25 #include "../common/WProperties.h"
27 #include "shaders/WGEShader.h"
28 #include "shaders/WGEPropertyUniform.h"
30 #include "WGEViewerEffectHorizon.h"
33 WGEViewerEffect(
"Horizon Background",
"Configurable horizon background effect." )
35 WPropColor bottom1Color =
m_properties->addProperty(
"First Bottom Color",
"Bottom color gradient: first color.",
36 WColor( 1.00, 1.00, 1.00, 1.00 ) );
37 WPropColor bottom2Color =
m_properties->addProperty(
"Second Bottom Color",
"Bottom color gradient: second color.",
38 WColor( 0.82, 0.82, 0.82, 1.00 ) );
39 WPropColor top1Color =
m_properties->addProperty(
"First Top Color",
"Top color gradient: first color.",
40 WColor( 0.85, 0.85, 0.85, 1.0 ) );
41 WPropColor top2Color =
m_properties->addProperty(
"Second Top Color",
"Top color gradient: second color.",
42 WColor( 0.95, 0.95, 0.95, 0.95 ) );
44 WPropDouble horizonLine =
m_properties->addProperty(
"Horizon in %",
"Horizon line in percent.", 33.0 );
45 horizonLine->setMin( 0.0 );
46 horizonLine->setMax( 100.0 );
55 setRenderOrder( WGECamera::NESTED_RENDER, -1000 );
57 osg::ref_ptr< WGEShader > horizonShader =
new WGEShader(
"WGECameraHorizon" );
58 horizonShader->apply(
m_geode );
Class encapsulating the OSG Program class for a more convenient way of adding and modifying shader.
WGEViewerEffectHorizon()
Default constructor.
virtual ~WGEViewerEffectHorizon()
Destructor.
Base class for implementing basic fullscreen effects for the WGEViewer.
osg::ref_ptr< osg::StateSet > m_state
The stateset of the cam.
osg::ref_ptr< osg::Geode > m_geode
The fullscreen quad.
WProperties::SPtr m_properties
the properties of the object.