merged 28885 frame update fix to trunk, slightly updated
authorJoseph Eagar <joeedh@gmail.com>
Thu, 20 May 2010 15:18:55 +0000 (15:18 +0000)
committerJoseph Eagar <joeedh@gmail.com>
Thu, 20 May 2010 15:18:55 +0000 (15:18 +0000)
source/blender/editors/render/render_opengl.c

index ee5363a00f997df46d7577eb96c15efa82e306c9..aded83c0d165a4228309195574abf973ebef0f60 100644 (file)
@@ -211,7 +211,7 @@ static void screen_opengl_render_end(bContext *C, OGLRender *oglrender)
 
        if(oglrender->timer) { /* exec will not have a timer */
                scene->r.cfra= oglrender->cfrao;
-               scene_update_for_newframe(scene, scene->lay);
+               scene_update_for_newframe(scene, scene->lay|oglrender->v3d->lay);
 
                WM_event_remove_timer(CTX_wm_manager(C), CTX_wm_window(C), oglrender->timer);
        }
@@ -268,16 +268,16 @@ static int screen_opengl_render_anim_step(bContext *C, wmOperator *op)
 
        /* go to next frame */
        while(CFRA<oglrender->nfra) {
-               if(scene->lay & 0xFF000000)
-                       lay= scene->lay & 0xFF000000;
-               else
-                       lay= scene->lay;
+               lay = scene->lay | oglrender->v3d->lay;
+
+               if(lay & 0xFF000000)
+                       lay &= 0xFF000000;
 
                scene_update_for_newframe(scene, lay);
                CFRA++;
        }
-
-       scene_update_for_newframe(scene, scene->lay);
+       
+       scene_update_for_newframe(scene, scene->lay | oglrender->v3d->lay);
 
        if(oglrender->rv3d->persp==RV3D_CAMOB && oglrender->v3d->camera && oglrender->v3d->scenelock) {
                /* since scene_update_for_newframe() is used rather