Hi guys,
I'm trying to swap out the IES file that a Twilight light points to via Ruby scripting. I'm able to change the ies_Path in the AttributeDictionary, which is reflected in the "Edit Light" GUI, but it doesn't appear that the light actually loads that new data. Is there any way I can force the light to load the IES data?
Thanks for reading!
Force light to load IES data via Ruby
-
- Posts: 4
- Joined: Tue Aug 31, 2021 5:17 pm
- SketchUp: SketchUp Pro 2020
Re: Force light to load IES data via Ruby
You are correct in that. Twilight Render actually stores the light data directly into the scene (kind of like how SketchUp stores images that it uses as textures). So changing the path isn't going to update the data.
Can you describe a bit of your workflow? Maybe we can expose a command via Twilight Render that would "reload" the data into the scene?
Can you describe a bit of your workflow? Maybe we can expose a command via Twilight Render that would "reload" the data into the scene?
-
- Posts: 4
- Joined: Tue Aug 31, 2021 5:17 pm
- SketchUp: SketchUp Pro 2020
Re: Force light to load IES data via Ruby
Thanks for the quick response, Chris.
In short, got a script with a dialog that allows for selecting a light fixture model and selecting a "lamp" for it, each lamp corresponding to different lumens, color, and IES data. The lumens and color have been straightforward enough to update in the AttributeDictionary. It's just getting the IES data to update that's been out of reach.
If you can, exposing a command to reload the IES data would be fantastic!
In short, got a script with a dialog that allows for selecting a light fixture model and selecting a "lamp" for it, each lamp corresponding to different lumens, color, and IES data. The lumens and color have been straightforward enough to update in the AttributeDictionary. It's just getting the IES data to update that's been out of reach.
If you can, exposing a command to reload the IES data would be fantastic!
Who is online
Users browsing this forum: No registered users and 6 guests