Duckcpp 2.1.0
Duckcpp is a high-performance c++ graphics engine.
Loading...
Searching...
No Matches
dcpp::scene::IDynamicMeshBuffer Class Referenceabstract

#include <duckcpp/core/engine/IDynamicMeshBuffer.hpp>

Inheritance diagram for dcpp::scene::IDynamicMeshBuffer:
Inheritance graph
Collaboration diagram for dcpp::scene::IDynamicMeshBuffer:
Collaboration graph

Public Member Functions

virtual IVertexBuffergetVertexBuffer () const =0
 
virtual IIndexBuffergetIndexBuffer () const =0
 
virtual void setVertexBuffer (IVertexBuffer *vertexBuffer)=0
 
virtual void setIndexBuffer (IIndexBuffer *indexBuffer)=0
 
virtual E_HARDWARE_MAPPING getHardwareMappingHint_Vertex () const override
 get the current hardware mapping hint
 
virtual E_HARDWARE_MAPPING getHardwareMappingHint_Index () const override
 get the current hardware mapping hint
 
virtual void setHardwareMappingHint (E_HARDWARE_MAPPING NewMappingHint, E_BUFFER_TYPE Buffer=EBT_VERTEX_AND_INDEX) override
 set the hardware mapping hint, for driver
 
virtual void setDirty (E_BUFFER_TYPE Buffer=EBT_VERTEX_AND_INDEX) override
 flags the mesh as changed, reloads hardware buffers
 
virtual u32 getChangedID_Vertex () const override
 Get the currently used ID for identification of changes.
 
virtual u32 getChangedID_Index () const override
 Get the currently used ID for identification of changes.
 
virtual video::E_VERTEX_TYPE getVertexType () const override
 Get type of vertex data which is stored in this meshbuffer.
 
virtual const void * getVertices () const override
 Get access to vertex data. The data is an array of vertices.
 
virtual void * getVertices () override
 Get access to vertex data. The data is an array of vertices.
 
virtual u32 getVertexCount () const override
 Get amount of vertices in meshbuffer.
 
virtual video::E_INDEX_TYPE getIndexType () const override
 Get type of index data which is stored in this meshbuffer.
 
virtual const u16getIndices () const override
 Get access to indices.
 
virtual u16getIndices () override
 Get access to indices.
 
virtual u32 getIndexCount () const override
 Get amount of indices in this meshbuffer.
 
virtual const nub::vector3dfgetPosition (u32 i) const override
 returns position of vertex i
 
virtual nub::vector3dfgetPosition (u32 i) override
 returns position of vertex i
 
virtual const nub::vector2dfgetTCoords (u32 i) const override
 returns texture coords of vertex i
 
virtual nub::vector2dfgetTCoords (u32 i) override
 returns texture coords of vertex i
 
virtual const nub::vector3dfgetNormal (u32 i) const override
 returns normal of vertex i
 
virtual nub::vector3dfgetNormal (u32 i) override
 returns normal of vertex i
 
virtual video::SColorgetColor (u32 i) override
 returns color of vertex i
 
virtual const video::SColorgetColor (u32 i) const override
 returns color of vertex i
 
- Public Member Functions inherited from dcpp::scene::IMeshBuffer
virtual video::SMaterialgetMaterial ()=0
 Get the material of this meshbuffer.
 
virtual const video::SMaterialgetMaterial () const =0
 Get the material of this meshbuffer.
 
virtual const nub::aabbox3dfgetBoundingBox () const =0
 Get the axis aligned bounding box of this meshbuffer.
 
virtual void setBoundingBox (const nub::aabbox3df &box)=0
 Set axis aligned bounding box.
 
virtual void recalculateBoundingBox ()=0
 Recalculates the bounding box. Should be called if the mesh changed.
 
virtual void append (const void *const vertices, u32 numVertices, const u16 *const indices, u32 numIndices)=0
 Append the vertices and indices to the current buffer.
 
virtual void append (const IMeshBuffer *const other)=0
 
virtual void setPrimitiveType (E_PRIMITIVE_TYPE type)=0
 Describe what kind of primitive geometry is used by the meshbuffer.
 
virtual E_PRIMITIVE_TYPE getPrimitiveType () const =0
 Get the kind of primitive geometry which is used by the meshbuffer.
 
virtual u32 getPrimitiveCount () const
 Calculate how many geometric primitives are used by this meshbuffer.
 
virtual EMESH_BUFFER_TYPE getType () const
 Returns type of the class implementing the IMeshBuffer.
 
virtual IMeshBuffercreateClone (int cloneFlags=ECF_VERTICES|ECF_INDICES) const =0
 Create a new object with a copy of the meshbuffer.
 
- Public Member Functions inherited from dcpp::IReferenceCounted
 IReferenceCounted ()
 Constructor.
 
virtual ~IReferenceCounted ()
 Destructor.
 
void grab () const
 Grabs the object. Increments the reference counter by one.
 
bool drop () const
 Drops the object. Decrements the reference counter by one.
 
i32 getReferenceCount () const
 Get the reference count.
 
const c8getDebugName () const
 Returns the debug name of the object.
 

Additional Inherited Members

- Public Types inherited from dcpp::scene::IMeshBuffer
enum  ECloneFlags { ECF_VERTICES = 1 , ECF_INDICES = 2 }
 Bitflags with options for cloning. More...
 
- Protected Member Functions inherited from dcpp::IReferenceCounted
void setDebugName (const c8 *newName)
 Sets the debug name of the object.
 

Detailed Description

a dynamic meshBuffer

Member Function Documentation

◆ getChangedID_Index()

virtual u32 dcpp::scene::IDynamicMeshBuffer::getChangedID_Index ( ) const
inlineoverridevirtual

Get the currently used ID for identification of changes.

