Documentation issues


I want to use this thread to identify possible documentation issues:

Writing mash data->Creating mesh data
to be consistent I think you want vertexDesc in the following line to be meshData

// Create mesh data able to contain 8 vertices of the format specified by vertexDesc, and 36 indices
SPtr vertexDesc = MeshData::create(8, 36, vertexDesc);

Writing mash data->Populating mesh data
I think myVertexPositions on the left hand side is missing an array index

// Fill out the data for the 0th VES_POSITION element
Vector3 myVertexPositions[8];
for(UINT32 i = 0; i < 8; i++)
myVertexPositions = Vector3(i, i, 0); // Arbitrary

In the next line:

// Write the vertices
meshData->setVertexData(VES_POSITION, myVertexPositions, sizeof(myVertexPositions));

I get an error: error C2664: ‘void bs::MeshData::setVertexData(bs::VertexElementSemantic,bs::UINT8 *,bs::UINT32,bs::UINT32,bs::UINT32)’: cannot convert argument 2 from ‘bs::Vector3 [8]’ to ‘bs::UINT8 *’


Thanks, having a thread for this seems like a good idea! I’m sure there a lot more minor issues to be found. I’ll move the threat to the Bugs category since I feel it’s a bit more appropriate.

I’ve fixed the first two issues by updating the docs, and the last issue was resolved on master by changing that function’s signature so it doesn’t require a cast so it now matches the documentation.