35 #ifndef IECOREGL_POINTSPRIMITIVE_H
36 #define IECOREGL_POINTSPRIMITIVE_H
38 #include "IECoreGL/Export.h"
39 #include "IECoreGL/Primitive.h"
41 #include "IECore/VectorTypedData.h"
46 class IECOREGL_API PointsPrimitive :
public Primitive
51 IE_CORE_DECLARERUNTIMETYPEDEXTENSION( IECoreGL::PointsPrimitive, PointsPrimitiveTypeId, Primitive );
62 PointsPrimitive( Type type );
63 ~PointsPrimitive()
override;
65 Imath::Box3f bound()
const override;
68 const Shader::Setup *shaderSetup(
const Shader *shader, State *state )
const override;
69 void render(
const State *currentState,
IECore::TypeId style )
const override;
70 void renderInstances(
size_t numInstances = 1 )
const override;
77 typedef TypedStateComponent<GLPointsUsage, PointsPrimitiveUseGLPointsTypeId> UseGLPoints;
80 IE_CORE_DECLAREPTR( UseGLPoints );
82 typedef TypedStateComponent<float, PointsPrimitiveGLPointWidthTypeId> GLPointWidth;
83 IE_CORE_DECLAREPTR( GLPointWidth );
89 static const T *dataAndStride(
const IECore::Data *data,
const T *defaultValue,
unsigned int &stride );
90 void updateBounds()
const;
92 Type effectiveType(
const State *state )
const;
94 static std::string &instancingVertexSource();
96 void depthSort()
const;
98 IE_CORE_FORWARDDECLARE( MemberData );
100 MemberDataPtr m_memberData;
104 IE_CORE_DECLAREPTR( PointsPrimitive );
108 #endif // IECOREGL_POINTSPRIMITIVE_H
The namespace within which all CoreGL functionality is defined.
Definition: AlphaTexture.h:41
Definition: PrimitiveVariable.h:47
TypeId
Definition: TypeIds.h:46