[Linux] Softimage, network licenses, and License.env


When you install Softimage 2014 on Linux, the license server name (or IP address) that you enter during setup goes into $SI_HOME/Application/bin/License.env.

rem Licensing method: Standalone | MSSA | Network
SOFTIMAGE_LICENSE_METHOD=Network

rem License servers specified from the setup. Format: [port1]@host1[;[port2]@host2]...
ADSKFLEX_LICENSE_FILE=@my_license_server

So, if you need to change ADSKFLEX_LICENSE_FILE, edit License.env.

ADSKFLEX_LICENSE_FILE is also set in the .xsi resource file (eg $SI_HOME/.xsi_2014_SP2), but License.env takes precedence. Unless, of course, you set ADLM_LICENSE_METHOD or SOFTIMAGE_LICENSE_METHOD:

# Set the ADSKFLEX_LICENSE_FILE
setenv ADSKFLEX_LICENSE_FILE "@192.168.1.221"

# Get License

if ( $?ADLM_LICENSE_METHOD ) then
	setenv SILicMethod $ADLM_LICENSE_METHOD
	setenv ADSKFLEX_LICENSE_FILE $ADSKFLEX_LICENSE_FILE
else if  ( $?SOFTIMAGE_LICENSE_METHOD ) then
	setenv SILicMethod $SOFTIMAGE_LICENSE_METHOD
	setenv ADSKFLEX_LICENSE_FILE $ADSKFLEX_LICENSE_FILE
else if ( -f "$SI_HOME/Application/bin/License.env" ) then
	setenv SILicMethod `sed -n s/SOFTIMAGE_LICENSE_METHOD=//p "$SI_HOME/Application/bin/License.env"`
	setenv ADSKFLEX_LICENSE_FILE `sed -n s/ADSKFLEX_LICENSE_FILE=//p "$SI_HOME/Application/bin/License.env"`
else
	setenv SILicMethod Network
endif

See how the .xsi resource file uses the sed swiss army knife to extract the environment variable values from License.env?

CHM version of Softimage 2014 User Guide


Click image to download
Softimage2014chm
It’s not hard to do:

  • Download and install the HTMLHelp Workshop.
  • Download the local version of the Softimage User Guide.
  • Generate hhp (project), hhc (toc), and hhk (index) files for the HTMLHelp Workshop, and then compile the project. You can even download a utility that does that for you (well, everything but the compiling part).

    I used to do it with a few ad-hoc perl and python scripts, but that utility works great.

  • Or you could just click that image at the top of the page.

Scripting: Finding all materials that contain a specific shader


Given a shader, it’s not too hard to find all materials that use (aka “own”) an instance of that shader. Here’s a Python snippet that does just that.

Note that I don’t check whether or not the shader is actually used. This snippet finds all instances, whether they are used or not (last week I posted another snippet for checking whether a shader instances was ultimately connected to the material).

from sipyutils import si			# win32com.client.Dispatch('XSI.Application')
from sipyutils import disp		# win32com.client.Dispatch
from sipyutils import C			# win32com.client.constants
si = si()

def get_materials_that_use_shader( s ):	
	mats = disp( "XSI.Collection" )	
	oShaderDef = si.GetShaderDef( s.ProgID )
	for i in oShaderDef.ShaderInstances:
		try:
			mats.Add( i.Owners(0) )
		except Exception:
			pass

	mats.Unique = True
	return mats

#
# Find all materials that use a specific shader
#
s = si.Selection(0)
if s.IsClassOf( C.siShaderID ):
	mats = get_materials_that_use_shader( s )
	for m in mats:
		print( "%s in %s" % (m.Name, m.Owners(0)) )
else:
	si.LogMessage( "Cannot find shader instances. Please select a shader." )

# Material in Sources.Materials.DefaultLib
# Material1 in Sources.Materials.DefaultLib
# Material2 in Sources.Materials.DefaultLib
# Material3 in Sources.Materials.DefaultLib
# Material7 in Sources.Materials.DefaultLib
# Material6 in Sources.Materials.DefaultLib
# Material5 in Sources.Materials.DefaultLib
# Material4 in Sources.Materials.DefaultLib

Screenshots of the week


Inverse distance weighting
by grahamef
inverse_distance_weighting

Maths problem
by David Barosin
weighted

Get closest location on group
by Alan Fregtman
ICE_example_GetClosestVertexColorFromGroup2

by Jack Kao
getclosestlocationongroup_temp

Mixed Contexts
by Vladimir Jankijevic
differentContexts_comp

Setting data on a particle based off data from another particle in the same cloud
by Leonard Koch
SeparatingStrandAndParticlesForAlan

Arnold Scene Viewer integrated in Softimage using Creation Platform

Git for Softimage

GitForSoftimage

How to use the cached Face Robot animation on a head

Building your own Voronoi shattering effect with blackjack and hookers in Softimage part 2

ICE: Getting data from other frames


In ICE, you can’t get data from any arbitrary frame. You get whatever data comes though through your input ports for the current evaluation time. There’s no way (except for Get Data at Previous Frame) for you to read the scene graph at any other time than the time at which the ICE Tree operator is being evaluated.

A few related notes:

  • In a simulated ICE tree, you could cache values from previous frames and then access them during playback of the simulation.
  • With Get Action Source at Frame, you can get the value at a specific frame of an item stored in an animation source.
  • On a non-simulated ICE tree, you might be able to use an at_frame expression (hat tip: grahamef)
  • You might consider writing a custom ICE node that accesses values on other frames, but I don’t know that this such a good idea. According to the docs, that isn’t recommended for custom ICE nodes.