Cleanup: refactor VSE timeline drawing code
- Use context variables for drawing functions. - Move conditions to functions drawing specific elements as preconditions - Disentangle calculation of common coordinates. - Use more descriptive variable names (in context at least) Individual drawing functions are mostly unchanged, so improvements there are minimal. No intended functional changes.
This commit is contained in:
@@ -435,6 +435,14 @@ void draw_seq_strip_thumbnail(View2D *v2d,
|
||||
float pixelx,
|
||||
float pixely)
|
||||
{
|
||||
SpaceSeq *sseq = CTX_wm_space_seq(C);
|
||||
if ((sseq->flag & SEQ_SHOW_OVERLAY) == 0 ||
|
||||
(sseq->timeline_overlay.flag & SEQ_TIMELINE_SHOW_THUMBNAILS) == 0 ||
|
||||
!ELEM(seq->type, SEQ_TYPE_MOVIE, SEQ_TYPE_IMAGE))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
bool clipped = false;
|
||||
float image_height, image_width, thumb_width;
|
||||
rcti crop;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user