Open3D (C++ API)  0.18.0+252c867
Public Member Functions | Protected Member Functions | Protected Attributes
open3d::visualization::glsl::NormalShader Class Referenceabstract

#include <NormalShader.h>

Inheritance diagram for open3d::visualization::glsl::NormalShader:
open3d::visualization::glsl::ShaderWrapper open3d::visualization::glsl::NormalShaderForPointCloud open3d::visualization::glsl::NormalShaderForTriangleMesh

Public Member Functions

 ~NormalShader () override
 
- Public Member Functions inherited from open3d::visualization::glsl::ShaderWrapper
virtual ~ShaderWrapper ()
 
 ShaderWrapper (const ShaderWrapper &)=delete
 
ShaderWrapperoperator= (const ShaderWrapper &)=delete
 
bool Render (const geometry::Geometry &geometry, const RenderOption &option, const ViewControl &view)
 
void InvalidateGeometry ()
 
const std::string & GetShaderName () const
 
void PrintShaderWarning (const std::string &message) const
 

Protected Member Functions

 NormalShader (const std::string &name)
 
bool Compile () final
 
void Release () final
 
bool BindGeometry (const geometry::Geometry &geometry, const RenderOption &option, const ViewControl &view) final
 
bool RenderGeometry (const geometry::Geometry &geometry, const RenderOption &option, const ViewControl &view) final
 
void UnbindGeometry () final
 
virtual bool PrepareRendering (const geometry::Geometry &geometry, const RenderOption &option, const ViewControl &view)=0
 
virtual bool PrepareBinding (const geometry::Geometry &geometry, const RenderOption &option, const ViewControl &view, std::vector< Eigen::Vector3f > &points, std::vector< Eigen::Vector3f > &normals)=0
 
- Protected Member Functions inherited from open3d::visualization::glsl::ShaderWrapper
 ShaderWrapper (const std::string &name)
 
bool ValidateShader (GLuint shader_index)
 
bool ValidateProgram (GLuint program_index)
 
bool CompileShaders (const char *const vertex_shader_code, const char *const geometry_shader_code, const char *const fragment_shader_code)
 
void ReleaseProgram ()
 
void SetShaderName (const std::string &shader_name)
 

Protected Attributes

GLuint vertex_position_
 
GLuint vertex_position_buffer_
 
GLuint vertex_normal_
 
GLuint vertex_normal_buffer_
 
GLuint MVP_
 
GLuint V_
 
GLuint M_
 
- Protected Attributes inherited from open3d::visualization::glsl::ShaderWrapper
GLuint vertex_shader_ = 0
 
GLuint geometry_shader_ = 0
 
GLuint fragment_shader_ = 0
 
GLuint program_ = 0
 
GLenum draw_arrays_mode_ = GL_POINTS
 
GLsizei draw_arrays_size_ = 0
 
bool compiled_ = false
 
bool bound_ = false
 

Constructor & Destructor Documentation

◆ ~NormalShader()

open3d::visualization::glsl::NormalShader::~NormalShader ( )
inlineoverride

◆ NormalShader()

open3d::visualization::glsl::NormalShader::NormalShader ( const std::string &  name)
inlineprotected

Member Function Documentation

◆ BindGeometry()

bool open3d::visualization::glsl::NormalShader::BindGeometry ( const geometry::Geometry geometry,
const RenderOption option,
const ViewControl view 
)
finalprotectedvirtual

◆ Compile()

bool open3d::visualization::glsl::NormalShader::Compile ( )
finalprotectedvirtual

Function to compile shader In a derived class, this must be declared as final, and called from the constructor.

Implements open3d::visualization::glsl::ShaderWrapper.

◆ PrepareBinding()

virtual bool open3d::visualization::glsl::NormalShader::PrepareBinding ( const geometry::Geometry geometry,
const RenderOption option,
const ViewControl view,
std::vector< Eigen::Vector3f > &  points,
std::vector< Eigen::Vector3f > &  normals 
)
protectedpure virtual

◆ PrepareRendering()

virtual bool open3d::visualization::glsl::NormalShader::PrepareRendering ( const geometry::Geometry geometry,
const RenderOption option,
const ViewControl view 
)
protectedpure virtual

◆ Release()

void open3d::visualization::glsl::NormalShader::Release ( )
finalprotectedvirtual

Function to release resource In a derived class, this must be declared as final, and called from the destructor.

Implements open3d::visualization::glsl::ShaderWrapper.

◆ RenderGeometry()

bool open3d::visualization::glsl::NormalShader::RenderGeometry ( const geometry::Geometry geometry,
const RenderOption option,
const ViewControl view 
)
finalprotectedvirtual

◆ UnbindGeometry()

void open3d::visualization::glsl::NormalShader::UnbindGeometry ( )
finalprotectedvirtual

Field Documentation

◆ M_

GLuint open3d::visualization::glsl::NormalShader::M_
protected

◆ MVP_

GLuint open3d::visualization::glsl::NormalShader::MVP_
protected

◆ V_

GLuint open3d::visualization::glsl::NormalShader::V_
protected

◆ vertex_normal_

GLuint open3d::visualization::glsl::NormalShader::vertex_normal_
protected

◆ vertex_normal_buffer_

GLuint open3d::visualization::glsl::NormalShader::vertex_normal_buffer_
protected

◆ vertex_position_

GLuint open3d::visualization::glsl::NormalShader::vertex_position_
protected

◆ vertex_position_buffer_

GLuint open3d::visualization::glsl::NormalShader::vertex_position_buffer_
protected

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