FBSystem - The System Class
The System Class
The FBSystem
class exposes many system properties, including the computer name (FBSystem.ComputerName
), the system time (FBSystem.SystemTime
), the process memory (FBSystem.ProcessMemory
), the MotionBuilder installation directory (FBSystem.ApplicationPath
), and the MotionBuilder version information (FBSystem.Version
) to name but a few.
It is implemented as a singleton, and also contains references to important objects such as the MotionBuilder scene (FBScene
), the current take (FBTake
), and the viewport (FBRenderer
). The following Python code snippet illustrates how to access the MotionBuilder scene and the current take from the FBSystem
object.
from pyfbsdk import *
scene = FBSystem().Scene
currentTake = FBSystem().CurrentTake
The FBSystem
is also responsible for:
- Loading and managing dynamic libraries (.dll's) through functions such as
FBSystem.LibraryLoad()
andFBSystem.LibraryFree()
. - Managing event callbacks through properties such as
FBSystem.OnUIIdle
,FBSystem.OnConnectionNotify
,FBSystem.OnConnectionDataNotify
, andFBSystem.OnConnectionStateNotify
. For more information, consult and execute the BasicOperations/FBSystemEvents.py Python sample. - Exposing audio/video inputs and outputs, as well as comm port availability via the following properties:
FBSystem.AudioInputs
,FBSystem.AudioOutputs
,FBSystem.VideoInputs
,FBSystem.VideoOutputs
, andFBSystem.CommPorts
.
Note: File I/O is encapsulated by the
FBApplication
class, which can be used to import and export scene data. For more information, consult the FBApplication - File I/O and Application Utilities topic.