Fix T38004: size of Waveform, Vectorscope and Histogram is incorrect in VSE

Made it so scopes image buffer is displayed without any additional scale
applied on them,

Further tweaks are possible here, but that i'd consider a TODO.
This commit is contained in:
Sergey Sharybin 2014-01-02 17:57:01 +06:00
parent f54778b7ee
commit 51c6ecac52
Notes: blender-bot 2023-02-14 11:25:08 +01:00
Referenced by issue #38004, The size of Waveform, Vectorscope and Histogram is not correct in Sequencer
1 changed files with 8 additions and 6 deletions

View File

@ -965,12 +965,6 @@ void draw_image_seq(const bContext *C, Scene *scene, ARegion *ar, SpaceSeq *sseq
glClear(GL_COLOR_BUFFER_BIT);
}
/* without this colors can flicker from previous opengl state */
glColor4ub(255, 255, 255, 255);
UI_view2d_totRect_set(v2d, viewrectx + 0.5f, viewrecty + 0.5f);
UI_view2d_curRect_validate(v2d);
/* only initialize the preview if a render is in progress */
if (G.is_rendering)
return;
@ -1027,8 +1021,16 @@ void draw_image_seq(const bContext *C, Scene *scene, ARegion *ar, SpaceSeq *sseq
}
scopes->reference_ibuf = ibuf;
viewrectx = scope->x;
viewrecty = scope->y;
}
/* without this colors can flicker from previous opengl state */
glColor4ub(255, 255, 255, 255);
UI_view2d_totRect_set(v2d, viewrectx + 0.5f, viewrecty + 0.5f);
UI_view2d_curRect_validate(v2d);
/* setting up the view - actual drawing starts here */
UI_view2d_view_ortho(v2d);