[Bf-blender-cvs] [79476a9c0ab] master: Tracking: Selection Crash

Jeroen Bakker noreply at git.blender.org
Mon Dec 30 09:25:21 CET 2019


Commit: 79476a9c0ab9e3f29d32a87aa8f9d859f2961cb9
Author: Jeroen Bakker
Date:   Mon Dec 30 09:21:29 2019 +0100
Branches: master
https://developer.blender.org/rB79476a9c0ab9e3f29d32a87aa8f9d859f2961cb9

Tracking: Selection Crash

Blender crashes when selecting a marker in the 3d viewport that is from the non active scene camera. This patch will solve this crash, but introduced a new scenario that isn't thought out. In the new scenario it is still hard to select a marker via the 3d viewport.

I would expect that when selecting a marker in this case would select the camera where the marker belongs to and select the marker that is under the mouse button.

Reviewed By: Sergey Sharybin

Differential Revision: https://developer.blender.org/D6360

===================================================================

M	source/blender/editors/space_view3d/view3d_select.c

===================================================================

diff --git a/source/blender/editors/space_view3d/view3d_select.c b/source/blender/editors/space_view3d/view3d_select.c
index 092142a83cd..85e9a2d7680 100644
--- a/source/blender/editors/space_view3d/view3d_select.c
+++ b/source/blender/editors/space_view3d/view3d_select.c
@@ -2077,7 +2077,8 @@ static bool ed_object_select_pick(bContext *C,
 
       if (has_bones && basact) {
         if (basact->object->type == OB_CAMERA) {
-          if (oldbasact == basact) {
+          MovieClip *clip = BKE_object_movieclip_get(scene, basact->object, false);
+          if (clip != NULL && oldbasact == basact) {
             int i, hitresult;
             bool changed = false;
 
@@ -2094,7 +2095,6 @@ static bool ed_object_select_pick(bContext *C,
                * in height word, this buffer value belongs to camera. not to bundle
                */
               if (buffer[4 * i + 3] & 0xFFFF0000) {
-                MovieClip *clip = BKE_object_movieclip_get(scene, basact->object, false);
                 MovieTracking *tracking = &clip->tracking;
                 ListBase *tracksbase;
                 MovieTrackingTrack *track;



More information about the Bf-blender-cvs mailing list