Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <mail@jlucke.com>2018-12-14 17:34:44 +0300
committerJacques Lucke <mail@jlucke.com>2018-12-14 17:34:48 +0300
commit233b7806354f27a52fb1aee672c7c58149d0b4a4 (patch)
tree9dbd34d9a85f60716d59e9ebe548ad71986f514a /source/blender/editors/space_clip/clip_buttons.c
parente67f7e922cfe6742753944fa1bf4ace358b382a7 (diff)
UI: show frame rate in movie clip editor
Feature Request from Hjialti.
Diffstat (limited to 'source/blender/editors/space_clip/clip_buttons.c')
-rw-r--r--source/blender/editors/space_clip/clip_buttons.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/space_clip/clip_buttons.c b/source/blender/editors/space_clip/clip_buttons.c
index a106ab5c465..79e632ce1c1 100644
--- a/source/blender/editors/space_clip/clip_buttons.c
+++ b/source/blender/editors/space_clip/clip_buttons.c
@@ -534,6 +534,12 @@ void uiTemplateMovieclipInformation(uiLayout *layout, PointerRNA *ptr, const cha
else
ofs += BLI_strncpy_rlen(str + ofs, IFACE_(", RGB byte"), sizeof(str) - ofs);
}
+
+ short frs_sec;
+ float frs_sec_base;
+ if (IMB_anim_get_fps(clip->anim, &frs_sec, &frs_sec_base, true)) {
+ ofs += BLI_snprintf(str + ofs, sizeof(str) - ofs, IFACE_(", %.2f fps"), (float)frs_sec / frs_sec_base);
+ }
}
else {
ofs += BLI_strncpy_rlen(str + ofs, IFACE_(", failed to load"), sizeof(str) - ofs);