Fix T64371
Variable stripe_offs used without been initialized Reviewed by: brecht Differential Revision: https://developer.blender.org/D4845
This commit is contained in:
parent
eff273c0bc
commit
05f1451d72
Notes:
blender-bot
2023-02-14 11:08:33 +01:00
Referenced by issue #65275, File with Curve crashes when entering edit mode. Referenced by issue #64999, FBX export fails with empty material slot Referenced by issue #64544, Boolean modifier difference not working properly, when plane's vertex is on the other mesh's edge. Referenced by issue #64371, Debug Build - crash when switching to Video Editing workspace
|
@ -1922,10 +1922,14 @@ static void draw_cache_view(const bContext *C)
|
|||
uint pos = GPU_vertformat_attr_add(immVertexFormat(), "pos", GPU_COMP_F32, 2, GPU_FETCH_FLOAT);
|
||||
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
|
||||
|
||||
float stripe_bot, stripe_top, stripe_offs;
|
||||
float stripe_bot, stripe_top;
|
||||
float stripe_offs = UI_view2d_region_to_view_y(v2d, 1.0f) - v2d->cur.ymin;
|
||||
float stripe_ht = UI_view2d_region_to_view_y(v2d, 4.0f * UI_DPI_FAC * U.pixelsize) -
|
||||
v2d->cur.ymin;
|
||||
|
||||
CLAMP_MAX(stripe_ht, 0.2f);
|
||||
CLAMP_MIN(stripe_offs, stripe_ht / 2);
|
||||
|
||||
if (scene->ed->cache_flag & SEQ_CACHE_VIEW_FINAL_OUT) {
|
||||
stripe_bot = UI_view2d_region_to_view_y(v2d, V2D_SCROLL_HEIGHT_HANDLES);
|
||||
stripe_top = stripe_bot + stripe_ht;
|
||||
|
@ -1944,10 +1948,6 @@ static void draw_cache_view(const bContext *C)
|
|||
continue;
|
||||
}
|
||||
|
||||
CLAMP_MAX(stripe_ht, 0.2f);
|
||||
stripe_offs = UI_view2d_region_to_view_y(v2d, 1.0f) - v2d->cur.ymin;
|
||||
CLAMP_MIN(stripe_offs, stripe_ht / 2);
|
||||
|
||||
stripe_bot = seq->machine + SEQ_STRIP_OFSBOTTOM + stripe_offs;
|
||||
stripe_top = stripe_bot + stripe_ht;
|
||||
|
||||
|
|
Loading…
Reference in New Issue