Skip to content

Instantly share code, notes, and snippets.

@fraguada
Created November 18, 2012 11:55
Show Gist options
  • Save fraguada/4104781 to your computer and use it in GitHub Desktop.
Save fraguada/4104781 to your computer and use it in GitHub Desktop.
Small example method to edit Rhino light properties
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