mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-25 16:55:07 +02:00
Merge pull request #3767 from birarda/plugs
fix a bug produced by not setting deleted var to NULL
This commit is contained in:
commit
338c5aea94
2 changed files with 5 additions and 4 deletions
|
@ -547,11 +547,12 @@ void Octree::deleteOctalCodeFromTreeRecursion(OctreeElement* element, void* extr
|
|||
|
||||
void Octree::eraseAllOctreeElements(bool createNewRoot) {
|
||||
delete _rootElement; // this will recurse and delete all children
|
||||
_rootElement = NULL;
|
||||
|
||||
if (createNewRoot) {
|
||||
_rootElement = createNewElement();
|
||||
} else {
|
||||
_rootElement = NULL;
|
||||
}
|
||||
|
||||
_isDirty = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -79,8 +79,8 @@ public:
|
|||
|
||||
protected:
|
||||
|
||||
uint32_t _glBufferIndex : 24, /// Client only, vbo index for this voxel if being rendered, 3 bytes
|
||||
_voxelSystemIndex : 8; /// Client only, index to the VoxelSystem rendering this voxel, 1 bytes
|
||||
uint32_t _glBufferIndex : 24; /// Client only, vbo index for this voxel if being rendered, 3 bytes
|
||||
uint32_t _voxelSystemIndex : 8; /// Client only, index to the VoxelSystem rendering this voxel, 1 bytes
|
||||
|
||||
// Support for _voxelSystemIndex, we use these static member variables to track the VoxelSystems that are
|
||||
// in use by various voxel nodes. We map the VoxelSystem pointers into an 1 byte key, this limits us to at
|
||||
|
|
Loading…
Reference in a new issue