Create and return a height-field collision shape * @param heightField A pointer to a HeightField object * @param scaling Scaling vector for the height field * @return A pointer to the created height field shape */
| 510 | * @return A pointer to the created height field shape |
| 511 | */ |
| 512 | HeightFieldShape* PhysicsCommon::createHeightFieldShape(HeightField* heightField, const Vector3& scaling) { |
| 513 | |
| 514 | HeightFieldShape* shape = new (mMemoryManager.allocate(MemoryManager::AllocationType::Pool, sizeof(HeightFieldShape))) HeightFieldShape(heightField, mMemoryManager.getHeapAllocator(), scaling); |
| 515 | |
| 516 | mHeightFieldShapes.add(shape); |
| 517 | |
| 518 | return shape; |
| 519 | } |
| 520 | |
| 521 | // Destroy a height-field shape |
| 522 | /** |