FBX C++ API Reference
fbxglobalsettings.h
Go to the documentation of this file.
1 /****************************************************************************************
2 
3  Copyright (C) 2015 Autodesk, Inc.
4  All rights reserved.
5 
6  Use of this software is subject to the terms of the Autodesk license agreement
7  provided at the time of installation or download, or which otherwise accompanies
8  this software in either electronic or hard copy form.
9 
10 ****************************************************************************************/
11 
13 #ifndef _FBXSDK_FILEIO_GLOBAL_SETTINGS_H_
14 #define _FBXSDK_FILEIO_GLOBAL_SETTINGS_H_
15 
16 #include <fbxsdk/fbxsdk_def.h>
17 
18 #include <fbxsdk/core/fbxobject.h>
21 
22 #include <fbxsdk/fbxsdk_nsbegin.h>
23 
28 {
30 
31 public:
36 
40  void SetAxisSystem(const FbxAxisSystem& pAxisSystem);
41 
45  FbxAxisSystem GetAxisSystem();
47 
51  void SetOriginalUpAxis(const FbxAxisSystem& pAxisSystem);
52 
56  int GetOriginalUpAxis() const;
58 
63 
67  void SetSystemUnit(const FbxSystemUnit& pOther);
68 
72  FbxSystemUnit GetSystemUnit() const;
73 
77  void SetOriginalSystemUnit(const FbxSystemUnit& pOther);
78 
82  FbxSystemUnit GetOriginalSystemUnit() const;
84 
85 
90 
95  void SetAmbientColor(FbxColor pAmbientColor);
96 
100  FbxColor GetAmbientColor() const;
101 
103 
115  bool SetDefaultCamera(const char* pCameraName);
116 
120  FbxString GetDefaultCamera() const;
122 
130  void SetTimeMode(FbxTime::EMode pTimeMode);
131 
135  FbxTime::EMode GetTimeMode() const;
136 
140  void SetTimeProtocol(FbxTime::EProtocol pTimeProtocol);
141 
145  FbxTime::EProtocol GetTimeProtocol() const;
146 
150  {
154  eSnapAndPlayOnFrame
155  };
156 
160  void SetSnapOnFrameMode(ESnapOnFrameMode pSnapOnFrameMode);
161 
165  ESnapOnFrameMode GetSnapOnFrameMode() const;
166 
170  void SetTimelineDefaultTimeSpan(const FbxTimeSpan& pTimeSpan);
171 
175  void GetTimelineDefaultTimeSpan(FbxTimeSpan& pTimeSpan) const;
176 
180  void SetCustomFrameRate(double pCustomFrameRate);
181 
185  double GetCustomFrameRate() const;
187 
193  {
195  TimeMarker();
196 
200  TimeMarker(const TimeMarker& pTimeMarker);
201 
205  TimeMarker& operator=(const TimeMarker& pTimeMarker);
206 
209 
212 
214  bool mLoop;
215  };
216 
220  int GetTimeMarkerCount() const;
221 
227  TimeMarker GetTimeMarker(int pIndex, FbxStatus* pStatus=NULL) const;
228 
233  void AddTimeMarker(const TimeMarker& pTimeMarker, FbxStatus* pStatus=NULL);
234 
240  void ReplaceTimeMarker(int pIndex, const TimeMarker& pTimeMarker, FbxStatus* pStatus=NULL);
241 
243  void RemoveAllTimeMarkers();
244 
250  bool SetCurrentTimeMarker(int pIndex, FbxStatus* pStatus=NULL);
251 
255  int GetCurrentTimeMarker() const;
257 
258 /*****************************************************************************************************************************
259 ** WARNING! Anything beyond these lines is for internal use, may not be documented and is subject to change without notice! **
260 *****************************************************************************************************************************/
261 #ifndef DOXYGEN_SHOULD_SKIP_THIS
262  virtual FbxObject& Copy(const FbxObject& pObject);
263 
264 protected:
265  FbxPropertyT<FbxInt> UpAxis;
266  FbxPropertyT<FbxInt> UpAxisSign;
267 
268  FbxPropertyT<FbxInt> FrontAxis;
269  FbxPropertyT<FbxInt> FrontAxisSign;
270 
271  FbxPropertyT<FbxInt> CoordAxis;
272  FbxPropertyT<FbxInt> CoordAxisSign;
273 
274  FbxPropertyT<FbxInt> OriginalUpAxis;
275  FbxPropertyT<FbxInt> OriginalUpAxisSign;
276 
277  FbxPropertyT<FbxDouble> UnitScaleFactor;
278  FbxPropertyT<FbxDouble> OriginalUnitScaleFactor;
279 
280  FbxPropertyT<FbxDouble3> AmbientColor;
281  FbxPropertyT<FbxString> DefaultCamera;
282  FbxPropertyT<FbxEnum> TimeMode;
283  FbxPropertyT<FbxEnum> TimeProtocol;
284  FbxPropertyT<FbxEnum> SnapOnFrameMode;
285  FbxPropertyT<FbxTime> TimeSpanStart;
286  FbxPropertyT<FbxTime> TimeSpanStop;
287  FbxPropertyT<FbxDouble> CustomFrameRate;
288 
289 protected:
290  virtual void Construct(const FbxObject* pFrom);
291  virtual void ConstructProperties(bool pForceSet);
292 
293 private:
294  void AxisSystemToProperties();
295  void PropertiesToAxisSystem();
296 
297  void Init();
298 
299  FbxAxisSystem mAxisSystem;
300  int mNbTimeMarkers;
301 
302  friend class FbxWriterFbx6;
303 
304  FbxProperty mTimeMarkers;
305  FbxPropertyT<FbxInt> mCurrentTimeMarker;
306  void AddSetTimeMarker(int pIndex, const TimeMarker& pTimeMarker, FbxStatus* pStatus, bool pAdd);
307 
308 #endif /* !DOXYGEN_SHOULD_SKIP_THIS *****************************************************************************************/
309 };
310 
311 inline EFbxType FbxTypeOf(const FbxTime::EMode&){ return eFbxEnum; }
312 
313 #include <fbxsdk/fbxsdk_nsend.h>
314 
315 #endif /* _FBXSDK_FILEIO_GLOBAL_SETTINGS_H_ */
#define FBXSDK_OBJECT_DECLARE(Class, Parent)
Macro used to declare a new class derived from FbxObject.
Definition: fbxobject.h:61
EFbxType FbxTypeOf(const FbxTime::EMode &)
FBX SDK environment definition.
EProtocol
Time protocols enumaration.
Definition: fbxtime.h:118
This class represents the coordinate system of the scene and can convert scenes to other coordinate s...
Definition: fbxaxissystem.h:97
#define NULL
Definition: fbxarch.h:210
Utility class to manipulate strings.
Definition: fbxstring.h:66
Class to represent colors in RGBA format using doubles.
This class facilitates the testing/reporting of errors.
Definition: fbxstatus.h:26
This class contains functions for accessing global settings.
EFbxType
Type identifier constants.
Class to encapsulate time units.
Definition: fbxtime.h:44
The base class of most FBX objects.
Definition: fbxobject.h:157
EMode
Time modes.
Definition: fbxtime.h:90
Enumeration.
Class to hold user properties.
Definition: fbxproperty.h:37
This class describes the units of measurement used within a particular scene.
Definition: fbxsystemunit.h:31
FbxString mName
Marker name.
#define FBXSDK_DLL
Definition: fbxarch.h:173
Class to encapsulate time intervals.
Definition: fbxtime.h:508
ESnapOnFrameMode
Snap on frame mode.