Point Cloud Viewer  1.00
A Viewer to display point clouds with phong shading by converting them to splats.
VisibilityPass Class Reference

A Render Pass that just fills a depth buffer. More...

#include <visibilitypass.h>

Inherits RenderPass.

Public Member Functions

void render () override
 Uses the input data to generate the output. More...
 
void cleanup () override
 Resets the Render Pass to the state after creation but before initialization. More...
 
void addObjectInput (VaoChannel &vaoChannel)
 Adds a model to the geometry input list. More...
 
void removeObjectInput (VaoChannel &vaoChannel)
 Removes a model from the geometry input list. More...
 
void clearObjectInput ()
 Removes all models from the geometry input list.
 
TextureChannelgetDepthMapOutput ()
 Returns the depth buffer. More...
 
bool depthMapToScreen ()
 Changes the output mode. The depth map is now drawn onto the screen. More...
 
void removeInput ()
 Removes all input channels except for VaoChannels. If the Render Pass uses VaoChannels as input use the provided clearObjectInput() function to remove all VaoChannels.
 
void updateResolution () override
 Must be called after the screen resolution has changed. More...
 
void linkSplatScale (float &scale)
 Links the splat scale. More...
 
- Public Member Functions inherited from RenderPass
virtual ~RenderPass ()
 Calls cleanup() More...
 

Static Public Member Functions

static void linkVpMat (QMatrix4x4 &vp)
 Links the view projection matrix that shall be used during rendering. More...
 
static void linkVMat (QMatrix4x4 &v)
 Links the view matrix that shall be used during rendering. More...
 
static void linkPointSizeCoeff (float &coeff)
 Links the point size coefficient. More...
 
- Static Public Member Functions inherited from RenderPass
static void cleanupHelpers ()
 Removes helper variables. More...
 

Additional Inherited Members

- Protected Member Functions inherited from RenderPass
template<class C >
bool helperMultiChannelContains (std::list< C * > &list, C &channel)
 
template<class C >
void helperMultiChannelAdd (std::list< C * > &list, C &channel)
 
template<class C >
bool helperMultiChannelRemove (std::list< C * > &list, C &channel)
 
template<class C >
void helperMultiChannelClean (std::list< C * > &list)
 
template<class C >
void helperMultiChannelClear (std::list< C * > &list)
 
- Static Protected Member Functions inherited from RenderPass
static bool loadShader (std::string &path, GLuint id)
 
static bool noGlErrors ()
 
static bool checkFbo ()
 
static void drawUnitQuad ()
 

Detailed Description

A Render Pass that just fills a depth buffer.

This Render Pass takes geometry as input and renders the z-values into a depth buffer.

Member Function Documentation

void VisibilityPass::addObjectInput ( VaoChannel &  vaoChannel)

Adds a model to the geometry input list.

Parameters
vaoChannelThe channel containing the geometry.
void VisibilityPass::cleanup ( )
overridevirtual

Resets the Render Pass to the state after creation but before initialization.

Might use OpenGL calls. If no other instances of this Render Pass are currently initialized the shader program is removed from the GPU.

Implements RenderPass.

bool VisibilityPass::depthMapToScreen ( )

Changes the output mode. The depth map is now drawn onto the screen.

Might use OpenGL calls.

Returns
Returns false if the output to the screen could not be set up properly.
RenderPass::TextureChannel & VisibilityPass::getDepthMapOutput ( )

Returns the depth buffer.

Might use OpenGL calls.

Returns
A channel containing the depth values.
void VisibilityPass::linkPointSizeCoeff ( float &  coeff)
static

Links the point size coefficient.

This value can be generated by the Camera. Does not copy the value. The responsibility for deletion remains at the caller.

Parameters
coeffThe coefficient. Must point to a valid float whenever render() is called.
void VisibilityPass::linkSplatScale ( float &  scale)

Links the splat scale.

The higher the value the bigger the drawn splats. A value of 1 leads to no splat scaling. Does not copy the value. The responisbility for deletion remains at the caller.

Parameters
scaleThe scaling coefficient. Must poit to a valid float whenever render() is called.
void VisibilityPass::linkVMat ( QMatrix4x4 &  v)
static

Links the view matrix that shall be used during rendering.

Does not copy the matrix. The responsibility for deletion remains at the caller.

Parameters
vThe view matrix. Must point to a valid matrix whenever render() is called.
void VisibilityPass::linkVpMat ( QMatrix4x4 &  vp)
static

Links the view projection matrix that shall be used during rendering.

Does not copy the matrix. The responsibility for deletion remains at the caller.

Parameters
vpThe view projection matrix. Must point to a valid matrix whenever render() is called.
void VisibilityPass::removeObjectInput ( VaoChannel &  vaoChannel)

Removes a model from the geometry input list.

Parameters
vaoChannelThe channel containing the geometry that shall not be rendered anymore.
void VisibilityPass::render ( )
overridevirtual

Uses the input data to generate the output.

Uses OpenGL calls if initialized.

Implements RenderPass.

void VisibilityPass::updateResolution ( )
overridevirtual

Must be called after the screen resolution has changed.

Might use OpenGL calls.

Implements RenderPass.


The documentation for this class was generated from the following files: