Showing the changes to interface/src/VoxelSystem.cpp (1 of 20 files). Show all
Unified · Split
| @@ -72,6 +72,18 @@ void VoxelSystem::loadVoxelsFile(const char* fileName, bool wantColorRandomizer) · 71 unmodified lines | |||
| 72 | setupNewVoxelsForDrawing(); | 72 | setupNewVoxelsForDrawing(); |
| 73 | } | 73 | } |
| 74 | 74 | ||
| 75 | void VoxelSystem::writeToSVOFile(const char* filename, VoxelNode* node) const { | ||
| 76 | _tree->writeToSVOFile(filename, node); | ||
| 77 | } | ||
| 78 | |||
| 79 | bool VoxelSystem::readFromSVOFile(const char* filename) { | ||
| 80 | bool result = _tree->readFromSVOFile(filename); | ||
| 81 | if (result) { | ||
| 82 | setupNewVoxelsForDrawing(); | ||
| 83 | } | ||
| 84 | return result; | ||
| 85 | } | ||
| 86 | |||
| 75 | long int VoxelSystem::getVoxelsCreated() { | 87 | long int VoxelSystem::getVoxelsCreated() { |
| 76 | return _tree->voxelsCreated; | 88 | return _tree->voxelsCreated; |
| 77 | } | 89 | } |
| @@ -1137,3 +1149,12 @@ void VoxelSystem::createSphere(float r,float xc, float yc, float zc, float s, bo · 1059 unmodified lines | |||
| 1137 | _tree->createSphere(r, xc, yc, zc, s, solid, mode, destructive, debug); | 1149 | _tree->createSphere(r, xc, yc, zc, s, solid, mode, destructive, debug); |
| 1138 | setupNewVoxelsForDrawing(); | 1150 | setupNewVoxelsForDrawing(); |
| 1139 | }; | 1151 | }; |
| 1152 | |||
| 1153 | void VoxelSystem::copySubTreeIntoNewTree(VoxelNode* startNode, VoxelTree* destinationTree, bool rebaseToRoot) { | ||
| 1154 | _tree->copySubTreeIntoNewTree(startNode, destinationTree, rebaseToRoot); | ||
| 1155 | } | ||
| 1156 | |||
| 1157 | void VoxelSystem::copyFromTreeIntoSubTree(VoxelTree* sourceTree, VoxelNode* destinationNode) { | ||
| 1158 | _tree->copyFromTreeIntoSubTree(sourceTree, destinationNode); | ||
| 1159 | } | ||
| 1160 | |||