Difference between revisions of "IC Python API:RLPy RApplication"

From Reallusion Wiki!
Jump to: navigation, search
(Returns)
m
 
Line 16: Line 16:
 
:API version (major, minor, sub-version) - int tuple
 
:API version (major, minor, sub-version) - int tuple
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get api version
 
# Get api version
 
api_version = RLPy.RApplication.GetApiVersion()
 
api_version = RLPy.RApplication.GetApiVersion()
Line 31: Line 31:
 
:API major version - int
 
:API major version - int
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get api major version
 
# Get api major version
 
api_major_version = RLPy.RApplication.GetApiMajorVersion()
 
api_major_version = RLPy.RApplication.GetApiMajorVersion()
Line 44: Line 44:
 
:API minor version - int
 
:API minor version - int
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get api minor version
 
# Get api minor version
 
api_minor_version = RLPy.RApplication.GetApiMinorVersion()
 
api_minor_version = RLPy.RApplication.GetApiMinorVersion()
Line 57: Line 57:
 
:Custom data path - string
 
:Custom data path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get custom data path
 
# Get custom data path
 
custom_data_path = RLPy.RApplication.GetCustomDataPath()
 
custom_data_path = RLPy.RApplication.GetCustomDataPath()
Line 70: Line 70:
 
:Default project path - string
 
:Default project path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get default project path
 
# Get default project path
 
default_project_path = RLPy.RApplication.GetDefaultProjectPath()
 
default_project_path = RLPy.RApplication.GetDefaultProjectPath()
Line 83: Line 83:
 
:Product major version - int
 
:Product major version - int
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get product major version
 
# Get product major version
 
product_major_version = RLPy.RApplication.GetProductMajorVersion()
 
product_major_version = RLPy.RApplication.GetProductMajorVersion()
Line 96: Line 96:
 
:Product minor version - int
 
:Product minor version - int
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get product minor version
 
# Get product minor version
 
product_minor_version = RLPy.RApplication.GetProductMinorVersion()
 
product_minor_version = RLPy.RApplication.GetProductMinorVersion()
Line 109: Line 109:
 
:Product name - string
 
:Product name - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get product name
 
# Get product name
 
product_name = RLPy.RApplication.GetProductName()
 
product_name = RLPy.RApplication.GetProductName()
Line 122: Line 122:
 
:Product version (major, minor, subversion) - int tuple
 
:Product version (major, minor, subversion) - int tuple
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get product version
 
# Get product version
 
product_version = RLPy.RApplication.GetProductVersion()
 
product_version = RLPy.RApplication.GetProductVersion()
Line 137: Line 137:
 
:Program path - string
 
:Program path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get program path
 
# Get program path
 
program_path = RLPy.RApplication.GetProgramPath()
 
program_path = RLPy.RApplication.GetProgramPath()
Line 150: Line 150:
 
:Shared custom data path - string
 
:Shared custom data path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get shared custom data path
 
# Get shared custom data path
 
shared_custom_data_path = RLPy.RApplication.GetSharedCustomDataPath()
 
shared_custom_data_path = RLPy.RApplication.GetSharedCustomDataPath()
Line 163: Line 163:
 
:Shared template data path - string
 
:Shared template data path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get shared template data path
 
# Get shared template data path
 
shared_template_data_path = RLPy.RApplication.GetSharedTemplateDataPath()
 
shared_template_data_path = RLPy.RApplication.GetSharedTemplateDataPath()
Line 176: Line 176:
 
:Template data path - string
 
:Template data path - string
  
<syntaxhighlight lang="Python">
+
<syntaxhighlight lang="python" line='line'>
 
# Get template data path
 
# Get template data path
 
template_data_path = RLPy.RApplication.GetTemplateDataPath()
 
template_data_path = RLPy.RApplication.GetTemplateDataPath()
 
print(template_data_path)
 
print(template_data_path)
 
</syntaxhighlight>
 
</syntaxhighlight>

Latest revision as of 23:21, 13 April 2020

Main article: Modules.
Last modified: 04/13/2020

Description

This class mainly provides information about the application, such as application version number, API version number, or related application paths.

Member Functions

GetApiVersion ( self )

Get API version.

Returns

API version (major, minor, sub-version) - int tuple
1 # Get api version
2 api_version = RLPy.RApplication.GetApiVersion()
3 print(api_version)
4 if api_version < (2,0,0):
5    print("API 2.0 is still in development.")

GetApiMajorVersion ( self )

Get API major version.

Returns

API major version - int
1 # Get api major version
2 api_major_version = RLPy.RApplication.GetApiMajorVersion()
3 print(api_major_version)

GetApiMinorVersion ( self )

Get API minor version.

Returns

API minor version - int
1 # Get api minor version
2 api_minor_version = RLPy.RApplication.GetApiMinorVersion()
3 print(api_minor_version)

GetCustomDataPath ( self )

Get custom data folder path.

Returns

Custom data path - string
1 # Get custom data path
2 custom_data_path = RLPy.RApplication.GetCustomDataPath()
3 print(custom_data_path)

GetDefaultProjectPath ( self )

Get default project path.

Returns

Default project path - string
1 # Get default project path
2 default_project_path = RLPy.RApplication.GetDefaultProjectPath()
3 print(default_project_path)

GetProductMajorVersion ( self )

Get product major version.

Returns

Product major version - int
1 # Get product major version
2 product_major_version = RLPy.RApplication.GetProductMajorVersion()
3 print(product_major_version)

GetProductMinorVersion ( self )

Get product minor version.

Returns

Product minor version - int
1 # Get product minor version
2 product_minor_version = RLPy.RApplication.GetProductMinorVersion()
3 print(product_minor_version)

GetProductName ( self )

Get product name.

Returns

Product name - string
1 # Get product name
2 product_name = RLPy.RApplication.GetProductName()
3 print(product_name)

GetProductVersion ( self )

Get product version.

Returns

Product version (major, minor, subversion) - int tuple
1 # Get product version
2 product_version = RLPy.RApplication.GetProductVersion()
3 print(product_version)
4 if product_version < (8,0,0):
5    print("iClone 8 is still in development.")

GetProgramPath ( self )

Get program path.

Returns

Program path - string
1 # Get program path
2 program_path = RLPy.RApplication.GetProgramPath()
3 print(program_path)

GetSharedCustomDataPath ( self )

Get shared custom data path.

Returns

Shared custom data path - string
1 # Get shared custom data path
2 shared_custom_data_path = RLPy.RApplication.GetSharedCustomDataPath()
3 print(shared_custom_data_path)

GetSharedTemplateDataPath ( self )

Get shared template data path.

Returns

Shared template data path - string
1 # Get shared template data path
2 shared_template_data_path = RLPy.RApplication.GetSharedTemplateDataPath()
3 print(shared_template_data_path)

GetTemplateDataPath ( self )

Get template data path.

Returns

Template data path - string
1 # Get template data path
2 template_data_path = RLPy.RApplication.GetTemplateDataPath()
3 print(template_data_path)