History

first major pass at voxelEctomy

ZappoMan committed 11 years ago

Commit 4ea9bbc1 parent 2a129b665 files · +43 −5956Browse files

Showing the changes to interface/src/ui/Stats.cpp (1 of 65 files). Show all

Unified · Split

interface/src/ui/Stats.cpp+3−37
@@ -471,8 +471,6 @@ void Stats::display( · 470 unmodified lines
471471 verticalOffset = 0;
472472 horizontalOffset = _lastHorizontalOffset + _generalStatsWidth + _pingStatsWidth + _geoStatsWidth + 3;
473473
474− VoxelSystem* voxels = Application::getInstance()->getVoxels();
475−
476474 lines = _expanded ? 14 : 3;
477475
478476 drawBackground(backgroundColor, horizontalOffset, 0, glCanvas->width() - horizontalOffset,
@@ -510,38 +508,6 @@ void Stats::display( · 31 unmodified lines
510508 drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
511509 }
512510
513− voxelStats.str("");
514− voxelStats.precision(4);
515− voxelStats << "Voxels Drawn: " << voxels->getVoxelsWritten() / 1000.0f << "K " <<
516− "Abandoned: " << voxels->getAbandonedVoxels() / 1000.0f << "K ";
517− verticalOffset += STATS_PELS_PER_LINE;
518− drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
519−
520− if (_expanded) {
521− // Local Voxel Memory Usage
522− voxelStats.str("");
523− voxelStats << " Voxels Memory Nodes: " << VoxelTreeElement::getTotalMemoryUsage() / 1000000.0f << "MB";
524− verticalOffset += STATS_PELS_PER_LINE;
525− drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
526−
527− voxelStats.str("");
528− voxelStats <<
529− " Geometry RAM: " << voxels->getVoxelMemoryUsageRAM() / 1000000.0f << "MB / " <<
530− "VBO: " << voxels->getVoxelMemoryUsageVBO() / 1000000.0f << "MB";
531− if (voxels->hasVoxelMemoryUsageGPU()) {
532− voxelStats << " / GPU: " << voxels->getVoxelMemoryUsageGPU() / 1000000.0f << "MB";
533− }
534− verticalOffset += STATS_PELS_PER_LINE;
535− drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
536−
537− // Voxel Rendering
538− voxelStats.str("");
539− voxelStats.precision(4);
540− voxelStats << " Voxel Rendering Slots Max: " << voxels->getMaxVoxels() / 1000.0f << "K";
541− verticalOffset += STATS_PELS_PER_LINE;
542− drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
543− }
544−
545511 // iterate all the current voxel stats, and list their sending modes, and total voxel counts
546512 std::stringstream sendingMode("");
547513 sendingMode << "Octree Sending Mode: [";
@@ -612,7 +578,7 @@ void Stats::display( · 64 unmodified lines
612578 }
613579
614580 QString serversTotalString = locale.toString((uint)totalNodes); // consider adding: .rightJustified(10, ' ');
615− unsigned long localTotal = VoxelTreeElement::getNodeCount();
581+ unsigned long localTotal = OctreeElement::getNodeCount();
616582 QString localTotalString = locale.toString((uint)localTotal); // consider adding: .rightJustified(10, ' ');
617583
618584 // Server Octree Elements
@@ -641,8 +607,8 @@ void Stats::display( · 22 unmodified lines
641607 drawText(horizontalOffset, verticalOffset, scale, rotation, font, (char*)voxelStats.str().c_str(), color);
642608
643609 // Local Voxels
644− unsigned long localInternal = VoxelTreeElement::getInternalNodeCount();
645− unsigned long localLeaves = VoxelTreeElement::getLeafNodeCount();
610+ unsigned long localInternal = OctreeElement::getInternalNodeCount();
611+ unsigned long localLeaves = OctreeElement::getLeafNodeCount();
646612 QString localInternalString = locale.toString((uint)localInternal);
647613 QString localLeavesString = locale.toString((uint)localLeaves);
648614

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t