mirror of
https://github.com/SFML/CSFML.git
synced 2026-10-24 13:53:36 +02:00
Fix const correctness issues
This commit is contained in:
1 parent
feb431a689
commit
589b86d4c0
4 files changed
+6
-6
No files matched your search
@@ -150,7 +150,7 @@ CSFML_GRAPHICS_API void sfVertexArray_setPrimitiveType(sfVertexArray* vertexArra
|
||||
/// \return Primitive type
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_GRAPHICS_API sfPrimitiveType sfVertexArray_getPrimitiveType(sfVertexArray* vertexArray);
|
||||
CSFML_GRAPHICS_API sfPrimitiveType sfVertexArray_getPrimitiveType(const sfVertexArray* vertexArray);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// \brief Compute the bounding rectangle of a vertex array
|
||||
@@ -163,4 +163,4 @@ CSFML_GRAPHICS_API sfPrimitiveType sfVertexArray_getPrimitiveType(sfVertexArray*
|
||||
/// \return Bounding rectangle of the vertex array
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_GRAPHICS_API sfFloatRect sfVertexArray_getBounds(sfVertexArray* vertexArray);
|
||||
CSFML_GRAPHICS_API sfFloatRect sfVertexArray_getBounds(const sfVertexArray* vertexArray);
|
||||
@@ -166,7 +166,7 @@ CSFML_GRAPHICS_API void sfVertexBuffer_swap(sfVertexBuffer* left, sfVertexBuffer
|
||||
/// \return OpenGL handle of the vertex buffer or 0 if not yet created
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_GRAPHICS_API unsigned int sfVertexBuffer_getNativeHandle(sfVertexBuffer* vertexBuffer);
|
||||
CSFML_GRAPHICS_API unsigned int sfVertexBuffer_getNativeHandle(const sfVertexBuffer* vertexBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// \brief Set the type of primitives to draw
|
||||
|
||||
@@ -104,7 +104,7 @@ void sfVertexArray_setPrimitiveType(sfVertexArray* vertexArray, sfPrimitiveType
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
sfPrimitiveType sfVertexArray_getPrimitiveType(sfVertexArray* vertexArray)
|
||||
sfPrimitiveType sfVertexArray_getPrimitiveType(const sfVertexArray* vertexArray)
|
||||
{
|
||||
assert(vertexArray);
|
||||
return static_cast<sfPrimitiveType>(vertexArray->getPrimitiveType());
|
||||
@@ -112,7 +112,7 @@ sfPrimitiveType sfVertexArray_getPrimitiveType(sfVertexArray* vertexArray)
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
sfFloatRect sfVertexArray_getBounds(sfVertexArray* vertexArray)
|
||||
sfFloatRect sfVertexArray_getBounds(const sfVertexArray* vertexArray)
|
||||
{
|
||||
assert(vertexArray);
|
||||
return convertRect(vertexArray->getBounds());
|
||||
|
||||
@@ -92,7 +92,7 @@ void sfVertexBuffer_swap(sfVertexBuffer* left, sfVertexBuffer* right)
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfVertexBuffer_getNativeHandle(sfVertexBuffer* vertexBuffer)
|
||||
unsigned int sfVertexBuffer_getNativeHandle(const sfVertexBuffer* vertexBuffer)
|
||||
{
|
||||
assert(vertexBuffer);
|
||||
return vertexBuffer->getNativeHandle();
|
||||
|
||||
Reference in new issue
Block a user