ParaScripting::ParaMovie Class Reference
[ParaMovie]

List of all members.

Detailed Description

movie making and screen capture functions


Static Public Member Functions

static void SetMovieScreenSize (int nWidth, int nHeight)
 set the movie screen size in pixel.
static void SetCaptureGUI (bool bGUI)
 set whether GUI is captured.
static bool CaptureGUI ()
 return true if GUI is also captured.
static void SetRecordingFPS (int nFPS)
 set the recording FPS, the default is 20 FPS.
static int GetRecordingFPS ()
 Get the recording FPS, the default is 20 FPS.
static void SetStereoCaptureMode (int nMode)
 set the stereo capture mode.
static int GetStereoCaptureMode ()
 Get the stereo capture mode.
static void SetStereoEyeSeparation (float fDist)
 the distance in meters between the left and right eye when generating the stereo image.
static float GetStereoEyeSeparation ()
 the distance in meters between the left and right eye when generating the stereo image.
static bool BeginCapture (string sFileName)
 starting capturing a screen movie
static bool EndCapture ()
 end capturing a screen movie and save movie to file.
static void PauseCapture ()
 pause the capturing.
static void ResumeCapture ()
 resume capturing
static bool IsInCaptureSession ()
 whether we are doing screen capture.
static bool IsRecording ()
 whether it is recording.
static void GetMovieScreenSize (int *nWidth, int *nHeight)
 get movie screen size.
static string GetMovieFileName ()
 get the movie file name
static void SelectCodecOptions ()
 display a dialog which allows the user to set the codec to be used.
static void SetEncodeMethod (int eType)
 set the code
static int GetEncodeMethod ()
 
See also:
SetEncodeMethod()

static bool TakeScreenShot (const char *filename)
 we will automatically take screen shot according to the file extensions, supported file extensions are "jpg","dds","bmp","tga",
static bool TakeScreenShot3 (const char *filename, int width, int height)
 render the current scene to texture, UI are disabled by default.
static bool RenderToTexture (const char *filename, int width, int height)
static bool ResizeImage (const string &filename, int width, int height, const char *destFilename)
 resize the given image.
static void GetImageInfo (const string &filename, int *width, int *height, int *nFileSize)
 get the given image info: i.e.


Member Function Documentation

void ParaScripting::ParaMovie::SetMovieScreenSize ( int  nWidth,
int  nHeight 
) [static]

set the movie screen size in pixel.

Parameters:
nWidth,: in pixels, must be multiple of 4.
nHeight,: in pixels, must be multiple of 4.

void ParaScripting::ParaMovie::SetCaptureGUI ( bool  bGUI  )  [static]

set whether GUI is captured.

bool ParaScripting::ParaMovie::CaptureGUI (  )  [static]

return true if GUI is also captured.

void ParaScripting::ParaMovie::SetRecordingFPS ( int  nFPS  )  [static]

set the recording FPS, the default is 20 FPS.

Some may prefer 30FPS.

int ParaScripting::ParaMovie::GetRecordingFPS (  )  [static]

Get the recording FPS, the default is 20 FPS.

Some may prefer 30FPS.

void ParaScripting::ParaMovie::SetStereoCaptureMode ( int  nMode  )  [static]

set the stereo capture mode.

This is used to generate video files that can be viewed by 3d eye glasses and stereo video player.

int ParaScripting::ParaMovie::GetStereoCaptureMode (  )  [static]

Get the stereo capture mode.

This is used to generate video files that can be viewed by 3d eye glasses and stereo video player.

void ParaScripting::ParaMovie::SetStereoEyeSeparation ( float  fDist  )  [static]

the distance in meters between the left and right eye when generating the stereo image.

some common values are in range [0.03, 0.1]. This is also related to the rendering unit that we used in games. since ParaEngine games usually use meter as its rendering unit, the value is such near the real eye separation distance.

float ParaScripting::ParaMovie::GetStereoEyeSeparation (  )  [static]

the distance in meters between the left and right eye when generating the stereo image.

some common values are in range [0.03, 0.1]. This is also related to the rendering unit that we used in games. since ParaEngine games usually use meter as its rendering unit, the value is such near the real eye separation distance.

bool ParaScripting::ParaMovie::BeginCapture ( string  sFileName  )  [static]

starting capturing a screen movie

Parameters:
sFileName,: the movie file name, which can be "". If it is "", a default name is used.

bool ParaScripting::ParaMovie::EndCapture (  )  [static]

end capturing a screen movie and save movie to file.

void ParaScripting::ParaMovie::PauseCapture (  )  [static]

pause the capturing.

bool ParaScripting::ParaMovie::IsInCaptureSession (  )  [static]

whether we are doing screen capture.

I.e. true between BeginCapture() and EndCapture() However, it may be in the recording or paused state.

bool ParaScripting::ParaMovie::IsRecording (  )  [static]

whether it is recording.

void ParaScripting::ParaMovie::GetMovieScreenSize ( int *  nWidth,
int *  nHeight 
) [static]

get movie screen size.

In script. Use like this : local x,y = ParaMovie.GetMovieScreenSize();

void ParaScripting::ParaMovie::SelectCodecOptions (  )  [static]

display a dialog which allows the user to set the codec to be used.

void ParaScripting::ParaMovie::SetEncodeMethod ( int  eType  )  [static]

set the code

Parameters:
eType,: 0 for XVID; 1 for WMV; -1 for user select codec.

bool ParaScripting::ParaMovie::TakeScreenShot ( const char *  filename  )  [static]

we will automatically take screen shot according to the file extensions, supported file extensions are "jpg","dds","bmp","tga",

Note:
: "jpg" has small file size; where "bmp" and "tga" is lossless.
Parameters:
filename,: this is the file name.If this is NULL or "", it will be automatically named as jpg file under the "screen shots" directory.

bool ParaScripting::ParaMovie::TakeScreenShot3 ( const char *  filename,
int  width,
int  height 
) [static]

render the current scene to texture, UI are disabled by default.

Aspect ratio are changed according to width/height. supported file extensions are "jpg","dds","bmp","tga",

Note:
: "jpg" has small file size; where "bmp" and "tga" is lossless.
Parameters:
filename,: this is the file name.If this is NULL or "", it will be automatically named as jpg file under the "screen shots" directory.
width; in pixel, if 0 it will be the screen size
height; in pixel, if 0 it will be the screen size

bool ParaScripting::ParaMovie::ResizeImage ( const string &  filename,
int  width,
int  height,
const char *  destFilename 
) [static]

resize the given image.

It can also be used to change the file format

Parameters:
filename,: source file name
width; in pixel
height; in pixel
destFilename,: destination file name. If nil or "", it will be the same as input. It can also be used to change the file format

void ParaScripting::ParaMovie::GetImageInfo ( const string &  filename,
int *  width,
int *  height,
int *  nFileSize 
) [static]

get the given image info: i.e.

size e.g. local width, height, filesize = ParaMovie.GetImageInfo("abc.jpg")

Parameters:
width; out in pixel
height; out in pixel
nFileSize,: out in size in bytes


Generated on Mon Dec 1 14:34:46 2008 for NPL Scripting Reference for ParaEngine by  doxygen 1.5.2