FileInfo
Functions
SET_CID |
|
SET_CHUNK_SIGNATURE |
|
FileInfo |
|
~FileInfo |
|
bool | IsValid |
bool | GetMultipleTracks |
unsigned int | GetFrameRate |
float | GetClippingNear |
float | GetClippingFar |
unsigned int | GetDefaultViewID |
const Map < unsigned int, String > & | GetIDToNamesMap |
const Map < unsigned int, Vector < unsigned int > > & | GetAnimationTracksHierarchy |
Detailed Description
-
class
FileInfo
: public RED::Object This class stores miscellaneous info about a .red file’s content.
@related The .red File Format, class RED::IREDFile
A .red file may or may not fill information in the FileInfo
class that is returned after the file has been loaded.
If the
FileInfo is empty, then the RED::FileInfo::IsValid method will return false.Information stored in that object are mostly related to file data display. It gives information about data animations and optionally, the desired default camera to render the data (camera ID and clipping planes).
Last but not least, a correspondence table between file objects IDs and real objects names can also be retrieved.
Public Functions
-
SET_CID (CID_class_REDFileInfo) IMPLEMENT_AS()
-
SET_CHUNK_SIGNATURE (0x00000002) FileInfo()
FileInfo default construction method.
-
FileInfo
(bool iMultipleTracks, unsigned int iFrameRate, float iClippingNear, float iClippingFar, unsigned int iDefaultViewID, const RED::Map<unsigned int, RED::String> &iIDToNames, const RED::Map<unsigned int, RED::Vector<unsigned int>> &iTracksHierarchy) Constructor.
Parameters: - iMultipleTracks – Flag indicating if the animations are exported per object or for the whole scene.
- iFrameRate – Animation play-back requested framerate.
- iClippingNear – Camera near clip distance suitable for a correct scene exploration.
- iClippingFar – Camera far clip distance suitable for a correct scene exploration.
- iDefaultViewID – Camera ID value that is selected as main camera for viewing the file.
- iIDToNames – Map of the RED::Object instances IDs to real names.
- iTracksHierarchy – Map of the animation tracks hierarchy. It stores, for each animation tracks, the IDs of the track parents in the DAG.
-
inline bool
IsValid
() const Do we have valid file information?
Returns: true if there are valid information in the class, false otherwise.
-
inline bool
GetMultipleTracks
() const Returns: true if animations were exported per object, false otherwise (one track for the whole scene).
-
inline unsigned int
GetFrameRate
() const Returns: The framerate that must be used for the file’s animation playback.
-
inline float
GetClippingNear
() const Returns: A camera near clip distance suitable for a correct scene exploration.
-
inline float
GetClippingFar
() const Returns: A camera far clip distance suitable for a correct scene exploration.
-
inline unsigned int
GetDefaultViewID
() const Returns: The ID corresponding to the name of the camera chosen as main camera at the file’s creation time.
-
inline const RED::Map<unsigned int, RED::String> &
GetIDToNamesMap
() const Returns: The conversion map between RED::Object instances IDs and real names.
-
inline const RED::Map<unsigned int, RED::Vector<unsigned int>> &
GetAnimationTracksHierarchy
() const Returns the hierarchy map of the animation tracks.
Each animation track can be linked to zero or multiple DAG nodes. This map stores for each animation track ID the list of the nodes to which it is linked.
Returns: The hierarchy map of the animation tracks.
-