Display animation data from lamps' node trees in animation editor windows
authorSergey Sharybin <sergey.vfx@gmail.com>
Thu, 26 Jul 2012 16:11:59 +0000 (16:11 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Thu, 26 Jul 2012 16:11:59 +0000 (16:11 +0000)
source/blender/editors/animation/anim_filter.c

index 1dcb9f79a0953e4de02ec7ac21ab4f06b5b3c79c..07e773b1e9abdb53348ba072ff15f7e9ddd67277 100644 (file)
@@ -1806,11 +1806,18 @@ static size_t animdata_filter_ds_obdata(bAnimContext *ac, ListBase *anim_data, b
                
                /* sub-data filtering... */
                switch (ob->type) {
-                       case OB_LAMP:  /* lamp - textures */
+                       case OB_LAMP:  /* lamp - textures + nodetree */
                        {
+                               Lamp *la = ob->data;
+                               bNodeTree *ntree = la->nodetree;
+
+                               /* nodetree */
+                               if ((ntree) && !(ads->filterflag & ADS_FILTER_NONTREE))
+                                       tmp_items += animdata_filter_ds_nodetree(ac, &tmp_data, ads, &la->id, ntree, filter_mode);
+
                                /* textures */
                                if (!(ads->filterflag & ADS_FILTER_NOTEX))
-                                       tmp_items += animdata_filter_ds_textures(ac, &tmp_data, ads, ob->data, filter_mode);
+                                       tmp_items += animdata_filter_ds_textures(ac, &tmp_data, ads, &la->id, filter_mode);
                        }
                        break;
                }