MCPcopy Create free account
hub / github.com/carbonengine/trinity / SetUseLinearColorSpace

Method SetUseLinearColorSpace

trinity/Sprite2d/Tr2Sprite2dScene.cpp:2636–2647  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2634}
2635
2636void Tr2Sprite2dScene::SetUseLinearColorSpace( bool use )
2637{
2638 m_useLinearColorSpace = use;
2639 if( m_uberShader2d )
2640 {
2641 m_uberShader2d->SetOption( BlueSharedString( "COLOR_SPACE" ), BlueSharedString( m_useLinearColorSpace ? "COLOR_SPACE_LINEAR" : "COLOR_SPACE_SRGB" ) );
2642 }
2643 if( m_uberShader3d )
2644 {
2645 m_uberShader3d->SetOption( BlueSharedString( "COLOR_SPACE" ), BlueSharedString( m_useLinearColorSpace ? "COLOR_SPACE_LINEAR" : "COLOR_SPACE_SRGB" ) );
2646 }
2647}
2648void Tr2Sprite2dScene::SetGammaCorrectText( bool use )
2649{
2650 m_isGammaCorrectingText = use;

Callers

nothing calls this directly

Calls 1

SetOptionMethod · 0.80

Tested by

no test coverage detected