BlenderDev/debug
Wikipedia,自由的百科全书
From: http://mediawiki.blender.org/index.php/BlenderDev/SconsRefactoring
Debugging
If you can compile Blender and are interested in development, then youll probably want to debug your code. There are 2 steps to this
1. Compile a debug build 2. Install a debugger
Compiling a debug build
is done by adding "-g" to the compiler flags. Its also a good to turn off optimizing flags like "-O2" when debugging. The resulting exe from a debug build may be 30 to 50 meg.
Installing a Debugger
I tried a few debuggers and insight seemed to be the best. Get Insight.exe here.
just extract it whereever you like.
Open insight\bin\insight.exe and from insight open your debug Blender.exe
Then run blender.exe by pressing the running man icon on the tool bar.
It will automaticaly break at main(), just press the "C" key to launch blender.
If you crash blender, go to View >> Trace and you can see the backtrace and what went wrong.
