From ab8e9ba3dd54fe8781f763644b882bbcb8cc7e8d Mon Sep 17 00:00:00 2001 From: Benoit Bolsee Date: Thu, 5 Mar 2009 15:16:43 +0000 Subject: VideoTexture: reactivate VideoTexture for scons/cmake/makefile compilation systems, fix video streaming, fix camera support in Linux, add multi-thread cache service, fix crash when a VideoFFmpeg object could not be created. The multi-thread cache service is activated only on multi-core processors. It consists in loading, decoding and caching the video frames in a separate thread. The cache size is 5 decoded frames and 30 raw frames. Note that the opening of video file/stream/camera is not multi-thread: you will still experience a delay at the VideoFFmpeg object creation. Processing of the video frame (resize, loading to texture) is still done in the main thread. Caching is automatically enabled for video file, video streaming and video camera. Video streaming now works correctly: the videos frames are loaded at the correct rate. Network delays and frequency drifts are automatically compensated. Note: an http video source is always treated as a streaming source, even though the http protocol allows seeking. For the user it means that he cannot define start/stop range and cannot restart the video except by reopening the source. Pause/play is however possible. Video camera is now correctly handled on Linux: it will not slow down the BGE. A video camera is treated as a streaming source. --- source/gameengine/VideoTexture/SConscript | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/gameengine/VideoTexture/SConscript') diff --git a/source/gameengine/VideoTexture/SConscript b/source/gameengine/VideoTexture/SConscript index 28737ed06e5..edd44f98783 100644 --- a/source/gameengine/VideoTexture/SConscript +++ b/source/gameengine/VideoTexture/SConscript @@ -27,7 +27,7 @@ incs += ' ' + env['BF_PYTHON_INC'] if env['WITH_BF_FFMPEG']: defs += ' WITH_FFMPEG' - incs += ' ' + env['BF_FFMPEG_INC'] + incs += ' ' + env['BF_FFMPEG_INC'] + ' ' + env['BF_PTHREADS_INC'] defs += ' __STDC_CONSTANT_MACROS' env.BlenderLib ( 'bf_videotex', sources, Split(incs), Split(defs), libtype=['game','player'], priority=[25, 72], cxx_compileflags = cxxflags ) -- cgit v1.2.3