diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-02-28 17:05:09 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-02-28 17:05:38 +0400 |
commit | e4996b49f5e0cdf9caacaae50e284e51d8250136 (patch) | |
tree | dcf90afedfeee36bc3d3d63fe5c53dae01ef3d0f /source/blender/editors/space_clip/clip_draw.c | |
parent | 45fc0514fbf0d71b691dd69816abdbc91f718172 (diff) |
Proper solution for crash of GP when marker is not exist on current frame
Diffstat (limited to 'source/blender/editors/space_clip/clip_draw.c')
-rw-r--r-- | source/blender/editors/space_clip/clip_draw.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/source/blender/editors/space_clip/clip_draw.c b/source/blender/editors/space_clip/clip_draw.c index 8c015a71d30..d8ccac730c8 100644 --- a/source/blender/editors/space_clip/clip_draw.c +++ b/source/blender/editors/space_clip/clip_draw.c @@ -1635,14 +1635,12 @@ static void draw_distortion(SpaceClip *sc, ARegion *ar, MovieClip *clip, if (track) { int framenr = ED_space_clip_get_clip_frame_number(sc); - MovieTrackingMarker *marker = BKE_tracking_marker_get_exact(track, framenr); + MovieTrackingMarker *marker = BKE_tracking_marker_get(track, framenr); - if (marker) { - offsx = marker->pos[0]; - offsy = marker->pos[1]; + offsx = marker->pos[0]; + offsy = marker->pos[1]; - gpd = track->gpd; - } + gpd = track->gpd; } } |