IC Python API:RLPy RGlobal
From Reallusion Wiki!
Contents
- Main article: System Module.
Class in RLPy / Inherits from: _object
Description
This class provides many of the common API global functions.
Member Functions
Function | Syntax | Description | Examples |
---|---|---|---|
IsPlaying | def RLPy.RGlobal.IsPlaying()
|
Check if the timeline is playing and returns either TRUE or FALSE. | import RLPy
print(RLPy.RGlobal.IsPlaying())
# True / False
|
GetProjectLength | def RLPy.RGlobal.GetProjectLength()
|
Get the length of the project in milliseconds. | Fetch the current frame time in milliseconds: import RLPy
# Put the current frame time into a variable.
time = RLPy.RGlobal.GetTime()
# Return the current frame time in milliseconds.
print(time.GetValue())
|
GetFps | def RLPy.RGlobal.GetFps()
|
Get frames per second. | Get the project frames per second. import RLPy
# Get frames per second
print(RLPy.RGlobal.GetFps())
#60
|
GetPath | def RLPy.RGlobal.GetPath(ePath, strPath)
|
Get iClone related path locations using the following enumeration (ePath):
|
Print out a few path locations (Individual path locations may vary). import RLPy
temp = ""
ret_list = RLPy.RGlobal.GetPath(RLPy.EPathType_Temp, temp)
print("Temp folder: "+ret_list[1])
# Temp folder: C:\Users\User_Name\AppData\Local\Temp\iClone7Temp\iClone7Temp\
ret_list = RLPy.RGlobal.GetPath(RLPy.EPathType_TemplateContent, temp)
print("Template content folder: "+ret_list[1])
# Template content folder: C:\Users\Public\Documents\Reallusion\Template\iClone 7 Template
ret_list = RLPy.RGlobal.GetPath(RLPy.EPathType_CustomContent, temp)
print("Custom content folder: "+ret_list[1])
# Custom content folder: C:\Users\Public\Documents\Reallusion\Custom\iClone 7 Custom
ret_list = RLPy.RGlobal.GetPath(RLPy.EPathType_ProgramDefault, temp)
print("Program default folder: "+ret_list[1])
# Program default folder: C:\Program Files\Reallusion\iClone 7\Program\Default\
|