[IGfxWorld] Map all array entries
This commit is contained in:
parent
ce457b20c6
commit
0d1267f7d9
@ -250,7 +250,7 @@ namespace Assets
|
||||
|
||||
if (aabbTree->smodelIndexes)
|
||||
{
|
||||
void* oldPointer = aabbTree->smodelIndexes;
|
||||
unsigned short* oldPointer = aabbTree->smodelIndexes;
|
||||
if(builder->getAllocator()->isPointerMapped(oldPointer))
|
||||
{
|
||||
// We still have to read it
|
||||
@ -261,7 +261,11 @@ namespace Assets
|
||||
else
|
||||
{
|
||||
aabbTree->smodelIndexes = reader.readArray<unsigned short>(aabbTree->smodelIndexCount);
|
||||
builder->getAllocator()->mapPointer(oldPointer, aabbTree->smodelIndexes);
|
||||
|
||||
for (unsigned short k = 0; k < aabbTree->smodelIndexCount; ++k)
|
||||
{
|
||||
builder->getAllocator()->mapPointer(&oldPointer[k], &aabbTree->smodelIndexes[k]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user