RE: Constant Pass - How to?

Date : Mon, 4 Feb 2008 11:41:58 -0600
To : <XSI(at)Softimage.COM>
From : "Greg Punchatz" <greg(at)janimation.com>
Subject : RE: Constant Pass - How to?
"Also you can over ride the scene ambience by writing an expression to the
position of a null and overriding the position of the null on a pass by pass
basis. It's a work around but it does work."

You don't need to use a null or an expression to override the scene
ambience, a simple override on the shared global ambience's rgb values in
any partition will effect all objects in that pass. The scenes ambience is a
shared property...so it you override it in anywhere in a pass it changes it
for all objects...regardless of what partition they are in. 

So for a constant pass I usually hide all the lights and up the pass's
ambience to 1 using this technique. 

There is a bit of Python code below that will make two passes...one with the
scenes ambience overridden. 

Greg


Application.CreatePrim("Sphere", "MeshSurface", "", "")
Application.CreatePrim("Cube", "MeshSurface", "", "")
Application.Translate("", 8.60903371326392, 0, 0, "siRelative", "siLocal",
"siObj", "siXYZ", "", "", "", "", "", "", "", "", "", 0, "")
Application.CreatePartition("", "", "", "")
Application.SelectObj("Passes.Default_Pass", "", "")
Application.SelectObj("Passes.Default_Pass", "", "")
Application.SetValue("Passes.Default_Pass.Name", "Default_Pass", "")
Application.Duplicate("Passes.Default_Pass", "", 2, 1, 1, 0, 0, 1, 0, 1, "",
"", "", "", "", "", "", "", "", "", 0)
Application.SelectObj("Passes.Default_Pass1.Background_Objects_Partition",
"", "")
Application.AddProp("Override", "", "", "", "")
Application.SIAddEntryToOverride("Passes.Default_Pass1.Background_Objects_Pa
rtition.Override",
"sphere.AmbientLighting.ambience.red,sphere.AmbientLighting.ambience.green,s
phere.AmbientLighting.ambience.blue", "")
Application.CopyPaste("Passes.Default_Pass1.Background_Objects_Partition.Ove
rride.red", "",
"Passes.Default_Pass1.Background_Objects_Partition.Override.green", 1)
Application.CopyPaste("Passes.Default_Pass1.Background_Objects_Partition.Ove
rride.red", "",
"Passes.Default_Pass1.Background_Objects_Partition.Override.blue", 1)
Application.SetValue("Passes.Default_Pass1.Background_Objects_Partition.Over
ride.red", 0.868, "")
Application.SetCurrentPass("Passes.Default_Pass1")
Application.SetCurrentPass("Passes.Default_Pass")

---
Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body:
unsubscribe xsi


Search the XSI List archives here or use the advanced search form to search across mailing lists. Searching help is available.
This site supposedly brought to you by Benjamin Grosser and the Imaging Technology Group.