[SItoA] Doing a license check in Softimage


Setting up the environment right is what often goes wrong. Running kick -licensecheck from inside Softimage is a quick way to check that you set up the environment variables correctly.

Here’s two lines of Python that will open a command prompt and run kick -licensecheck (on Windows).

#Python
from subprocess import Popen
Popen(["cmd", "/K", XSIUtils.BuildPath( Application.Plugins('Arnold Render').OriginPath, 'kick.exe' ), "-licensecheck"])

Here’s the same thing, but broken down a bit for legibility:

#Python
si = Application

p = si.Plugins('Arnold Render')
sKick = XSIUtils.BuildPath( p.OriginPath, 'kick.exe' )

from subprocess import Popen
Popen(["cmd", "/K", sKick, "-licensecheck"])

Noise, world coordinates, and offsets


If you’re using world coordinates for your noise, then obviously as an object moves in global space, the noise will change. Here I’ve extracted a polygon and moved it: same shader tree that uses noise, but different noise because I’m using world coordinates.
noise_world

You could keep the same noise by applying an offset equal to the translation:
noise_world_offset_1
Note that I’ve assumed that there’s no scaling of the noise. If there was, I’d have to multiply my offset by the same scaling.

Just for kicks: listing the available shaders


Want to know what shaders come with SItoA?

Use kick -nodes with the -l flag to get a list of all nodes. For example:

kick -nodes -l %SITOA_BINDIR%\sitoa_shaders.dll | find "shader"

where SITOA_BINDIR is just shorthand for the Application\bin\nt-x86-64 folder of your SItoA addon install. On my machine, that’s here:

C:\Users\SOLIDANGLE\Documents\Workgroups\sitoa-2.6.0-2013\Addons\SItoA\Application\bin\nt-x86-64

The output will list the builtin Arnold shaders first (such as ambient_occlusion, standard, and wireframe), and then the SItoA shaders (which start with the two BA_ shaders).

In general, you wouldn’t include a filename in the -l path. I included sitoa_shaders.dll so kick wouldn’t try to load sitoa_curves_proc.dll and then pop up a “sicppsdk.dll is missing” error because I’m not running kick in a Softimage command prompt (where all the Softimage environment variables are set for me).

So, a more general example would look like this:

kick -nodes t -l %SITOA_BINDIR%

-nodes t will sort the list of nodes by type.