FBX C++ API Reference
All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FbxReaderFbx6 Class Reference

#include <fbxreaderfbx6.h>

Class Description

This class is the FBX v6 reader.

The reader provide you the ability to read the global settings, objects and animation information from file.

Definition at line 82 of file fbxreaderfbx6.h.

+ Inheritance diagram for FbxReaderFbx6:

Public Types

enum  EImportMode { eASCII, eBINARY, eENCRYPTED }
 File import mode. More...
 
- Public Types inherited from FbxReader
enum  EInfoRequest { eInfoExtension, eInfoDescriptions, eReserved1 = 0xFBFB }
 Information type to request. More...
 
enum  EFileOpenSpecialFlags { eParseForGlobalSettings = 1, eParseForStatistics = 2 }
 Flags for reading parts of file. More...
 
typedef FbxReader *(* CreateFuncType) (FbxManager &pManager, FbxImporter &pImporter, int pSubID, int pPluginID)
 
typedef void(* IOSettingsFillerFuncType) (FbxIOSettings &pIOS)
 
typedef void *(* GetInfoFuncType) (EInfoRequest pRequest, int pReaderTypeId)
 

Public Member Functions

 FbxReaderFbx6 (FbxManager &pManager, FbxImporter &pImporter, int pID, FbxStatus &pStatus)
 Constructor. More...
 
virtual ~FbxReaderFbx6 ()
 Destructor. More...
 
virtual bool FileOpen (char *pFileName, EFileOpenSpecialFlags pFlags)
 Open file with certain EFileOpenSpecialFlags. More...
 
virtual bool FileOpen (char *pFileName)
 Open file with default flag. More...
 
virtual bool FileOpen (FbxFile *pFile)
 Open file with FbxFile handle. More...
 
virtual bool FileOpen (FbxStream *pStream, void *pStreamData)
 Open file from stream. More...
 
virtual bool FileClose ()
 Close the file stream. More...
 
virtual bool IsFileOpen ()
 Check whether the file stream is open. More...
 
EImportMode GetImportMode ()
 Get current Import mode. More...
 
virtual void GetVersion (int &pMajor, int &pMinor, int &pRevision)
 Get file version. More...
 
virtual bool GetAxisInfo (FbxAxisSystem *pAxisSystem, FbxSystemUnit *pSystemUnits)
 Get axis system information from file. More...
 
virtual bool GetFrameRate (FbxTime::EMode &pTimeMode)
 Get FBX file time mode read from GlobalSettings in FBX 6.n and FBX 7.n. More...
 
virtual bool GetStatistics (FbxStatistics *pStats)
 Get the statistics from file. More...
 
virtual bool GetReadOptions (bool pParseFileAsNeeded=true)
 Get the file stream options. More...
 
virtual bool Read (FbxDocument *pDocument)
 Read file with stream options. More...
 
virtual bool GetReadOptions (FbxIO *pFbx, bool pParseFileAsNeeded=true)
 Get the file options. More...
 
virtual bool Read (FbxDocument *pDocument, FbxIO *pFbx)
 Read file with stream options. More...
 
virtual void PluginReadParameters (FbxObject &pParams)
 Read all the properties and flags. More...
 
virtual FbxDocumentInfoGetSceneInfo ()
 Returns the scene info from the file. More...
 
virtual FbxArray< FbxTakeInfo * > * GetTakeInfo ()
 Returns the pointer to the list of TakeInfo from the file. More...
 
virtual void SetProgressHandler (FbxProgress *pProgress)
 Pass a progress handler to the reader. More...
 
virtual void SetEmbeddingExtractionFolder (const char *pExtractFolder)
 
virtual bool SupportsStreams () const
 Returns true if this reader supports FbxStream I/O. More...
 
- Public Member Functions inherited from FbxReader
 FbxReader (FbxManager &pManager, int pID, FbxStatus &pStatus)
 Constructor. More...
 
virtual ~FbxReader ()
 Destructor. More...
 
virtual bool GetDefaultRenderResolution (FbxString &pCamName, FbxString &pResolutionMode, double &pW, double &pH)
 If default camera resolution is OK, returns information about the resolution of the render. More...
 
bool IsGenuine ()
 Judges if the format of the file is was created by an Autodesk plug-in. More...
 
virtual FbxIOSettingsGetIOSettings ()
 Access to a IOSettings object. More...
 
virtual void SetIOSettings (FbxIOSettings *pIOSettings)
 Set the IOSettings pointer to be used for this reader instance. More...
 

Member Enumeration Documentation

◆ EImportMode

File import mode.

Enumerator
eASCII 

Plain text mode.

eBINARY 

Binary mode.

eENCRYPTED 

Encrypted mode.

Definition at line 135 of file fbxreaderfbx6.h.

136  {
137  eASCII,
138  eBINARY,
139  eENCRYPTED
140  } EImportMode;
Plain text mode.
EImportMode
File import mode.

Constructor & Destructor Documentation

◆ FbxReaderFbx6()

FbxReaderFbx6 ( FbxManager pManager,
FbxImporter pImporter,
int  pID,
FbxStatus pStatus 
)

Constructor.

Parameters
pManagerthe FbxManager Object
pImporterthe FbxImporter to import the SDK objects
pIDid for current reader
pStatusthe FbxStatus object to hold error codes

◆ ~FbxReaderFbx6()

virtual ~FbxReaderFbx6 ( )
virtual

Destructor.

Member Function Documentation

◆ FileOpen() [1/4]

virtual bool FileOpen ( char *  pFileName,
EFileOpenSpecialFlags  pFlags 
)
virtual

