diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-01-12 22:45:01 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-01-12 22:45:01 +0300 |
commit | 6a0308aad332137c0b6f22152a439ca0f73914da (patch) | |
tree | 821692dc6ebdefb806106dd58d9fb5be87072169 /source/blender/render/intern/raytrace/rayobject_vbvh.cpp | |
parent | 000dcc7ad767511baec0e88b4e88b24c5667ef7e (diff) |
Raytrace: only print debug info when running with -d option.
Diffstat (limited to 'source/blender/render/intern/raytrace/rayobject_vbvh.cpp')
-rw-r--r-- | source/blender/render/intern/raytrace/rayobject_vbvh.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/render/intern/raytrace/rayobject_vbvh.cpp b/source/blender/render/intern/raytrace/rayobject_vbvh.cpp index 4a2a56fa8ef..6185be324d6 100644 --- a/source/blender/render/intern/raytrace/rayobject_vbvh.cpp +++ b/source/blender/render/intern/raytrace/rayobject_vbvh.cpp @@ -37,6 +37,7 @@ int tot_hints = 0; #include "RE_raytrace.h" #include "BLI_memarena.h" #include "MEM_guardedalloc.h" +#include "BKE_global.h" #include "BKE_utildefines.h" #include "BLI_math.h" @@ -145,10 +146,13 @@ void bfree(VBVHTree *tree) { if(tot_pushup + tot_pushdown + tot_hints + tot_moves) { - printf("tot pushups: %d\n", tot_pushup); - printf("tot pushdowns: %d\n", tot_pushdown); - printf("tot moves: %d\n", tot_moves); - printf("tot hints created: %d\n", tot_hints); + if(G.f & G_DEBUG) { + printf("tot pushups: %d\n", tot_pushup); + printf("tot pushdowns: %d\n", tot_pushdown); + printf("tot moves: %d\n", tot_moves); + printf("tot hints created: %d\n", tot_hints); + } + tot_pushup = 0; tot_pushdown = 0; tot_hints = 0; |