== Core ==
authorPeter Schlaile <peter@schlaile.de>
Sun, 21 Oct 2007 15:42:08 +0000 (15:42 +0000)
committerPeter Schlaile <peter@schlaile.de>
Sun, 21 Oct 2007 15:42:08 +0000 (15:42 +0000)
commita0390e5cc340febece6e2a7e61085033d79742e2
tree5d0e89c54603641f394b95b0e76ee917d15a727d
parentbacfc9eb91f10871a2ba9c3b35e48c3895dffac3
== Core ==

This adds fractional FPS support to blender and should finally
make NTSC work correctly.

NTSC has an FPS of 30.0/1.001 which is approximately 29.97 FPS.
Therefore, it is not enough to simply make frs_sec a float, since
you can't represent this accurately enough.
I added a seperate variable frs_sec_base and FPS is now
frs_sec / frs_sec_base.

I changed all the places, where frs_sec was used to my best knowledge.

For convenience sake, I added several macros, that should make life
easier in the future:

FRA2TIME(a) : convert frame number to a double precision time in seconds
TIME2FRA(a) : the same in the opposite direction
FPS         : return current FPS as a double precision number
              (last resort)

This closes bug #6715
Standard framerates not supported / breaks sync -- 23.967 29.967 etc.

https://projects.blender.org/tracker/?func=detail&aid=6715&group_id=9&atid=125

Please give this heavy testing with NTSC files, quicktime in/export
and the python interface.
Errors are most probably only spotted on longer timelines, so that is
also important.

The patch was tested by Troy Sobotka and me, so it most probably should
work out of the box, but wider testing is important, since errors are
very subtle.

Enjoy!
29 files changed:
source/blender/avi/intern/options.c
source/blender/blenkernel/intern/scene.c
source/blender/blenkernel/intern/writeavi.c
source/blender/blenkernel/intern/writeffmpeg.c
source/blender/blenloader/intern/readfile.c
source/blender/include/BIF_editsound.h
source/blender/include/blendef.h
source/blender/makesdna/DNA_scene_types.h
source/blender/python/api2_2x/sceneRender.c
source/blender/python/api2_2x/sceneSequence.c
source/blender/quicktime/apple/quicktime_export.c
source/blender/src/buttons_scene.c
source/blender/src/drawipo.c
source/blender/src/drawseq.c
source/blender/src/drawsound.c
source/blender/src/drawtime.c
source/blender/src/drawview.c
source/blender/src/editipo.c
source/blender/src/editipo_mods.c
source/blender/src/editnla.c
source/blender/src/editscreen.c
source/blender/src/editseq.c
source/blender/src/edittime.c
source/blender/src/hddaudio.c
source/blender/src/header_time.c
source/blender/src/seqaudio.c
source/blender/src/transform.c
source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
source/gameengine/Converter/BL_BlenderDataConversion.cpp