Difference between revisions of "IC Python API:Smooth Camera Follow"

From Reallusion Wiki!
Jump to: navigation, search
m
m (Steps to Take)
Line 24: Line 24:
 
# Load the script into the project from the menu: '''Plugins > Python Samples > Smooth Camera Follow'''.
 
# Load the script into the project from the menu: '''Plugins > Python Samples > Smooth Camera Follow'''.
 
# Follow the instructions in the subsequent dialog window.
 
# Follow the instructions in the subsequent dialog window.
 +
 +
=== Modules Used ===
 +
====main.py====
 +
<div style="column-count:4; -moz-column-count:4; -webkit-column-count:4">
 +
* [[ IC_Python_API:RLPy_REventCallback#__init__ | RLPy.REventCallback.__init__() ]]
 +
* [[ IC_Python_API:RLPy_RMatrix3 | RLPy.RMatrix3() ]]
 +
* [[ IC_Python_API:RLPy_REventHandler#UnregisterCallback | RLPy.REventHandler.UnregisterCallback() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#SetTime | RLPy.RGlobal.SetTime() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#GetStartTime | RLPy.RGlobal.GetStartTime() ]]
 +
* [[ IC_Python_API:RLPy_RQuaternion | RLPy.RQuaternion() ]]
 +
* [[ IC_Python_API:RLPy_RTransform | RLPy.RTransform() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#IsPlaying | RLPy.RGlobal.IsPlaying() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#GetTime | RLPy.RGlobal.GetTime() ]]
 +
* [[ IC_Python_API:RLPy_RMath#Min | RLPy.RMath.Min() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#Stop | RLPy.RGlobal.Stop() ]]
 +
* [[ IC_Python_API:RLPy_REventHandler#RegisterCallback | RLPy.REventHandler.RegisterCallback() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#Play | RLPy.RGlobal.Play() ]]
 +
* [[ IC_Python_API:RLPy_RGlobal#GetEndTime | RLPy.RGlobal.GetEndTime() ]]
 +
* [[ IC_Python_API:RLPy_RUi#ShowMessageBox | RLPy.RUi.ShowMessageBox() ]]
 +
* [[ IC_Python_API:RLPy_RUi#AddMenu | RLPy.RUi.AddMenu() ]]
 +
* [[ IC_Python_API:RLPy_RUi#CreateRDockWidget | RLPy.RUi.CreateRDockWidget() ]]
 +
* [[ IC_Python_API:RLPy_RVector3 | RLPy.RVector3() ]]
 +
</div>
 +
 +
====Extensions.py====
 +
<div style="column-count:4; -moz-column-count:4; -webkit-column-count:4">
 +
* [[ IC_Python_API:RLPy_RMath#Abs | RLPy.RMath.Abs() ]]
 +
* [[ IC_Python_API:RLPy_RVector3 | RLPy.RVector3() ]]
 +
* [[ IC_Python_API:RLPy_RQuaternion | RLPy.RQuaternion() ]]
 +
* [[ IC_Python_API:RLPy_RScene#FindObjects | RLPy.RScene.FindObjects() ]]
 +
</div>

Revision as of 02:16, 11 April 2019

Main article: RL Python Samples.

Smooth Camera Follow

This script lets the user pick a camera/view and a prop/target to follow. The camera will always be facing the direction of the target prop with delay as an adjustable factor. The Offset values creates a distance between the view and the target. Use the Delay value to create a lag between the view and the target.

Camera WIKI Code Route.png

Learn How to

  • Drive the motion of the camera according to the animation of a prop.
  • Populate drop down menus/combo boxes with elements from the scene.
  • Set timer and event callbacks and attach commands.

Required Files

  • iClone scene with camera and animated prop
  • Smooth Camera Follow Python script
  • Extensions Python script

Steps to Take

  1. Unzip the contents of Smooth Camera Follow.zip into the iClone install directory ...\Bin64\OpenPlugin.
  2. Load the script into the project from the menu: Plugins > Python Samples > Smooth Camera Follow.
  3. Follow the instructions in the subsequent dialog window.

Modules Used

main.py

Extensions.py