diff options
author | Ton Roosendaal <ton@blender.org> | 2006-07-20 14:36:55 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2006-07-20 14:36:55 +0400 |
commit | 0128c401b9d765ac83dc243f83039a488d3505c7 (patch) | |
tree | 655ef2c288e60fc17e6a4e2c5888cf9752079fa0 /source/blender/src | |
parent | 60f3a338553f9c8fb2a13479c170986109c176e7 (diff) |
Bugfix #4741
Ancient issue; when you press keypad-0, it should assign the active camera
object to a scene, but this did not happen when that camera was already
assigned to the active 3d view. A rare case, causing 'error no camera' on
a render.
Diffstat (limited to 'source/blender/src')
-rw-r--r-- | source/blender/src/toets.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/src/toets.c b/source/blender/src/toets.c index 15a6fe1d420..93d38ad6b34 100644 --- a/source/blender/src/toets.c +++ b/source/blender/src/toets.c @@ -259,8 +259,9 @@ void persptoetsen(unsigned short event) handle_view3d_lock(); } else if(BASACT) { + /* check both G.vd as G.scene cameras */ if(G.qual==LR_CTRLKEY) { - if(G.vd->camera != OBACT) { + if(G.vd->camera != OBACT || G.scene->camera != OBACT) { if(G.vd->camera && G.vd->camera->type==OB_CAMERA) oldcamera= G.vd->camera; @@ -268,7 +269,7 @@ void persptoetsen(unsigned short event) handle_view3d_lock(); } } - else if(G.vd->camera==0 && OBACT->type==OB_CAMERA) { + else if((G.vd->camera==NULL || G.scene->camera==NULL) && OBACT->type==OB_CAMERA) { G.vd->camera= OBACT; handle_view3d_lock(); } |