Go to the documentation of this file.
24 #ifndef vtkOpenGLPolyDataMapper_h
25 #define vtkOpenGLPolyDataMapper_h
28 #include "vtkRenderingOpenGL2Module.h"
81 vtkGetMacro(PopulateSelectionSettings,
int);
116 vtkSetStringMacro(PointIdArrayName);
117 vtkGetStringMacro(PointIdArrayName);
118 vtkSetStringMacro(CellIdArrayName);
119 vtkGetStringMacro(CellIdArrayName);
128 vtkSetStringMacro(ProcessIdArrayName);
129 vtkGetStringMacro(ProcessIdArrayName);
142 vtkSetStringMacro(CompositeIdArrayName);
143 vtkGetStringMacro(CompositeIdArrayName);
155 void AddShaderReplacement(
161 void ClearShaderReplacement(
166 void ClearAllShaderReplacements();
176 vtkSetStringMacro(VertexShaderCode);
177 vtkGetStringMacro(VertexShaderCode);
178 vtkSetStringMacro(FragmentShaderCode);
179 vtkGetStringMacro(FragmentShaderCode);
180 vtkSetStringMacro(GeometryShaderCode);
181 vtkGetStringMacro(GeometryShaderCode);
190 std::vector<float> &buffData);
203 this->HaveAppleBugForce = 1;
208 this->HaveAppleBugForce = 2;
224 void SetVBOShiftScaleMethod(
int m);
247 static void MakeCellCellMap(
248 std::vector<vtkIdType> &cellCellMap,
266 const char* vertexAttributeName,
267 const char* dataArrayName,
268 int fieldAssociation,
269 int componentno = -1)
override;
278 const char* dataArrayName,
int fieldAssociation,
int componentno = -1)
override;
295 std::vector<unsigned int> &pixeloffsets,
305 const char* vertexAttributeName,
306 const char* dataArrayName,
307 const char *texturename,
308 int fieldAssociation,
312 std::string GetTextureCoordinateName(
const char *tname);
326 void GetCoincidentParameters(
340 virtual void UpdateShaders(
346 virtual bool GetNeedToRebuildShaders(
352 virtual void BuildShaders(
353 std::map<vtkShader::Type, vtkShader *> shaders,
359 virtual void GetShaderTemplate(
360 std::map<vtkShader::Type, vtkShader *> shaders,
366 virtual void ReplaceShaderValues(
367 std::map<vtkShader::Type, vtkShader *> shaders,
375 virtual void ReplaceShaderRenderPass(
376 std::map<vtkShader::Type, vtkShader *> shaders,
378 virtual void ReplaceShaderColor(
379 std::map<vtkShader::Type, vtkShader *> shaders,
381 virtual void ReplaceShaderLight(
382 std::map<vtkShader::Type, vtkShader *> shaders,
384 virtual void ReplaceShaderTCoord(
385 std::map<vtkShader::Type, vtkShader *> shaders,
387 virtual void ReplaceShaderPicking(
388 std::map<vtkShader::Type, vtkShader *> shaders,
390 virtual void ReplaceShaderPrimID(
391 std::map<vtkShader::Type, vtkShader *> shaders,
393 virtual void ReplaceShaderNormal(
394 std::map<vtkShader::Type, vtkShader *> shaders,
396 virtual void ReplaceShaderClip(
397 std::map<vtkShader::Type, vtkShader *> shaders,
399 virtual void ReplaceShaderPositionVC(
400 std::map<vtkShader::Type, vtkShader *> shaders,
402 virtual void ReplaceShaderCoincidentOffset(
403 std::map<vtkShader::Type, vtkShader *> shaders,
405 virtual void ReplaceShaderDepth(
406 std::map<vtkShader::Type, vtkShader *> shaders,
462 virtual bool HaveTextures(
vtkActor *actor);
465 virtual unsigned int GetNumberOfTextures(
vtkActor *actor);
472 virtual std::vector<std::pair<vtkTexture *, std::string> > GetTextures(
vtkActor *actor);
517 virtual void BuildCellTextures(
523 void AppendCellTextures(
528 std::vector<unsigned char> &colors,
529 std::vector<float> &normals,
545 std::map<const vtkShader::ReplacementSpec, vtkShader::ReplacementValue>
569 int GetOpenGLMode(
int representation,
int primType);
573 int GetPointPickingPrimitiveSize(
int primType);
map vtkPolyData to graphics primitives
represent and manipulate 3D points
bool GetHaveAppleBug()
Get the value of HaveAppleBug.
char * CompositeIdArrayName
bool ForceTextureCoordinates
vtkStateStorage TempState
virtual void MapDataArrayToMultiTextureAttribute(const char *textureName, const char *dataArrayName, int fieldAssociation, int componentno=-1)
Class to make storing and comparing state quick and easy.
void SetPopulateSelectionSettings(int v)
std::string CellMapsBuildString
virtual void RenderPiece(vtkRenderer *ren, vtkActor *act)=0
Implemented by sub classes.
virtual void RemoveVertexAttributeMapping(const char *vertexAttributeName)
Remove a vertex attribute mapping.
record modification and/or execution time
std::vector< vtkIdType > CellCellMap
std::map< const vtkOpenGLHelper *, int > LastLightCount
vtkStateStorage VBOBuildState
void ShallowCopy(vtkAbstractMapper *m) override
Make a shallow copy of this mapper.
virtual void Modified()
Update the modification time for this object.
std::vector< float > AppleBugPrimIDs
vtkStateStorage IBOBuildState
std::map< std::string, ExtraAttributeValue > ExtraAttributes
vtkNew< vtkMatrix4x4 > VBOShiftScale
represent and manipulate 3x3 transformation matrices
window superclass for vtkRenderWindow
vtkTextureObject * CellNormalTexture
Asynchronously measures GPU execution time for a single event.
vtkOpenGLHelper * LastBoundBO
handles properties associated with a texture map
std::map< const vtkOpenGLHelper *, int > LastLightComplexity
char * FragmentShaderCode
vtkTimeStamp VBOBuildTime
manage vertex buffer objects shared within a mapper
virtual void ProcessSelectorPixelBuffers(vtkHardwareSelector *, std::vector< unsigned int > &, vtkProp *)
allows a mapper to update a selections color buffers Called from a prop which in turn is called from ...
vtkPolyData * CurrentInput
char * GeometryShaderCode
vtkOpenGLBufferObject * CellNormalBuffer
represents an object (geometry & properties) in a rendered scene
a simple class to control print indentation
abstracts an OpenGL texture object.
represent and manipulate 4x4 transformation matrices
std::map< const vtkShader::ReplacementSpec, vtkShader::ReplacementValue > UserShaderReplacements
bool DrawingEdgesOrVertices
std::vector< vtkIdType > PointCellMap
object to represent cell connectivity
Type
Available shader types.
vtkGenericOpenGLResourceFreeCallback * ResourceCallback
vtkNew< vtkTransform > VBOInverseTransform
int PopulateSelectionSettings
bool GetSupportsSelection() override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THIS METHOD OUTSIDE OF THE RENDERI...
std::map< const vtkOpenGLHelper *, vtkTimeStamp > LightComplexityChanged
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this mapper.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
abstract superclass for all actors, volumes and annotations
vtkMatrix4x4 * TempMatrix4
vtkOpenGLVertexBufferObjectGroup * VBOs
static vtkPolyDataMapper * New()
virtual void MapDataArrayToVertexAttribute(const char *vertexAttributeName, const char *dataArrayName, int fieldAssociation, int componentno=-1)
Select a data array from the point/cell data and map it to a generic vertex attribute.
virtual bool GetIsOpaque()
Returns if the mapper does not expect to have translucent geometry.
void ForceHaveAppleBugOn()
vtkOpenGLRenderTimer * TimerQuery
vtkOpenGLTexture * InternalColorTexture
abstract specification for renderers
vtkNew< vtkInformation > LastRenderPassInfo
unsigned int TimerQueryCounter
vtkStateStorage CellTextureBuildState
concrete dataset represents vertices, lines, polygons, and triangle strips
void ForceHaveAppleBugOff()
Override the normal test for the apple bug.
virtual void ComputeBounds()
Called in GetBounds().
vtkOpenGLBufferObject * AppleBugPrimIDBuffer
vtkMatrix3x3 * TempMatrix3
PolyDataMapper using OpenGL to render.
char * ProcessIdArrayName
vtkOpenGLBufferObject * CellScalarBuffer
vtkTimeStamp SelectionStateChanged
virtual void RemoveAllVertexAttributeMappings()
Remove all vertex attributes.
abstract class specifies interface to map data
vtkTextureObject * CellScalarTexture
vtkTypeUInt32 vtkMTimeType