20 #ifndef _STELINDEXBUFFER_HPP_
21 #define _STELINDEXBUFFER_HPP_
58 Q_ASSERT_X(!locked_, Q_FUNC_INFO,
59 "Trying to set an index in a locked index buffer");
60 Q_ASSERT_X(
indexType_ == IndexType_U32 || index < 65536, Q_FUNC_INFO,
61 "Trying to add a 16-bit index with value greater than 65536");
75 Q_ASSERT_X(!locked_, Q_FUNC_INFO,
76 "Trying to get an index from a locked index buffer");
77 Q_ASSERT_X(which < indexCount_, Q_FUNC_INFO,
78 "Index to an index buffer element out of bounds");
88 void setIndex(
const int which,
const uint index)
90 Q_ASSERT_X(!locked_, Q_FUNC_INFO,
91 "Trying to set an index in a locked index buffer");
92 Q_ASSERT_X(which < indexCount_, Q_FUNC_INFO,
93 "Index to an index buffer element out of bounds");
94 Q_ASSERT_X(
indexType_ == IndexType_U32 || index < 65536, Q_FUNC_INFO,
95 "Trying to set a 16-bit index to a value greater than 65536");
108 Q_ASSERT_X(!locked_, Q_FUNC_INFO,
"Trying to clear a locked index buffer");
160 virtual void addIndex_(
const uint index) = 0;
165 virtual uint
getIndex_(
const int which)
const = 0;
170 virtual void setIndex_(
const int which,
const uint index) = 0;
175 virtual void clear_() = 0;
180 virtual void lock_() = 0;
196 #endif //_STELINDEXBUFFER_HPP_