History

initial newline removal from all QDebug calls

Stephen Birarda committed 12 years ago

Commit 987c6391 parent a8bbe4172 files · +477 −486Browse files

Showing the changes to interface/src/VoxelSystem.cpp (1 of 72 files). Show all

Unified · Split

interface/src/VoxelSystem.cpp+38−38
@@ -204,7 +204,7 @@ glBufferIndex VoxelSystem::getNextBufferIndex() { · 203 unmodified lines
204204 // will be "invisible"
205205 void VoxelSystem::freeBufferIndex(glBufferIndex index) {
206206 if (_voxelsInWriteArrays == 0) {
207− qDebug() << "freeBufferIndex() called when _voxelsInWriteArrays == 0!!!!\n";
207+ qDebug() << "freeBufferIndex() called when _voxelsInWriteArrays == 0!";
208208 }
209209
210210 // if the "freed" index was our max index, then just drop the _voxelsInWriteArrays down one...
@@ -214,7 +214,7 @@ void VoxelSystem::freeBufferIndex(glBufferIndex index) { · 3 unmodified lines
214214 if (Menu::getInstance()->isOptionChecked(MenuOption::AutomaticallyAuditTree)) {
215215 for (long i = 0; i < _freeIndexes.size(); i++) {
216216 if (_freeIndexes[i] == index) {
217− printf("freeBufferIndex(glBufferIndex index)... index=%ld already in free list!\n", index);
217+ printf("freeBufferIndex(glBufferIndex index)... index=%ld already in free list!", index);
218218 inList = true;
219219 break;
220220 }
@@ -615,7 +615,7 @@ int VoxelSystem::parseData(unsigned char* sourceBuffer, int numBytes) { · 394 unmodified lines
615615 if (Application::getInstance()->getLogger()->extraDebugging()) {
616616 qDebug("VoxelSystem::parseData() ... Got Packet Section"
617617 " color:%s compressed:%s sequence: %u flight:%d usec size:%d data:%d"
618− " subsection:%d sectionLength:%d uncompressed:%d\n",
618+ " subsection:%d sectionLength:%d uncompressed:%d",
619619 debug::valueOf(packetIsColored), debug::valueOf(packetIsCompressed),
620620 sequence, flightTime, numBytes, dataBytes, subsection, sectionLength, packetData.getUncompressedSize());
621621 }
@@ -704,7 +704,7 @@ void VoxelSystem::setupNewVoxelsForDrawing() { · 82 unmodified lines
704704
705705 bool extraDebugging = Application::getInstance()->getLogger()->extraDebugging();
706706 if (extraDebugging) {
707− qDebug("setupNewVoxelsForDrawing()... _voxelsUpdated=%lu...\n",_voxelsUpdated);
707+ qDebug("setupNewVoxelsForDrawing()... _voxelsUpdated=%lu...",_voxelsUpdated);
708708 _viewFrustum->printDebugDetails();
709709 }
710710 }
@@ -801,7 +801,7 @@ void VoxelSystem::cleanupRemovedVoxels() { · 90 unmodified lines
801801 // This handles cleanup of voxels that were culled as part of our regular out of view culling operation
802802 if (!_removedVoxels.isEmpty()) {
803803 if (Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings)) {
804− qDebug() << "cleanupRemovedVoxels().. _removedVoxels=" << _removedVoxels.count() << "\n";
804+ qDebug() << "cleanupRemovedVoxels().. _removedVoxels=" << _removedVoxels.count();
805805 }
806806 while (!_removedVoxels.isEmpty()) {
807807 delete _removedVoxels.extract();
@@ -815,7 +815,7 @@ void VoxelSystem::cleanupRemovedVoxels() { · 7 unmodified lines
815815 if (!_writeRenderFullVBO && (_abandonedVBOSlots > (_voxelsInWriteArrays * TOO_MANY_ABANDONED_RATIO))) {
816816 if (Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings)) {
817817 qDebug() << "cleanupRemovedVoxels().. _abandonedVBOSlots ["
818− << _abandonedVBOSlots << "] > TOO_MANY_ABANDONED_RATIO \n";
818+ << _abandonedVBOSlots << "] > TOO_MANY_ABANDONED_RATIO";
819819 }
820820 _writeRenderFullVBO = true;
821821 }
@@ -982,7 +982,7 @@ int VoxelSystem::updateNodeInArrays(VoxelTreeElement* node, bool reuseIndex, boo · 160 unmodified lines
982982 // possibly shifting down to lower LOD or something. This debug message is to help identify, if/when/how this
983983 // state actually occurs.
984984 if (Application::getInstance()->getLogger()->extraDebugging()) {
985− qDebug("OHHHH NOOOOOO!!!! updateNodeInArrays() BAILING (_voxelsInWriteArrays >= _maxVoxels)\n");
985+ qDebug("OH NO! updateNodeInArrays() BAILING (_voxelsInWriteArrays >= _maxVoxels)");
986986 }
987987 return 0;
988988 }
@@ -1062,7 +1062,7 @@ ProgramObject VoxelSystem::_shadowMapProgram; · 73 unmodified lines
10621062
10631063 void VoxelSystem::init() {
10641064 if (_initialized) {
1065− qDebug("[ERROR] VoxelSystem is already initialized.\n");
1065+ qDebug("[ERROR] VoxelSystem is already initialized.");
10661066 return;
10671067 }
10681068
@@ -1436,7 +1436,7 @@ void VoxelSystem::clearAllNodesBufferIndex() { · 367 unmodified lines
14361436 _tree->recurseTreeWithOperation(clearAllNodesBufferIndexOperation);
14371437 unlockTree();
14381438 if (Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings)) {
1439− qDebug("clearing buffer index of %d nodes\n", _nodeCount);
1439+ qDebug("clearing buffer index of %d nodes", _nodeCount);
14401440 }
14411441 }
14421442
@@ -1449,7 +1449,7 @@ bool VoxelSystem::forceRedrawEntireTreeOperation(OctreeElement* element, void* e · 6 unmodified lines
14491449 void VoxelSystem::forceRedrawEntireTree() {
14501450 _nodeCount = 0;
14511451 _tree->recurseTreeWithOperation(forceRedrawEntireTreeOperation);
1452− qDebug("forcing redraw of %d nodes\n", _nodeCount);
1452+ qDebug("forcing redraw of %d nodes", _nodeCount);
14531453 _tree->setDirtyBit();
14541454 setupNewVoxelsForDrawing();
14551455 }
@@ -1467,7 +1467,7 @@ bool VoxelSystem::randomColorOperation(OctreeElement* element, void* extraData) · 11 unmodified lines
14671467 void VoxelSystem::randomizeVoxelColors() {
14681468 _nodeCount = 0;
14691469 _tree->recurseTreeWithOperation(randomColorOperation);
1470− qDebug("setting randomized true color for %d nodes\n", _nodeCount);
1470+ qDebug("setting randomized true color for %d nodes", _nodeCount);
14711471 _tree->setDirtyBit();
14721472 setupNewVoxelsForDrawing();
14731473 }
@@ -1483,7 +1483,7 @@ bool VoxelSystem::falseColorizeRandomOperation(OctreeElement* element, void* ext · 9 unmodified lines
14831483 void VoxelSystem::falseColorizeRandom() {
14841484 _nodeCount = 0;
14851485 _tree->recurseTreeWithOperation(falseColorizeRandomOperation);
1486− qDebug("setting randomized false color for %d nodes\n", _nodeCount);
1486+ qDebug("setting randomized false color for %d nodes", _nodeCount);
14871487 _tree->setDirtyBit();
14881488 setupNewVoxelsForDrawing();
14891489 }
@@ -1499,7 +1499,7 @@ void VoxelSystem::trueColorize() { · 9 unmodified lines
14991499 PerformanceWarning warn(true, "trueColorize()",true);
15001500 _nodeCount = 0;
15011501 _tree->recurseTreeWithOperation(trueColorizeOperation);
1502− qDebug("setting true color for %d nodes\n", _nodeCount);
1502+ qDebug("setting true color for %d nodes", _nodeCount);
15031503 _tree->setDirtyBit();
15041504 setupNewVoxelsForDrawing();
15051505 }
@@ -1521,7 +1521,7 @@ bool VoxelSystem::falseColorizeInViewOperation(OctreeElement* element, void* ext · 15 unmodified lines
15211521 void VoxelSystem::falseColorizeInView() {
15221522 _nodeCount = 0;
15231523 _tree->recurseTreeWithOperation(falseColorizeInViewOperation,(void*)_viewFrustum);
1524− qDebug("setting in view false color for %d nodes\n", _nodeCount);
1524+ qDebug("setting in view false color for %d nodes", _nodeCount);
15251525 _tree->setDirtyBit();
15261526 setupNewVoxelsForDrawing();
15271527 }
@@ -1626,7 +1626,7 @@ void VoxelSystem::falseColorizeBySource() { · 98 unmodified lines
16261626 }
16271627
16281628 _tree->recurseTreeWithOperation(falseColorizeBySourceOperation, &args);
1629− qDebug("setting false color by source for %d nodes\n", _nodeCount);
1629+ qDebug("setting false color by source for %d nodes", _nodeCount);
16301630 _tree->setDirtyBit();
16311631 setupNewVoxelsForDrawing();
16321632 }
@@ -1679,10 +1679,10 @@ void VoxelSystem::falseColorizeDistanceFromView() { · 46 unmodified lines
16791679 _maxDistance = 0.0;
16801680 _minDistance = FLT_MAX;
16811681 _tree->recurseTreeWithOperation(getDistanceFromViewRangeOperation, (void*) _viewFrustum);
1682− qDebug("determining distance range for %d nodes\n", _nodeCount);
1682+ qDebug("determining distance range for %d nodes", _nodeCount);
16831683 _nodeCount = 0;
16841684 _tree->recurseTreeWithOperation(falseColorizeDistanceFromViewOperation, (void*) _viewFrustum);
1685− qDebug("setting in distance false color for %d nodes\n", _nodeCount);
1685+ qDebug("setting in distance false color for %d nodes", _nodeCount);
16861686 _tree->setDirtyBit();
16871687 setupNewVoxelsForDrawing();
16881688 }
@@ -1813,7 +1813,7 @@ void VoxelSystem::removeOutOfView() { · 124 unmodified lines
18131813 }
18141814 bool showRemoveDebugDetails = false;
18151815 if (showRemoveDebugDetails) {
1816− qDebug("removeOutOfView() scanned=%ld removed=%ld inside=%ld intersect=%ld outside=%ld _removedVoxels.count()=%d \n",
1816+ qDebug("removeOutOfView() scanned=%ld removed=%ld inside=%ld intersect=%ld outside=%ld _removedVoxels.count()=%d",
18171817 args.nodesScanned, args.nodesRemoved, args.nodesInside,
18181818 args.nodesIntersect, args.nodesOutside, _removedVoxels.count()
18191819 );
@@ -1842,7 +1842,7 @@ void VoxelSystem::showAllLocalVoxels() { · 22 unmodified lines
18421842
18431843 bool showRemoveDebugDetails = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);
18441844 if (showRemoveDebugDetails) {
1845− qDebug("showAllLocalVoxels() scanned=%ld \n",args.nodesScanned );
1845+ qDebug("showAllLocalVoxels() scanned=%ld",args.nodesScanned );
18461846 }
18471847 }
18481848
@@ -1979,15 +1979,15 @@ void VoxelSystem::hideOutOfView(bool forceFullFrustum) { · 130 unmodified lines
19791979
19801980 bool extraDebugDetails = false; // Application::getInstance()->getLogger()->extraDebugging();
19811981 if (extraDebugDetails) {
1982− qDebug("hideOutOfView() scanned=%ld removed=%ld show=%ld inside=%ld intersect=%ld outside=%ld\n",
1982+ qDebug("hideOutOfView() scanned=%ld removed=%ld show=%ld inside=%ld intersect=%ld outside=%ld",
19831983 args.nodesScanned, args.nodesRemoved, args.nodesShown, args.nodesInside,
19841984 args.nodesIntersect, args.nodesOutside
19851985 );
1986− qDebug(" inside/inside=%ld intersect/inside=%ld outside/outside=%ld\n",
1986+ qDebug("inside/inside=%ld intersect/inside=%ld outside/outside=%ld",
19871987 args.nodesInsideInside, args.nodesIntersectInside, args.nodesOutsideOutside
19881988 );
19891989
1990− qDebug() << "args.thisViewFrustum....\n";
1990+ qDebug() << "args.thisViewFrustum....";
19911991 args.thisViewFrustum.printDebugDetails();
19921992 }
19931993 _inhideOutOfView = false;
@@ -2224,7 +2224,7 @@ bool VoxelSystem::falseColorizeRandomEveryOtherOperation(OctreeElement* element, · 230 unmodified lines
22242224 void VoxelSystem::falseColorizeRandomEveryOther() {
22252225 falseColorizeRandomEveryOtherArgs args;
22262226 _tree->recurseTreeWithOperation(falseColorizeRandomEveryOtherOperation,&args);
2227− qDebug("randomized false color for every other node: total %ld, colorable %ld, colored %ld\n",
2227+ qDebug("randomized false color for every other node: total %ld, colorable %ld, colored %ld",
22282228 args.totalNodes, args.colorableNodes, args.coloredNodes);
22292229 _tree->setDirtyBit();
22302230 setupNewVoxelsForDrawing();
@@ -2294,14 +2294,14 @@ bool VoxelSystem::collectStatsForTreesAndVBOsOperation(OctreeElement* element, v · 63 unmodified lines
22942294
22952295 const bool extraDebugging = false; // enable for extra debugging
22962296 if (extraDebugging) {
2297− qDebug("node In VBO... [%f,%f,%f] %f ... index=%ld, isDirty=%s, shouldRender=%s \n",
2297+ qDebug("node In VBO... [%f,%f,%f] %f ... index=%ld, isDirty=%s, shouldRender=%s",
22982298 voxel->getCorner().x, voxel->getCorner().y, voxel->getCorner().z, voxel->getScale(),
22992299 nodeIndex, debug::valueOf(voxel->isDirty()), debug::valueOf(voxel->getShouldRender()));
23002300 }
23012301
23022302 if (args->hasIndexFound[nodeIndex]) {
23032303 args->duplicateVBOIndex++;
2304− qDebug("duplicateVBO found... index=%ld, isDirty=%s, shouldRender=%s \n", nodeIndex,
2304+ qDebug("duplicateVBO found... index=%ld, isDirty=%s, shouldRender=%s", nodeIndex,
23052305 debug::valueOf(voxel->isDirty()), debug::valueOf(voxel->getShouldRender()));
23062306 } else {
23072307 args->hasIndexFound[nodeIndex] = true;
@@ -2335,17 +2335,17 @@ void VoxelSystem::collectStatsForTreesAndVBOs() { · 27 unmodified lines
23352335 collectStatsForTreesAndVBOsArgs args(_maxVoxels);
23362336 args.expectedMax = _voxelsInWriteArrays;
23372337
2338− qDebug("CALCULATING Local Voxel Tree Statistics >>>>>>>>>>>>\n");
2338+ qDebug("CALCULATING Local Voxel Tree Statistics >>>>>>>>>>>>");
23392339
23402340 _tree->recurseTreeWithOperation(collectStatsForTreesAndVBOsOperation,&args);
23412341
2342− qDebug("Local Voxel Tree Statistics:\n total nodes %ld \n leaves %ld \n dirty %ld \n colored %ld \n shouldRender %ld \n",
2342+ qDebug("Local Voxel Tree Statistics:\n total nodes %ld \n leaves %ld \n dirty %ld \n colored %ld \n shouldRender %ld",
23432343 args.totalNodes, args.leafNodes, args.dirtyNodes, args.coloredNodes, args.shouldRenderNodes);
23442344
2345− qDebug(" _voxelsDirty=%s \n _voxelsInWriteArrays=%ld \n minDirty=%ld \n maxDirty=%ld \n", debug::valueOf(_voxelsDirty),
2345+ qDebug(" _voxelsDirty=%s \n _voxelsInWriteArrays=%ld \n minDirty=%ld \n maxDirty=%ld", debug::valueOf(_voxelsDirty),
23462346 _voxelsInWriteArrays, minDirty, maxDirty);
23472347
2348− qDebug(" inVBO %ld \n nodesInVBOOverExpectedMax %ld \n duplicateVBOIndex %ld \n nodesInVBONotShouldRender %ld \n",
2348+ qDebug(" inVBO %ld \n nodesInVBOOverExpectedMax %ld \n duplicateVBOIndex %ld \n nodesInVBONotShouldRender %ld",
23492349 args.nodesInVBO, args.nodesInVBOOverExpectedMax, args.duplicateVBOIndex, args.nodesInVBONotShouldRender);
23502350
23512351 glBufferIndex minInVBO = GLBUFFER_INDEX_UNKNOWN;
@@ -2358,13 +2358,13 @@ void VoxelSystem::collectStatsForTreesAndVBOs() { · 6 unmodified lines
23582358 }
23592359 }
23602360
2361− qDebug(" minInVBO=%ld \n maxInVBO=%ld \n _voxelsInWriteArrays=%ld \n _voxelsInReadArrays=%ld \n",
2361+ qDebug(" minInVBO=%ld \n maxInVBO=%ld \n _voxelsInWriteArrays=%ld \n _voxelsInReadArrays=%ld",
23622362 minInVBO, maxInVBO, _voxelsInWriteArrays, _voxelsInReadArrays);
23632363
2364− qDebug(" _freeIndexes.size()=%ld \n",
2364+ qDebug(" _freeIndexes.size()=%ld",
23652365 _freeIndexes.size());
23662366
2367− qDebug("DONE WITH Local Voxel Tree Statistics >>>>>>>>>>>>\n");
2367+ qDebug("DONE WITH Local Voxel Tree Statistics >>>>>>>>>>>>");
23682368 }
23692369
23702370
@@ -2550,7 +2550,7 @@ void VoxelSystem::falseColorizeOccluded() { · 179 unmodified lines
25502550
25512551 _tree->recurseTreeWithOperationDistanceSorted(falseColorizeOccludedOperation, position, (void*)&args);
25522552
2553− qDebug("falseColorizeOccluded()\n position=(%f,%f)\n total=%ld\n colored=%ld\n occluded=%ld\n notOccluded=%ld\n outOfView=%ld\n subtreeVoxelsSkipped=%ld\n nonLeaves=%ld\n nonLeavesOutOfView=%ld\n nonLeavesOccluded=%ld\n pointInside_calls=%ld\n occludes_calls=%ld\n intersects_calls=%ld\n",
2553+ qDebug("falseColorizeOccluded()\n position=(%f,%f)\n total=%ld\n colored=%ld\n occluded=%ld\n notOccluded=%ld\n outOfView=%ld\n subtreeVoxelsSkipped=%ld\n nonLeaves=%ld\n nonLeavesOutOfView=%ld\n nonLeavesOccluded=%ld\n pointInside_calls=%ld\n occludes_calls=%ld\n intersects_calls=%ld",
25542554 position.x, position.y,
25552555 args.totalVoxels, args.coloredVoxels, args.occludedVoxels,
25562556 args.notOccludedVoxels, args.outOfView, args.subtreeVoxelsSkipped,
@@ -2685,7 +2685,7 @@ void VoxelSystem::falseColorizeOccludedV2() { · 128 unmodified lines
26852685
26862686 void VoxelSystem::nodeAdded(Node* node) {
26872687 if (node->getType() == NODE_TYPE_VOXEL_SERVER) {
2688− qDebug("VoxelSystem... voxel server %s added...\n", node->getUUID().toString().toLocal8Bit().constData());
2688+ qDebug("VoxelSystem... voxel server %s added...", node->getUUID().toString().toLocal8Bit().constData());
26892689 _voxelServerCount++;
26902690 }
26912691 }
@@ -2708,7 +2708,7 @@ void VoxelSystem::nodeKilled(Node* node) { · 16 unmodified lines
27082708 if (node->getType() == NODE_TYPE_VOXEL_SERVER) {
27092709 _voxelServerCount--;
27102710 QUuid nodeUUID = node->getUUID();
2711− qDebug("VoxelSystem... voxel server %s removed...\n", nodeUUID.toString().toLocal8Bit().constData());
2711+ qDebug("VoxelSystem... voxel server %s removed...", nodeUUID.toString().toLocal8Bit().constData());
27122712 }
27132713 }
27142714
@@ -2777,7 +2777,7 @@ void VoxelSystem::unlockTree() { · 62 unmodified lines
27772777
27782778
27792779 void VoxelSystem::localVoxelCacheLoaded() {
2780− qDebug() << "localVoxelCacheLoaded()\n";
2780+ qDebug() << "localVoxelCacheLoaded()";
27812781
27822782 // Make sure that the application has properly set up the view frustum for our loaded state
27832783 Application::getInstance()->initAvatarAndViewFrustum();
@@ -2790,11 +2790,11 @@ void VoxelSystem::localVoxelCacheLoaded() { · 6 unmodified lines
27902790 }
27912791
27922792 void VoxelSystem::beginLoadingLocalVoxelCache() {
2793− qDebug() << "beginLoadingLocalVoxelCache()\n";
2793+ qDebug() << "beginLoadingLocalVoxelCache()";
27942794 _writeRenderFullVBO = true; // this will disable individual node updates
27952795 _inhideOutOfView = true; // this will disable hidOutOfView which we want to do until local cache is loaded
27962796 killLocalVoxels();
2797− qDebug() << "DONE beginLoadingLocalVoxelCache()\n";
2797+ qDebug() << "DONE beginLoadingLocalVoxelCache()";
27982798 }
27992799
28002800

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