Merge branch 'blender-v2.81-release'
This commit is contained in:
commit
76e8d2cc17
@ -125,7 +125,7 @@ struct Scene *BKE_scene_find_from_collection(const struct Main *bmain,
|
||||
#ifdef DURIAN_CAMERA_SWITCH
|
||||
struct Object *BKE_scene_camera_switch_find(struct Scene *scene); // DURIAN_CAMERA_SWITCH
|
||||
#endif
|
||||
int BKE_scene_camera_switch_update(struct Scene *scene);
|
||||
bool BKE_scene_camera_switch_update(struct Scene *scene);
|
||||
|
||||
char *BKE_scene_find_marker_name(struct Scene *scene, int frame);
|
||||
char *BKE_scene_find_last_marker_name(struct Scene *scene, int frame);
|
||||
|
@ -1008,19 +1008,19 @@ Object *BKE_scene_camera_switch_find(Scene *scene)
|
||||
}
|
||||
#endif
|
||||
|
||||
int BKE_scene_camera_switch_update(Scene *scene)
|
||||
bool BKE_scene_camera_switch_update(Scene *scene)
|
||||
{
|
||||
#ifdef DURIAN_CAMERA_SWITCH
|
||||
Object *camera = BKE_scene_camera_switch_find(scene);
|
||||
if (camera) {
|
||||
if (camera && (camera != scene->camera)) {
|
||||
scene->camera = camera;
|
||||
DEG_id_tag_update(&scene->id, ID_RECALC_COPY_ON_WRITE);
|
||||
return 1;
|
||||
return true;
|
||||
}
|
||||
#else
|
||||
(void)scene;
|
||||
#endif
|
||||
return 0;
|
||||
return false;
|
||||
}
|
||||
|
||||
char *BKE_scene_find_marker_name(Scene *scene, int frame)
|
||||
|
@ -88,7 +88,11 @@ static void rna_Scene_frame_set(Scene *scene, Main *bmain, int frame, float subf
|
||||
BPy_END_ALLOW_THREADS;
|
||||
# endif
|
||||
|
||||
BKE_scene_camera_switch_update(scene);
|
||||
if (BKE_scene_camera_switch_update(scene)) {
|
||||
for (bScreen *sc = bmain->screens.first; sc; sc = sc->id.next) {
|
||||
BKE_screen_view3d_scene_sync(sc, scene);
|
||||
}
|
||||
}
|
||||
|
||||
/* don't do notifier when we're rendering, avoid some viewport crashes
|
||||
* redrawing while the data is being modified for render */
|
||||
|
Loading…
Reference in New Issue
Block a user