c4d.bitmaps.MovieLoader¶
-
class
c4d.bitmaps.
MovieLoader
¶ The movie loader class is used for reading movie streams.
Methods Signatures
|
Open a movie file. |
|
Close the movie file. |
|
Return information about the movie. |
|
Read an image from the movie. |
Methods Documentation
-
MovieLoader.
__init__
(self)¶ - Return type
- Returns
The new movie loader
-
MovieLoader.
Open
(self, fn)¶ Open a movie file.
- Parameters
fn (Union[str, c4d.storage.MemoryFileStruct]) – The file.
-
MovieLoader.
Close
(self)¶ Close the movie file.
-
MovieLoader.
GetInfo
(self)¶ Return information about the movie.
framecount, fps = ml.GetInfo()
- Return type
tuple(int, float)
- Returns
Frame and FPS
-
MovieLoader.
Read
(self, new_frame_idx)¶ Read an image from the movie.
framecount, fps = ml.GetInfo() for frame in xrange(framecount): result, image = ml.Read(frame) #when result is not IMAGERESULT_OK... #...image is None. if result != c4d.IMAGERESULT_OK: break pass
- Parameters
new_frame_idx (int) – The frame number of the frame to be read.
- Return type
tuple(IMAGERESULT,
BaseBitmap
)- Returns
The image result and the bitmap or None.