Profile Picture

python reading light time keys

Posted By frank_461853 4 Years Ago
You don't have permission to rate!
Author
Message
frank_461853
frank_461853
Posted 4 Years Ago
View Quick Profile
Senior Member

Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)

Group: Forum Members
Last Active: 3 Months Ago
Posts: 26, Visits: 98
I'm not sure if t his is the right place to post this but given how unimpressed i am with iclones python documentation, i feel i have no other choice. 

I amd playing wiht scripting iclone's animations via python and one thing i sish to do is read the keys where a light changes it's brightness multiplier

of course  i tried this
    control = thisObject.GetControl("Transform")
but naturally the brightness doesn't come under Transform. So i took a guess and tried 

     control = thisObject.GetControl("Multiplier")
but that didn't work, an the page where GetControl is explains lacks any information of what other values you can put in as a parameter 
So does anyone know how a can read the ckey changes on a light's multplier changes? Thank you very much 

 
videodv
videodv
Posted 4 Years Ago
View Quick Profile
Distinguished Member

Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)Distinguished Member (2.9K reputation)

Group: Forum Members
Last Active: 2 Years Ago
Posts: 342, Visits: 12.0K
Check this link hopefully it's what you want Here
frank_461853
frank_461853
Posted 4 Years Ago
View Quick Profile
Senior Member

Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)

Group: Forum Members
Last Active: 3 Months Ago
Posts: 26, Visits: 98
videodv (12/6/2021)
Check this link hopefully it's what you want Here

thanks but i've been there already. it's they keyframs of the light i'm after. i know it has something to do with Rcontrol but the relevent parameters which would allow me to find what keyframes brightness change etc ha thus far eluded me. 


gordryd
gordryd
Posted 4 Years Ago
View Quick Profile
Distinguished Member

Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)Distinguished Member (5.2K reputation)

Group: Forum Members
Last Active: 3 days ago
Posts: 730, Visits: 8.0K
The wiki has a section for lights: https://wiki.reallusion.com/IC_Python_API:RLPy_RILight
There is a section specifically about multipliers there (the formatting of the sample code got messed up during copy/paste below):

GetMultiplier ( self )

Get the light's current strength.

See Also: SetMultiplier

Returns

The strength of the light - float
1 # Get light object2 light_object = RLPy.RScene.FindObject(RLPy.EObjectType_Light, "Spotlight")3 4 # Get light object multiplier value5 multiplier_value = light_object.GetMultiplier()6 print(multiplier_value)


Reallusion Certified Director / Reallusion Best Visual Award / Reallusion Certified Content Developer
See all the G-Tools Plug-Ins available for iClone here: G-Tools Plug-Ins


frank_461853
frank_461853
Posted 4 Years Ago
View Quick Profile
Senior Member

Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)Senior Member (491 reputation)

Group: Forum Members
Last Active: 3 Months Ago
Posts: 26, Visits: 98
No Gors, that's now what i'm looking dor. i already said to videotv. i'm after whatever returns the keyframe ot the light brightness status. Rcontrol.getControl would be the relevant but the only parameter provided in the documentation of the function is "translation" which only returns the keyframe data of the movement of the light, not the keyframes where it's brightness changes. i already know how to get and set the multiplier, what i'm after is retrieving the keyframes where the brightness multiplier changes.

gordryd (12/6/2021)
The wiki has a section for lights: https://wiki.reallusion.com/IC_Python_API:RLPy_RILight
There is a section specifically about multipliers there (the formatting of the sample code got messed up during copy/paste below):

GetMultiplier ( self )

Get the light's current strength.

See Also: SetMultiplier

Returns

The strength of the light - float
1 # Get light object2 light_object = RLPy.RScene.FindObject(RLPy.EObjectType_Light, "Spotlight")3 4 # Get light object multiplier value5 multiplier_value = light_object.GetMultiplier()6 print(multiplier_value)





Reading This Topic