mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-14 16:14:38 +00:00
- Fixed memory leak when creating terrain with physx 3
- Fixed terrain tessellation with physx 3
This commit is contained in:
parent
b0c83601d1
commit
664595ef9e
1 changed files with 4 additions and 2 deletions
|
|
@ -191,9 +191,9 @@ bool Px3Collision::addHeightfield( const U16 *heights,
|
||||||
|
|
||||||
int flag = ( column + tess ) % 2;
|
int flag = ( column + tess ) % 2;
|
||||||
if(flag)
|
if(flag)
|
||||||
currentSample->setTessFlag();
|
|
||||||
else
|
|
||||||
currentSample->clearTessFlag();
|
currentSample->clearTessFlag();
|
||||||
|
else
|
||||||
|
currentSample->setTessFlag();
|
||||||
|
|
||||||
currentByte += heightFieldDesc.samples.stride;
|
currentByte += heightFieldDesc.samples.stride;
|
||||||
}
|
}
|
||||||
|
|
@ -211,5 +211,7 @@ bool Px3Collision::addHeightfield( const U16 *heights,
|
||||||
desc->pose = pose2;
|
desc->pose = pose2;
|
||||||
|
|
||||||
mColShapes.push_back(desc);
|
mColShapes.push_back(desc);
|
||||||
|
|
||||||
|
SAFE_DELETE(samples);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue