<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>sjt &#187; XSI</title>
	<atom:link href="http://sjt.is/category/xsi/feed/" rel="self" type="application/rss+xml" />
	<link>http://sjt.is</link>
	<description>[insert clever tagline here]</description>
	<lastBuildDate>Tue, 08 May 2012 23:38:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>XSICollections, python and you</title>
		<link>http://sjt.is/2011/06/24/xsicollections-python-and-you/</link>
		<comments>http://sjt.is/2011/06/24/xsicollections-python-and-you/#comments</comments>
		<pubDate>Fri, 24 Jun 2011 14:06:52 +0000</pubDate>
		<dc:creator>sjt</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[XSI]]></category>

		<guid isPermaLink="false">http://sjt.is/?p=333</guid>
		<description><![CDATA[Have you ever called a some scripting function in Softimage and gotten back an XSICollection and printed that return value only to get a &#8216;None&#8217; value printed to the log? Don&#8217;t worry, you got some data there. Just remember that thats the way python in Softimage prints XSICollections if you would iterate over the collection [...]]]></description>
			<content:encoded><![CDATA[<p>Have you ever called a some scripting function in Softimage and gotten back an XSICollection and printed that return value only to get a &#8216;None&#8217; value printed to the log?<br />
Don&#8217;t worry, you got some data there. Just remember that thats the way python in Softimage prints XSICollections if you would iterate over the collection you will find your values:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">for</span> <span style="color: #008000;">object</span> <span style="color: #ff7700;font-weight:bold;">in</span> returnedCollectin:
   <span style="color: #808080; font-style: italic;"># do something with object</span>
   ...</pre></div></div>

<p>I have seen some people who just started scripting in xsi run in to this little issue.</p>
]]></content:encoded>
			<wfw:commentRss>http://sjt.is/2011/06/24/xsicollections-python-and-you/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What I learned today #2: Various definitions of TEMP</title>
		<link>http://sjt.is/2010/10/04/what-i-learned-today-2-various-definitions-of-temp/</link>
		<comments>http://sjt.is/2010/10/04/what-i-learned-today-2-various-definitions-of-temp/#comments</comments>
		<pubDate>Mon, 04 Oct 2010 20:10:38 +0000</pubDate>
		<dc:creator>sjt</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[whatilearnedtoday]]></category>
		<category><![CDATA[XSI]]></category>

		<guid isPermaLink="false">http://sjt.is/?p=270</guid>
		<description><![CDATA[In Softimage on Windows, if you fetch the TEMP environment variable e.g. from witihn python (with the os.environ dictionary), you will get a different directory when you get the TEMP variable from outside Softimage. Outside Softimage you get: C:\Users\&#60;username&#62;\some\path\I\cannot\rembemer within it you get: C:\Users\&#60;username&#62;\some\path\I\cannot\rembemer\XSI_temp_### Just in case you wanted to write files to TEMP and [...]]]></description>
			<content:encoded><![CDATA[<p>In Softimage on Windows, if you fetch the <code>TEMP</code> environment variable e.g. from witihn python (with the <code>os.environ</code> dictionary), you will get a different directory when you get the <code>TEMP</code> variable from outside Softimage.<br />
Outside Softimage you get: <br />
<code>C:\Users\&lt;username&gt;\some\path\I\cannot\rembemer</code><br />
within it you get:<br />
<code>C:\Users\&lt;username&gt;\some\path\I\cannot\rembemer\XSI_temp_###</code> </p>
<p>Just in case you wanted to write files to <code>TEMP</code> and read from them later.</p>
]]></content:encoded>
			<wfw:commentRss>http://sjt.is/2010/10/04/what-i-learned-today-2-various-definitions-of-temp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Match translation &#8220;tool&#8221; for Maya</title>
		<link>http://sjt.is/2007/10/18/match-translation-tool-for-maya/</link>
		<comments>http://sjt.is/2007/10/18/match-translation-tool-for-maya/#comments</comments>
		<pubDate>Thu, 18 Oct 2007 03:15:55 +0000</pubDate>
		<dc:creator>sjt</dc:creator>
				<category><![CDATA[3D]]></category>
		<category><![CDATA[Maya]]></category>
		<category><![CDATA[Scripting]]></category>
		<category><![CDATA[XSI]]></category>

		<guid isPermaLink="false">http://blog.sjt.is/2007/10/18/match-translation-tool-for-maya/</guid>
		<description><![CDATA[For those who have used XSI for anything have most likely encountered the very useful &#8220;Match translation&#8221; tool (and it&#8217;s variants). This tool exists in Maya but according to some it doesn&#8217;t work very well especially when within a hierarchy. So a solution was to constrain the object you want to move to the object [...]]]></description>
			<content:encoded><![CDATA[<p>For those who have used XSI for anything have most likely encountered the very useful &#8220;Match translation&#8221; tool (and it&#8217;s variants). This tool exists in Maya but according to some it doesn&#8217;t work very well especially when within a hierarchy. So a solution was to constrain the object you want to move to the object that we want to match the translation to and then, in the outliner, delete the constraint.<br />
<br />
This obviously is very tedious especially if you want to this many times. So I decided to try creating my first mel scripts and created a set of scripts in a custom shelf that do this automatically. Here is the &#8220;Match translation&#8221; script:<br />
<br /><code>string $nodes[];<br />
$nodes = `selectedNodes`;<br />
pointConstraint -name tmpconstraint -offset 0 0 0 -weight 1;<br />
select -r tmpconstraint;<br />
delete;<br />
select $nodes[size($nodes)-1];<br /></code></p>
<p>&nbsp;</p>
<p>This script simply automates the steps listed above and the other variants (translation+orientation, orientation, scale) all work in almost the same way.<br />
<br />
These scripts work like this: you first pick the object that you want to match the translation to and second select the object you want to move and then hit one of the shelf buttons. Simple right?<br />
<br />
I like to use these script as marking menus and on that note I was thinking about creating a tutorial that shows how to add custom marking menus, since I guess that some people simply don&#8217;t know how to do that (but many of you do). That tutorial will hopefully be up soon.<br />
<br />
Anyway, you can find the script <a href="http://blog.sjt.is/efni/shelf_sjt_MEL.mel.zip">here</a> and to install it you simply place it in <br />&nbsp;<br />  <code>/Users/<user>/Library/Preferences/Autodesk/maya/8.5/prefs/shelves (on a mac)</code><br /> &nbsp; <br />  and I can&#8217;t remember where to place it on other platforms.</p>
]]></content:encoded>
			<wfw:commentRss>http://sjt.is/2007/10/18/match-translation-tool-for-maya/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

