FVVLib  1.0.0 beta 3
Public Member Functions
FVVLoader Class Reference

Central class to access FVV file data. More...

List of all members.

Public Member Functions

bool OpenFile (const wchar_t *path)
 Opens a FVV file which name is specified by the path parameter.
bool OpenFile (const char *path)
 Opens a FVV file which name is specified by the path parameter.
const FVVFileInfoPtr GetFileInfo ()
 Get metadata information about the FVV file. See the definition of FVVFileInfo.
const FVVFrameInfoPtr GetFrameInfo ()
 Get metadata information about FVV frames. See the definition of FVVFrameInfo.
const FVVSequenceDataPtr GetSequenceData ()
 Get sequence data. See the definition of FVVSequenceData.
const FVVFrameDataPtr GetNextFrameData ()
 Get the next processed free-viewpoint video frame. See the definition of FVVFrameData.
bool SeekFrame (int frameNumber)
 Set the frame position to the given frame number.
bool CloseFile ()
 Closes the file.
bool IsFileOpen ()
 Checks if a file is currently opend by the loader.
bool IsEndOfSequence ()
 Check if the end of the frame sequence has been reached.
bool GetLastError (FVVError &error)
 Retrieve the internal error state of the loader.
 FVVLoader (void)
 ~FVVLoader (void)

Detailed Description

Central class to access FVV file data.

Author:
Voxelogram, Inc.
Version:
1.0.0beta
Date:
2011-08-23

Constructor & Destructor Documentation

FVVLoader ( void  )
~FVVLoader ( void  )

Member Function Documentation

bool OpenFile ( const wchar_t *  path)

Opens a FVV file which name is specified by the path parameter.

If opened successfully the function will read metadata information and starts processing of the free-viewpoint video frame data.

File and frame metadata can be accessed through the FVVFileInfo and FVVFrameInfo interfaces. Data relevant for all frames in the sequence can be accessed through the FVVSequenceData interface. These interfaces can be retrieved through the GetFileInfo(), GetFrameInfo() and GetSequenceData() functions, respectively.

Individual frame data can be accessed through the FVVFrameData interface by successively calling GetNextFrameData().

Note:
Not valid to call if another file is already openend. CloseFile() has to be called first before opening another file.
Parameters:
pathPath of the FVV file.
Returns:
true if the file was opened successfully.
false if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
bool OpenFile ( const char *  path)

Opens a FVV file which name is specified by the path parameter.

If opened successfully the function will read metadata information and starts processing of the free-viewpoint video frame data.

File and frame metadata can be accessed through the FVVFileInfo and FVVFrameInfo interfaces. Data relevant for all frames in the sequence can be accessed through the FVVSequenceData interface. These interfaces can be retrieved through the GetFileInfo(), GetFrameInfo() and GetSequenceData() functions, respectively.

Individual frame data can be accessed through the FVVFrameData interface by successively calling GetNextFrameData().

Note:
Not valid to call if another file is already openend. CloseFile() has to be called first before opening another file.
Parameters:
pathPath of the FVV file.
Returns:
true if the file was opened successfully.
false if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
const FVVFileInfoPtr GetFileInfo ( )

Get metadata information about the FVV file. See the definition of FVVFileInfo.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return nullptr and the internal error state is set.
Returns:
Pointer to the FVVFileInfo.
nullptr if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
FVVFrameInfoPtr GetFrameInfo ( )

Get metadata information about FVV frames. See the definition of FVVFrameInfo.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return nullptr and the internal error state is set.
Returns:
Pointer to the FVVFrameInfo.
nullptr if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
const FVVSequenceDataPtr GetSequenceData ( )

Get sequence data. See the definition of FVVSequenceData.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return nullptr and the internal error state is set.
Returns:
Pointer to the FVVSequenceData.
nullptr if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
FVVFrameDataPtr GetNextFrameData ( )

Get the next processed free-viewpoint video frame. See the definition of FVVFrameData.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return nullptr and the internal error state is set. This function will block the calling thread until the next processed frame is available.
If the end of the sequence has been reached the function will return nullptr and the internal eror state will set to FVV_ERROR_END_OF_SEQUENCE. The end of sequence can be checked by calling IsEndOfSequence() before calling GetNextFrameData().
Returns:
The next free-viewpoint video frame in the sequence.
nullptr if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
bool SeekFrame ( int  frameNumber)

Set the frame position to the given frame number.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return false and the internal error state is set.
Parameters:
[in]frameNumberThe new position in the frame sequence.
Returns:
true if successfully.
false if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
bool CloseFile ( )

Closes the file.

Note:
Resets and cleans up the loader. A new file can be opened after calling this function.
Only valid to call after OpenFile() has been called successfully. Otherwise it will return nullptr and the internal error state is set.
Returns:
true if successfully.
false if an error occured. The interal error state is set in this case which can be retrieved with GetLastError().
bool IsFileOpen ( )

Checks if a file is currently opend by the loader.

Returns:
true if a file is currently openend by the loader.
false if no file is currently openend by the loader.
bool IsEndOfSequence ( )

Check if the end of the frame sequence has been reached.

Note:
Only valid to call after OpenFile() has been called successfully. Otherwise it will return false and the internal error state is set.
Returns:
true if no more frames available.
false if more frames available.
bool GetLastError ( FVVError error)

Retrieve the internal error state of the loader.

The internal error state allways stores the last error occured in the loader.
If an error was set internally the function will return 'true' and the given error parameter is filled with the internal error state information.
The internal error state is reset when this function is called, i.e. internal error information can only be retrieved one time.

Parameters:
error[out] FVVError structure to be filled with the error information.
Returns:
true if the error state was set internally.
false if no error was set internally, i.e. internal error state is set to FVVError::FVV_ERROR_NONE.