-----------------------------------------------------------------------------
| 185 | } |
| 186 | //----------------------------------------------------------------------------- |
| 187 | void ManualObject::beginUpdate(size_t sectionIndex) |
| 188 | { |
| 189 | OgreAssert(!mCurrentSection, "You cannot call begin() again until after you call end()"); |
| 190 | mCurrentSection = mSectionList.at(sectionIndex); |
| 191 | mCurrentUpdating = true; |
| 192 | mFirstVertex = true; |
| 193 | mTexCoordIndex = 0; |
| 194 | // reset vertex & index count |
| 195 | RenderOperation* rop = mCurrentSection->getRenderOperation(); |
| 196 | rop->vertexData->vertexCount = 0; |
| 197 | if (rop->indexData) |
| 198 | rop->indexData->indexCount = 0; |
| 199 | rop->useIndexes = false; |
| 200 | mDeclSize = rop->vertexData->vertexDeclaration->getVertexSize(0); |
| 201 | } |
| 202 | //----------------------------------------------------------------------------- |
| 203 | void ManualObject::declareElement(VertexElementType t, VertexElementSemantic s) |
| 204 | { |