Page MenuHome

Cycles: Use special debug panel to fine-tune debug flags
ClosedPublic

Authored by Sergey Sharybin (sergey) on Jan 9 2016, 12:54 PM.

Details

Summary

This panel is only visible when debug_value is set to 256 and has no
affect in other cases. However, if debug value is not set to this
value, environment variables will be used to control which features
are enabled, so there's no visible changes to anyone in fact.

There are some changes needed to prevent devices re-enumeration on
every Cycles session create.

Diff Detail

Repository
rB Blender

Event Timeline

Sergey Sharybin (sergey) retitled this revision from to Cycles: Use special debug panel to fine-tune debug flags.
Sergey Sharybin (sergey) updated this object.
Lukas Stockner (lukasstockner97) edited edge metadata.

Nice patch, seems useful for debugging!
Another option that might be useful for debugging/benchmarking would be a Tile Size and Samples override via environment variables, but that's probably out of scope for this patch.

intern/cycles/device/device.h
193

Diff Noise

intern/cycles/util/util_debug.cpp
38

Am I missing something or is GLUE unused?

This revision is now accepted and ready to land.Jan 9 2016, 1:11 PM
Sergey Sharybin (sergey) marked an inline comment as done.
Sergey Sharybin (sergey) edited edge metadata.

Cleanup for the review from Lukas

Sergey Sharybin (sergey) marked an inline comment as done.Jan 9 2016, 3:49 PM

As for the samples override -- this should be done in the same way as "progressive samples" option which i need to extract from Gooseberry branch in a nice way. Tile size -- not so sure that much, you can do:

blender --python-expr="import bpy; bpy.data.scenes['foo'].render.tile_x = 100; bpy.data.scenes['foo'].render.tile_y = 200"

Don't really think we should add environment variables for the stuff which we can control via RNA.

intern/cycles/device/device.h
193

Removed.

intern/cycles/util/util_debug.cpp
38

Yes, was used in intermediate path version. Unneeded now. Removed.

Why not use --debug-cycles to enable this?

Sergey Sharybin (sergey) marked an inline comment as done.Jan 9 2016, 6:00 PM

The idea was to avoid need of any terminal/commandline magic for users. So we can easily ask reporters to test something without describing what the command line is and what exactly to type in there.

Another side, is that one might not really want the intense logging and only wants to tweak some values in order to test particular stuff.

Thomas Dinges (dingto) edited edge metadata.

A very welcome addition. :)

Sergey Sharybin (sergey) edited edge metadata.

Updates:

  • Solved remaining TODOs
  • Added some comments and logging
  • Seems we all agree on the idea now so will be committing soon.
This revision was automatically updated to reflect the committed changes.