Open file with certain EFileOpenSpecialFlags.

Parameters
pFileNamename of the File to open
pFlagsthe EFileOpenSpecialFlags to open with
Returns
if the file is open successfully return true, otherwise return false

Reimplemented from FbxReader.

◆ FileOpen() [2/4]

virtual bool FileOpen ( char *  pFileName)
virtual

Open file with default flag.

Parameters
pFileNamename of the File to open
Returns
if the file is open successfully return true, otherwise return false

Implements FbxReader.

◆ FileOpen() [3/4]

virtual bool FileOpen ( FbxFile pFile)
virtual

Open file with FbxFile handle.

Parameters
pFilethe FbxFile handle
Returns
if the file is open successfully return true, otherwise return false

◆ FileOpen() [4/4]

virtual bool FileOpen ( FbxStream pStream,
void *  pStreamData 
)
virtual

Open file from stream.

Reimplemented from FbxReader.

◆ FileClose()

virtual bool FileClose ( )
virtual

Close the file stream.

Returns
if the file is closed successfully return true, otherwise return false

Implements FbxReader.

◆ IsFileOpen()

virtual bool IsFileOpen ( )
virtual

Check whether the file stream is open.

Returns
if the file stream is open return true, otherwise return false.

Implements FbxReader.

◆ GetImportMode()

EImportMode GetImportMode ( )

Get current Import mode.

Returns
return the EImportMode value

◆ GetVersion()

virtual void GetVersion ( int &  pMajor,
int &  pMinor,
int &  pRevision 
)
virtual

Get file version.

Parameters
pMajorMajor version
pMinorMinor version
pRevisionRevision version

Reimplemented from FbxReader.

◆ GetAxisInfo()

virtual bool GetAxisInfo ( FbxAxisSystem pAxisSystem,
FbxSystemUnit pSystemUnits 
)
virtual

Get axis system information from file.

Parameters
pAxisSystemaxis system in file
pSystemUnitssystem unit in file
Returns
if either pAxisSystem or pSystemUnits is NULL return false, otherwise return true.

Reimplemented from FbxReader.

◆ GetFrameRate()

virtual bool GetFrameRate ( FbxTime::EMode pTimeMode)
virtual

Get FBX file time mode read from GlobalSettings in FBX 6.n and FBX 7.n.

Parameters
pTimeModeref to a FbxTime::EMode enum
Returns
true on success, false otherwise.
Remarks
This function must be called after FbxImporter::Initialize(). Can be used for statistics (via GlobalSettings) before loading the whole scene from the file.

Reimplemented from FbxReader.

◆ GetStatistics()

virtual bool GetStatistics ( FbxStatistics pStats)
virtual

Get the statistics from file.

Parameters
pStatsstatistics in file
Returns
if fetching statistics is successfully return true, otherwise return false.

Reimplemented from FbxReader.

◆ GetReadOptions() [1/2]

virtual bool GetReadOptions ( bool  pParseFileAsNeeded = true)
virtual

Get the file stream options.

Parameters
pParseFileAsNeededWhether to parse file as read options
Returns
true on success, otherwise return false.

Implements FbxReader.

◆ Read() [1/2]

virtual bool Read ( FbxDocument pDocument)
virtual

Read file with stream options.

Parameters
pDocumentFbxDocument to store the file data
Returns
if fetching statistics is successful return true, otherwise return false.

Implements FbxReader.

◆ GetReadOptions() [2/2]

virtual bool GetReadOptions ( FbxIO pFbx,
bool  pParseFileAsNeeded = true 
)
virtual

Get the file options.

Parameters
pFbxfile object to read options
pParseFileAsNeededWhether to parse file as read options
Returns
true on success, otherwise return false.

◆ Read() [2/2]

virtual bool Read ( FbxDocument pDocument,
FbxIO pFbx 
)
virtual

Read file with stream options.

Parameters
pDocumentFbxDocument to store the file data
pFbxfile object to read from
Returns
if reading the file is successful return true, otherwise return false.

◆ PluginReadParameters()

virtual void PluginReadParameters ( FbxObject pParams)
virtual

Read all the properties and flags.

Parameters
pParamssettings to assign properties and flags

Reimplemented from FbxReader.

◆ GetSceneInfo()

virtual FbxDocumentInfo* GetSceneInfo ( )
inlinevirtual

Returns the scene info from the file.

Returns
The pointer to file scene info defined by this reader.

Reimplemented from FbxReader.

Definition at line 212 of file fbxreaderfbx6.h.

212 { return mSceneInfo; }

◆ GetTakeInfo()

virtual FbxArray<FbxTakeInfo*>* GetTakeInfo ( )
inlinevirtual

Returns the pointer to the list of TakeInfo from the file.

Returns
NULL

Reimplemented from FbxReader.

Definition at line 218 of file fbxreaderfbx6.h.

218 { return &mTakeInfo; }

◆ SetProgressHandler()

virtual void SetProgressHandler ( FbxProgress pProgress)
virtual

Pass a progress handler to the reader.

Parameters
pProgressFbxProgress to store the progress information.

Reimplemented from FbxReader.

◆ SetEmbeddingExtractionFolder()

virtual void SetEmbeddingExtractionFolder ( const char *  pExtractFolder)
virtual

Reimplemented from FbxReader.

◆ SupportsStreams()

virtual bool SupportsStreams ( ) const
inlinevirtual

Returns true if this reader supports FbxStream I/O.

Default value is false.

Reimplemented from FbxReader.

Definition at line 227 of file fbxreaderfbx6.h.

227 { return true; }

The documentation for this class was generated from the following file: