OpenGL Point Sprites PolyData Mapper. More...
#include <VTKViewer_PolyDataMapper.h>
Classes | |
struct | Locations |
Public Types | |
enum | ExtensionsState { ES_None = 0, ES_Error, ES_Ok } |
Public Member Functions | |
vtkTypeMacro (VTKViewer_PolyDataMapper, vtkOpenGLPolyDataMapper) | |
void | SetMarkerEnabled (bool) |
Set point marker enabled. More... | |
void | SetBallEnabled (bool) |
Set point ball enabled. More... | |
bool | GetBallEnabled () |
void | SetBallScale (double) |
Set ball scale factor. More... | |
double | GetBallScale () |
void | SetMarkerStd (VTK::MarkerType, VTK::MarkerScale) |
Set standard point marker. More... | |
void | SetMarkerTexture (int, VTK::MarkerTexture) |
Set custom point marker. More... | |
VTK::MarkerType | GetMarkerType () |
Get type of the point marker. More... | |
VTK::MarkerScale | GetMarkerScale () |
Get scale of the point marker. More... | |
int | GetMarkerTexture () |
Get texture identifier of the point marker. More... | |
virtual void | RenderPiece (vtkRenderer *, vtkActor *) |
Implement superclass render method. More... | |
virtual int | Draw (vtkRenderer *, vtkActor *) |
Draw method for OpenGL. More... | |
Static Public Member Functions | |
static VTKViewer_PolyDataMapper * | New () |
Protected Member Functions | |
VTKViewer_PolyDataMapper () | |
~VTKViewer_PolyDataMapper () | |
int | InitExtensions () |
Initializing OpenGL extensions. More... | |
void | InitPointSprites () |
Activate Point Sprites. More... | |
void | CleanupPointSprites () |
Deactivate Point Sprites. More... | |
void | InitTextures () |
Initializing textures for Point Sprites. More... | |
int | InitShader () |
Initializing of the Vertex Shader. More... | |
void | InternalDraw (vtkRenderer *, vtkActor *) |
Private Types | |
typedef std::map< int, vtkSmartPointer< vtkImageData > > | ImageDataMap |
Private Attributes | |
int | ExtensionsInitialized |
GLuint | PointSpriteTexture |
vtkSmartPointer< vtkImageData > | ImageData |
VTKViewer_OpenGLHelper | OpenGLHelper |
GLhandleARB | PointProgram |
struct VTKViewer_PolyDataMapper::Locations | myLocations |
bool | MarkerEnabled |
bool | BallEnabled |
double | BallScale |
VTK::MarkerType | MarkerType |
VTK::MarkerScale | MarkerScale |
int | MarkerId |
ImageDataMap | StandardTextures |
ImageDataMap | CustomTextures |
ImageDataMap | SpecialTextures |
VTKViewer_PolyDataMapper is a class that maps polygonal data (i.e., vtkPolyData) to graphics primitives. It is performing the mapping to the rendering/graphics hardware/software. It is now possible to set a memory limit for the pipeline in the mapper. If the total estimated memory usage of the pipeline is larger than this limit, the mapper will divide the data into pieces and render each in a for loop.
|
private |
|
protected |
|
protected |
References VTKViewer_OpenGLHelper::DestroyShaderProgram(), OpenGLHelper, PointProgram, and PointSpriteTexture.
|
protected |
References GL_POINT_SPRITE_ARB, and GL_VERTEX_PROGRAM_POINT_SIZE_ARB.
|
virtual |
References BallEnabled, ImageData, InternalDraw(), MarkerEnabled, MarkerType, and VTK::MT_NONE.
bool VTKViewer_PolyDataMapper::GetBallEnabled | ( | ) |
References BallEnabled.
double VTKViewer_PolyDataMapper::GetBallScale | ( | ) |
References BallScale.
VTK::MarkerScale VTKViewer_PolyDataMapper::GetMarkerScale | ( | ) |
References MarkerScale.
int VTKViewer_PolyDataMapper::GetMarkerTexture | ( | ) |
References MarkerId.
VTK::MarkerType VTKViewer_PolyDataMapper::GetMarkerType | ( | ) |
References MarkerType.
|
protected |
References ES_Error, InitShader(), VTKViewer_OpenGLHelper::IsInitialized(), OpenGLHelper, and s.
|
protected |
References BallEnabled, GL_POINT_SPRITE_ARB, and GL_VERTEX_PROGRAM_POINT_SIZE_ARB.
|
protected |
References VTKViewer_OpenGLHelper::CreateShaderProgram(), ES_Ok, VTKViewer_PolyDataMapper::Locations::GeneralPointSize, GL_VERTEX_SHADER_ARB, VTKViewer_PolyDataMapper::Locations::ModelViewProjection, myLocations, OpenGLHelper, PointProgram, VTKViewer_PolyDataMapper::Locations::PointSprite, VTKViewer_PolyDataMapper::Locations::Projection, GUI_OPENGL::readFromFile(), VTKViewer_OpenGLHelper::vglAttachObjectARB, VTKViewer_OpenGLHelper::vglCompileShaderARB, VTKViewer_OpenGLHelper::vglCreateProgramObjectARB, VTKViewer_OpenGLHelper::vglCreateShaderObjectARB, VTKViewer_OpenGLHelper::vglLinkProgramARB, VTKViewer_OpenGLHelper::vglShaderSourceARB, and VTKViewer_OpenGLHelper::vglUseProgramObjectARB.
|
protected |
|
protected |
References BallEnabled, ES_Ok, ExtensionsInitialized, VTKViewer_PolyDataMapper::Locations::GeneralPointSize, GetBallScale(), GL_ARRAY_BUFFER_ARB, GL_STATIC_DRAW_ARB, ImageData, VTKViewer_PolyDataMapper::Locations::ModelViewProjection, myLocations, OpenGLHelper, PointProgram, VTKViewer_PolyDataMapper::Locations::Projection, VTKViewer_OpenGLHelper::vglBindBufferARB, VTKViewer_OpenGLHelper::vglBufferDataARB, VTKViewer_OpenGLHelper::vglDeleteBuffersARB, VTKViewer_OpenGLHelper::vglDisableVertexAttribArrayARB, VTKViewer_OpenGLHelper::vglEnableVertexAttribArrayARB, VTKViewer_OpenGLHelper::vglGenBuffersARB, VTKViewer_OpenGLHelper::vglGetAttribLocationARB, VTKViewer_OpenGLHelper::vglUseProgramObjectARB, and VTKViewer_OpenGLHelper::vglVertexAttribPointerARB.
|
static |
|
virtual |
void VTKViewer_PolyDataMapper::SetBallEnabled | ( | bool | theBallEnabled | ) |
References BallEnabled, BallTextureId, ImageData, VTK::MakeTexture(), and SpecialTextures.
void VTKViewer_PolyDataMapper::SetBallScale | ( | double | theBallScale | ) |
References BallScale.
void VTKViewer_PolyDataMapper::SetMarkerEnabled | ( | bool | theMarkerEnabled | ) |
References MarkerEnabled.
void VTKViewer_PolyDataMapper::SetMarkerStd | ( | VTK::MarkerType | theMarkerType, |
VTK::MarkerScale | theMarkerScale | ||
) |
References ImageData, VTK::LoadTextureData(), VTK::MakeVTKImage(), MarkerScale, MarkerType, VTK::MS_70, VTK::MT_NONE, VTK::MT_USER, and StandardTextures.
void VTKViewer_PolyDataMapper::SetMarkerTexture | ( | int | theMarkerId, |
VTK::MarkerTexture | theMarkerTexture | ||
) |
References CustomTextures, ImageData, VTK::MakeVTKImage(), MarkerId, MarkerType, and VTK::MT_USER.
VTKViewer_PolyDataMapper::vtkTypeMacro | ( | VTKViewer_PolyDataMapper | , |
vtkOpenGLPolyDataMapper | |||
) |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |