diff options
author | Harley Acheson <harley.acheson@gmail.com> | 2021-11-13 20:39:18 +0300 |
---|---|---|
committer | Harley Acheson <harley.acheson@gmail.com> | 2021-11-13 20:39:18 +0300 |
commit | 73047c69ea803a35f3eb4082b5ccdc7d2c53514d (patch) | |
tree | 6ae8aaf0a693f2a0a983f3fedaca9aff971dc16c /source/blender/sequencer/intern/effects.c | |
parent | e8a8bb67fcefa5e935214e1af1ec3da38465dda1 (diff) |
BLF: Use Floats for Font Point Sizes
Allow the use of floating-point values for font point sizes, which
allows greater precision and flexibility for text output.
See D8960 for more information, details, and justification.
Differential Revision: https://developer.blender.org/D8960
Reviewed by Campbell Barton
Diffstat (limited to 'source/blender/sequencer/intern/effects.c')
-rw-r--r-- | source/blender/sequencer/intern/effects.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/sequencer/intern/effects.c b/source/blender/sequencer/intern/effects.c index b9ee23a9186..37d1f6832bb 100644 --- a/source/blender/sequencer/intern/effects.c +++ b/source/blender/sequencer/intern/effects.c @@ -3741,7 +3741,7 @@ static void init_text_effect(Sequence *seq) data = seq->effectdata = MEM_callocN(sizeof(TextVars), "textvars"); data->text_font = NULL; data->text_blf_id = -1; - data->text_size = 60; + data->text_size = 60.0f; copy_v4_fl(data->color, 1.0f); data->shadow_color[3] = 0.7f; @@ -3842,7 +3842,7 @@ static int num_inputs_text(void) static int early_out_text(Sequence *seq, float UNUSED(facf0), float UNUSED(facf1)) { TextVars *data = seq->effectdata; - if (data->text[0] == 0 || data->text_size < 1 || + if (data->text[0] == 0 || data->text_size < 1.0f || ((data->color[3] == 0.0f) && (data->shadow_color[3] == 0.0f || (data->flag & SEQ_TEXT_SHADOW) == 0))) { return EARLY_USE_INPUT_1; |