This commit is contained in:
ZappoMan 2013-03-29 09:12:52 -07:00
parent 9e308f4821
commit f7df625439
2 changed files with 4 additions and 1 deletions

View file

@ -97,6 +97,7 @@ bool VoxelNode::collapseIdenticalLeaves() {
if (allChildrenMatch) {
printf("allChildrenMatch: pruning tree\n");
for (int i = 0; i < 8; i++) {
delete children[i]; // delete all the child nodes
children[i]=NULL; // set it to NULL

View file

@ -528,7 +528,7 @@ void VoxelTree::createSphere(float r,float xc, float yc, float zc, float s, bool
// only use our actual desired color on the outer edge, otherwise
// use our "average" color
if (ri+(s*2.0)>=r) {
printf("painting candy shell radius: ri=%f r=%f\n",ri,r);
//printf("painting candy shell radius: ri=%f r=%f\n",ri,r);
red = wantColorRandomizer ? randomColorValue(165) : r1+((r2-r1)*gradient);
green = wantColorRandomizer ? randomColorValue(165) : g1+((g2-g1)*gradient);
blue = wantColorRandomizer ? randomColorValue(165) : b1+((b2-b1)*gradient);
@ -536,6 +536,8 @@ void VoxelTree::createSphere(float r,float xc, float yc, float zc, float s, bool
unsigned char* voxelData = pointToVoxel(x,y,z,s,red,green,blue);
this->readCodeColorBufferToTree(voxelData);
printf("voxel data for x:%f y:%f z:%f s:%f\n",x,y,z,s);
printVoxelCode(voxelData);
delete voxelData;
}
}