diff options
author | Maxime Curioni <maxime.curioni@gmail.com> | 2009-04-09 00:19:20 +0400 |
---|---|---|
committer | Maxime Curioni <maxime.curioni@gmail.com> | 2009-04-09 00:19:20 +0400 |
commit | 8c8579d911c7bb9ceaf1e28a26950e6db882a79d (patch) | |
tree | ec17d7b929367846a221f010f1a188fc5341dce3 | |
parent | 997624c7ddad836080e54d5b488169954bc77b35 (diff) |
Made the calculation of the number of available style modules more robust
-rw-r--r-- | source/blender/freestyle/intern/app_blender/FRS_freestyle.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/freestyle/intern/app_blender/FRS_freestyle.cpp b/source/blender/freestyle/intern/app_blender/FRS_freestyle.cpp index 95d0a5f7fa1..d780191ce94 100644 --- a/source/blender/freestyle/intern/app_blender/FRS_freestyle.cpp +++ b/source/blender/freestyle/intern/app_blender/FRS_freestyle.cpp @@ -227,6 +227,9 @@ extern "C" { int displayed_layer_count( SceneRenderLayer* srl ) { int count = 0; + + if( panelConfig->layers.find(srl) == panelConfig->layers.end() ) + return 0; for( StyleModuleConf* module_conf = (StyleModuleConf *)panelConfig->modules[srl]->first; module_conf; module_conf = module_conf->next ) { if( module_conf->is_displayed ) |