Carna Version 3.3.3
Loading...
Searching...
No Matches
OccludedRenderingStage.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2010 - 2015 Leonid Kostrykin
3 *
4 * Chair of Medical Engineering (mediTEC)
5 * RWTH Aachen University
6 * Pauwelsstr. 20
7 * 52074 Aachen
8 * Germany
9 *
10 */
11
12#ifndef OCCLUDEDRENDERINGSTAGE_H_6014714286
13#define OCCLUDEDRENDERINGSTAGE_H_6014714286
14
16
21namespace Carna
22{
23
24namespace presets
25{
26
27
28
29// ----------------------------------------------------------------------------------
30// OccludedRenderingStage
31// ----------------------------------------------------------------------------------
32
57{
58
59 struct Details;
60 const std::unique_ptr< Details > pimpl;
61
62 struct VideoResources;
63 std::unique_ptr< VideoResources > vr;
64
65public:
66
71
77
78 OccludedRenderingStage* clone() const override;
79
84
89
93 void enableStage( const base::RenderStage& rs );
94
99
103 bool isStageEnabled( const base::RenderStage& rs ) const;
104
111 void setOcclusionTranslucency( float translucency );
112
120
121 virtual void reshape( base::FrameRenderer& fr, unsigned int width, unsigned int height ) override;
122
123 virtual void prepareFrame( base::Node& root ) override;
124
125 virtual void renderPass
126 ( const base::math::Matrix4f& viewTransform
127 , base::RenderTask& rt
128 , const base::Viewport& vp ) override;
129
130}; // OccludedRenderingStage
131
132
133
134} // namespace Carna :: presets
135
136} // namespace Carna
137
138#endif // OCCLUDEDRENDERINGSTAGE_H_6014714286
Defines Carna::base::RenderStage.
Defines logic for rendering frames from given scenes.
Defines the inner node of a scene graph. Implements a spatial scene element that is allowed to have c...
Definition Node.h:45
Base abstract class of each rendering stage. Refer to the documentation of the rendering process.
Definition RenderStage.h:43
Invokes the rendering stages of the frame renderer successively.
Definition RenderTask.h:41
Defines a rendering viewport. The viewport is a property of the current OpenGL context.
Definition Viewport.h:49
Renders geometry that is actually depth-occluded. The occluded geometry is rendered with reduced opac...
bool isStageEnabled(const base::RenderStage &rs) const
Tells whether rs is enabled in .
virtual void renderPass(const base::math::Matrix4f &viewTransform, base::RenderTask &rt, const base::Viewport &vp) override
Called once per pass.
void disableAllStages()
Disables all stages.
void setOcclusionTranslucency(float translucency)
Sets the translucency of the occluding geometry.
static const float DEFAULT_OCCLUSION_TRANSLUCENCY
Holds the default translucency of the occluding geometry.
void enableStage(const base::RenderStage &rs)
Enables rs in .
OccludedRenderingStage * clone() const override
Returns same RenderStage implementation with same configuration.
virtual void prepareFrame(base::Node &root) override
Called once before each frame.
virtual void reshape(base::FrameRenderer &fr, unsigned int width, unsigned int height) override
Orders this stage to reshape its buffers according to the specified dimensions.
float occlusionTranslucency() const
Tells the translucency of the occluding geometry.
void disableStage(const base::RenderStage &rs)
Disables rs in .
OccludedRenderingStage()
Sets translucency of occluding geometry to DEFAULT_OCCLUSION_TRANSLUCENCY.
Eigen::Matrix< float, 4, 4, Eigen::ColMajor > Matrix4f
Defines matrix.
Definition math.h:193