Cycles-Bake: Unset properties fallback only working for invoke
authorDalai Felinto <dfelinto@gmail.com>
Mon, 4 Jan 2016 14:13:52 +0000 (12:13 -0200)
committerDalai Felinto <dfelinto@gmail.com>
Mon, 4 Jan 2016 15:20:34 +0000 (13:20 -0200)
source/blender/editors/object/object_bake_api.c

index 93f9856b51a30cda7f881c1e66252e422c332e70..616c43704484216908f25b0e864b9f8c3abd91a7 100644 (file)
@@ -76,6 +76,8 @@
 
 #include "object_intern.h"
 
+/* prototypes */
+static void bake_set_props(wmOperator *op, Scene *scene);
 
 typedef struct BakeAPIRender {
        Object *ob;
@@ -1078,6 +1080,9 @@ static int bake_exec(bContext *C, wmOperator *op)
        Render *re;
        int result = OPERATOR_CANCELLED;
        BakeAPIRender bkr = {NULL};
+       Scene *scene = CTX_data_scene(C);
+
+       bake_set_props(op, scene);
 
        bake_init_api_data(op, C, &bkr);
        re = bkr.render;