This shouldn't be used for anything outside the VideoDriver.

Implements dcpp::scene::IMeshBuffer.

◆ getChangedID_Vertex()

virtual u32 dcpp::scene::IDynamicMeshBuffer::getChangedID_Vertex ( ) const
inlineoverridevirtual

Get the currently used ID for identification of changes.

This shouldn't be used for anything outside the VideoDriver.

Implements dcpp::scene::IMeshBuffer.

◆ getColor() [1/2]

virtual const video::SColor & dcpp::scene::IDynamicMeshBuffer::getColor ( u32  i) const
inlineoverridevirtual

returns color of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getColor() [2/2]

virtual video::SColor & dcpp::scene::IDynamicMeshBuffer::getColor ( u32  i)
inlineoverridevirtual

returns color of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getHardwareMappingHint_Index()

virtual E_HARDWARE_MAPPING dcpp::scene::IDynamicMeshBuffer::getHardwareMappingHint_Index ( ) const
inlineoverridevirtual

get the current hardware mapping hint

Implements dcpp::scene::IMeshBuffer.

◆ getHardwareMappingHint_Vertex()

virtual E_HARDWARE_MAPPING dcpp::scene::IDynamicMeshBuffer::getHardwareMappingHint_Vertex ( ) const
inlineoverridevirtual

get the current hardware mapping hint

Implements dcpp::scene::IMeshBuffer.

◆ getIndexCount()

virtual u32 dcpp::scene::IDynamicMeshBuffer::getIndexCount ( ) const
inlineoverridevirtual

Get amount of indices in this meshbuffer.

Returns
Number of indices in this buffer.

Implements dcpp::scene::IMeshBuffer.

◆ getIndexType()

virtual video::E_INDEX_TYPE dcpp::scene::IDynamicMeshBuffer::getIndexType ( ) const
inlineoverridevirtual

Get type of index data which is stored in this meshbuffer.

Returns
Index type of this buffer.

Implements dcpp::scene::IMeshBuffer.

◆ getIndices() [1/2]

virtual const u16 * dcpp::scene::IDynamicMeshBuffer::getIndices ( ) const
inlineoverridevirtual

Get access to indices.

Returns
Pointer to indices array.

Implements dcpp::scene::IMeshBuffer.

◆ getIndices() [2/2]

virtual u16 * dcpp::scene::IDynamicMeshBuffer::getIndices ( )
inlineoverridevirtual

Get access to indices.

Returns
Pointer to indices array.

Implements dcpp::scene::IMeshBuffer.

◆ getNormal() [1/2]

virtual const nub::vector3df & dcpp::scene::IDynamicMeshBuffer::getNormal ( u32  i) const
inlineoverridevirtual

returns normal of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getNormal() [2/2]

virtual nub::vector3df & dcpp::scene::IDynamicMeshBuffer::getNormal ( u32  i)
inlineoverridevirtual

returns normal of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getPosition() [1/2]

virtual const nub::vector3df & dcpp::scene::IDynamicMeshBuffer::getPosition ( u32  i) const
inlineoverridevirtual

returns position of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getPosition() [2/2]

virtual nub::vector3df & dcpp::scene::IDynamicMeshBuffer::getPosition ( u32  i)
inlineoverridevirtual

returns position of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getTCoords() [1/2]

virtual const nub::vector2df & dcpp::scene::IDynamicMeshBuffer::getTCoords ( u32  i) const
inlineoverridevirtual

returns texture coords of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getTCoords() [2/2]

virtual nub::vector2df & dcpp::scene::IDynamicMeshBuffer::getTCoords ( u32  i)
inlineoverridevirtual

returns texture coords of vertex i

Implements dcpp::scene::IMeshBuffer.

◆ getVertexCount()

virtual u32 dcpp::scene::IDynamicMeshBuffer::getVertexCount ( ) const
inlineoverridevirtual

Get amount of vertices in meshbuffer.

Returns
Number of vertices in this buffer.

Implements dcpp::scene::IMeshBuffer.

◆ getVertexType()

virtual video::E_VERTEX_TYPE dcpp::scene::IDynamicMeshBuffer::getVertexType ( ) const
inlineoverridevirtual

Get type of vertex data which is stored in this meshbuffer.

Returns
Vertex type of this buffer.

Implements dcpp::scene::IMeshBuffer.

◆ getVertices() [1/2]

virtual const void * dcpp::scene::IDynamicMeshBuffer::getVertices ( ) const
inlineoverridevirtual

Get access to vertex data. The data is an array of vertices.

Which vertex type is used can be determined by getVertexType().

Returns
Pointer to array of vertices.

Implements dcpp::scene::IMeshBuffer.

◆ getVertices() [2/2]

virtual void * dcpp::scene::IDynamicMeshBuffer::getVertices ( )
inlineoverridevirtual

Get access to vertex data. The data is an array of vertices.

Which vertex type is used can be determined by getVertexType().

Returns
Pointer to array of vertices.

Implements dcpp::scene::IMeshBuffer.

◆ setDirty()

virtual void dcpp::scene::IDynamicMeshBuffer::setDirty ( E_BUFFER_TYPE  Buffer = EBT_VERTEX_AND_INDEX)
inlineoverridevirtual

flags the mesh as changed, reloads hardware buffers

Implements dcpp::scene::IMeshBuffer.

◆ setHardwareMappingHint()

virtual void dcpp::scene::IDynamicMeshBuffer::setHardwareMappingHint ( E_HARDWARE_MAPPING  NewMappingHint,
E_BUFFER_TYPE  Buffer = EBT_VERTEX_AND_INDEX 
)
inlineoverridevirtual

set the hardware mapping hint, for driver

Implements dcpp::scene::IMeshBuffer.


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

Duckcpp    @cppfx.xyz