blender/source/gameengine/VideoTexture
Benoit Bolsee ce1625ebc0 VideoTexture: new VideoTexture.ImageFFmpeg to load and reload images.
The FFmpeg library allows to load image files. Although it is possible
to load images using the VideoFFmpeg class, it is not very efficient.
The new class VideoTexture.ImageFFmpeg is dedicated to image management.

Constructor:
-----------
VideoTexture.ImageFFmpeg('image_file_name')
  Opens the file but does not load the texture yet.
  The file name can also be a network address. It can also be a video
  file name; in that case only the first image is loaded.

Methods:
-------
refresh(True)
  Loads the image to texture. 
  You just need to call it once, the file is automatically closed after
  that and calling refresh() again will have no effect.

reload('new_file_name')
  Reloads the image (if new_file_name is omitted) or loads a new image.
  The file is opened but the texture is not updated yet, you need
  to call refresh() once to load the texture.

Attributes:
----------
status
  returns the image status:
    2 : file opened, texture not loaded
    3 : file closed, texture loaded

image
  returns the image data as a string of RGBA pixel

size
  returns the image size [x,y]

scale
  get/set the scale flag. 
  If the scale flag is False, the image is rescale to texture format
  using gluScaleImage() function, slow but good quality.
  If the scale flag is True, the image is rescaled using a fast but
  less accurate algorithm.

flip
  get/set Y-flip flag.
  Set to True by default as FFmpeg always provides the image upside down

filter
  get/set filter(s) on the image.

Example:
2008-11-05 21:53:22 +00:00
..
BlendType.h
blendVideoTex.cpp VideoTexture: new VideoTexture.ImageFFmpeg to load and reload images. 2008-11-05 21:53:22 +00:00
CMakeLists.txt Fix Cmake for MSVC 32bit 2008-11-01 11:15:13 +00:00
Common.h
Exception.cpp VideoTexture: Add support for GLSL. FIx small printout bug in Exception printout 2008-11-05 13:22:10 +00:00
Exception.h BGE Video Texture: fix constant initializer problem with Exception description. Uniformized the line ending. 2008-11-01 12:48:46 +00:00
FilterBase.cpp VideoTexture: use PyObjectPlus.h instead of Python.h for compatibility with Python2.3 2008-11-02 18:02:31 +00:00
FilterBase.h VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterBlueScreen.cpp VideoTexture: Bug report #17946: add (char*) casting to fix compile error with Python get-set method and module object. 2008-11-04 09:21:27 +00:00
FilterBlueScreen.h VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterColor.cpp VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterColor.h VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterNormal.cpp VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterNormal.h VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterSource.cpp VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
FilterSource.h VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
ImageBase.cpp VideoTexture: use PyObjectPlus.h instead of Python.h for compatibility with Python2.3 2008-11-02 18:02:31 +00:00
ImageBase.h VideoTexture: use PyObjectPlus.h instead of Python.h for compatibility with Python2.3 2008-11-02 18:02:31 +00:00
ImageBuff.cpp VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
ImageBuff.h
ImageMix.cpp VideoTexture: Bug report #17946: add (char*) casting to fix compile error with Python get-set method and module object. 2008-11-04 09:21:27 +00:00
ImageMix.h
ImageRender.cpp VideoTexture: Bug report #17946: add (char*) casting to fix compile error with Python get-set method and module object. 2008-11-04 09:21:27 +00:00
ImageRender.h
ImageViewport.cpp VideoTexture: fix RGB/BGR confusion, make code compatible with big endian CPU, add RGBA source filter. 2008-11-04 12:04:59 +00:00
ImageViewport.h VideoTexture: fix compile error with GLint in ImageViewport under osx. 2008-11-02 18:31:54 +00:00
Makefile
PyTypeList.cpp VideoTexture: Bug report #17946: add (char*) casting to fix compile error with Python get-set method and module object. 2008-11-04 09:21:27 +00:00
PyTypeList.h VideoTexture: use PyObjectPlus.h instead of Python.h for compatibility with Python2.3 2008-11-02 18:02:31 +00:00
SConscript Include path for numpy no longer needed. 2008-11-02 14:36:32 +00:00
Texture.cpp VideoTexture: Add support for GLSL. FIx small printout bug in Exception printout 2008-11-05 13:22:10 +00:00
Texture.h VideoTexture: Add support for GLSL. FIx small printout bug in Exception printout 2008-11-05 13:22:10 +00:00
VideoBase.cpp
VideoBase.h VideoTexture: use PyObjectPlus.h instead of Python.h for compatibility with Python2.3 2008-11-02 18:02:31 +00:00
VideoFFmpeg.cpp VideoTexture: new VideoTexture.ImageFFmpeg to load and reload images. 2008-11-05 21:53:22 +00:00
VideoFFmpeg.h VideoTexture: new VideoTexture.ImageFFmpeg to load and reload images. 2008-11-05 21:53:22 +00:00