diff options
author | Joshua Leung <aligorith@gmail.com> | 2010-01-30 07:43:36 +0300 |
---|---|---|
committer | Joshua Leung <aligorith@gmail.com> | 2010-01-30 07:43:36 +0300 |
commit | e1fdf7fc58573de84fba5514bcdef1749bb61d16 (patch) | |
tree | 301a9bfee9018170f18327e86f6a1e460123c335 /source/blender/editors/include/ED_anim_api.h | |
parent | d86a9da07ca7901c1984c79b420cb87b363cbafa (diff) |
View2D/TimeCode Drawing:
This commit introduces a few cleanups and tweaks to the way that timecodes (i.e. the timing indications used instead of frame numbers) get displayed.
1. Custom Spacing of TimeCodes/Gridlines
Made the minimum number of pixels between gridlines/timecode indications a user-preference, instead of being a hardcoded constant. This allows to set the spacing tighter/looser than the defaults, and is also used for the other changes.
2. Default timecode display style, (now named 'minimal') uses '+' as the delimeter for the sub-second frames. This hopefully makes it a bit clearer what those values represent, as opposed to the '!', which can sometimes look too much like a colon.
3. Added various timecode display styles as user-preference. - These include always displaying full SMPTE, to showing milliseconds instead of frams for sub-second times, and also an option to just show the times as seconds only.
- When changing the timecode style, the spacing setting is automatically modified so that the timecodes are spaced far apart enough so that they won't clash (under most circumstances). This automatic modification is only done if the spacing is too tight for the style being set.
4. Unified the code for generating timecode strings between the View2D scrollbar drawing and the current frame indicator drawing.
Diffstat (limited to 'source/blender/editors/include/ED_anim_api.h')
-rw-r--r-- | source/blender/editors/include/ED_anim_api.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/include/ED_anim_api.h b/source/blender/editors/include/ED_anim_api.h index 1b1b31ff704..47eeb476c4d 100644 --- a/source/blender/editors/include/ED_anim_api.h +++ b/source/blender/editors/include/ED_anim_api.h @@ -409,6 +409,9 @@ void ANIM_fcurve_delete_from_animdata(bAnimContext *ac, struct AnimData *adt, st /* DRAWING API */ /* anim_draw.c */ +/* Get string representing the given frame number as an appropriately represented frame or timecode */ +void ANIM_timecode_string_from_frame(char *str, struct Scene *scene, int power, short timecodes, float cfra); + /* ---------- Current Frame Drawing ---------------- */ /* flags for Current Frame Drawing */ |