Yes, I've got experience with this. A couple of years ago we were
attempting to to import flight data of aircraft landing at a terminal. I
had position and attitude data and was attempting to import that into a
Maya scene. After numerous attempts trying to convert the data via a
Maya move file, I instead imported via the command port. Basically I had
too many aircraft to process the move files easily. I was able to
automate the whole process outside of Maya, process the data standards
conversion, import the external data into maya, generate the
connections, keyframes, etc, via command port. It worked really well,
.....and I got to use Perl to script my Maya scene instead of
MEL...Muwhahahahaa! In fact everything was automated straight from the
perl script I wrote, just start Maya, open the command port, write the
perl script with a port connection to Maya, and execute.
In the case of Maya I found it most useful because there are things you
just can't do well with MEL if they aren't directly tied to a MEL
function or Maya command. This is more to do with the fact MEL is
lacking decent regex tools and is not useful for anything not directly
associated with Maya. XSI doesn't exactly suffer the same restriction
because you have so many different language options for scripting. As
long as you can draw the data into your scripting session, you really
don't need to be outside of the application to get use of a decent
programming language. However, if you are trying to coordinate data back
and forth between two applications using perl or python to synchronize
between say Maya and XSI or XSI and some other scientific visualization
app, having a command port available in XSI would be quite useful.
Joey Ponthieux
NCI Information Systems Inc.
NASA Langley research Center
____________________________________________________________
Opinions stated here-in are strictly those of the author and
do not represent the opinions of NASA or any other party.
Ben Barker wrote:
That sounds pretty cool. Anyone have experience using Maya's
commandPort in production (or something similar) and care to share any
thoughts? Seems like you could do some pretty useful things, besides
sending X rated geometry to Graham's workstation during reviews.
On 12/29/06, Luc-Eric Rousseau <lucer(at)softimage.com> wrote:
Well basically it's not possible to call scripting functions from
outside of
XSI,
because that means calling functions across two processes, and we don't
expose a socket port for scripting.
So what that XSI 6.0 sample does is implement a server in XSI that
listens
to a network socket. Then, outside of XSI you send scripting
commands to
that
socket which are then executed in XSI.
This could be used for example to force an update of a plug-in while
users
are running XSI.
-----Original Message-----
From: Kim Aldis
Interesting -and useful - example but wouldn't it have been easier to
do the
same thing using only a few lines of Python or Perl code?
> -----Original Message-----
> From: Stephen Blair
>
> Hi
>
> If you have XSI 6, take a look at the XSIServer example in the SDK
> example workgroup.
>
> Steve
>
> -----Original Message-----
> From: Greg Smith
>
> I was curious if it was possible to run a script outside of XSI that
> could control some aspect inside XSI. The simplest thing I would like
> to do is to invoke a XSIUIToolbox.Msgbox pop up inside xsi from an
> external script using string data collected from outside of xsi.
>
> Just Curious
>
> Greg
---
Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body:
unsubscribe xsi