Created
November 18, 2012 11:55
-
-
Save fraguada/4104781 to your computer and use it in GitHub Desktop.
Small example method to edit Rhino light properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void RunScript(Guid id, Color col, double pow, ref object A) | |
{ | |
Rhino.DocObjects.ObjRef obj = new Rhino.DocObjects.ObjRef(id); | |
Rhino.DocObjects.LightObject lobj = obj.Object() as Rhino.DocObjects.LightObject; | |
lobj.LightGeometry.Diffuse = col; | |
lobj.LightGeometry.Intensity = pow; | |
lobj.CommitChanges(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment