Mailing List
Home
Forum Home
Softimage
Carrara
trueSpace
Dir3d-l
Maya - a powerful 3D animation and visual effects software
Macromedia Flash Development
Subjects
Cameras
scaleDown command
black out solved
Aircraft Tutorial
Mathematical XYZ ?
Its done This vs That
Its done first week
recommendations for screen video captures?
3DExplorer "Oddity "
New Director
ProTeam renewals
Fuel 's new websites (X post)
Blue peter create a make toy
targeting groups question
XPost: Shockwave 3D game ( sort of )
RES: RES: RES: Fish Modeling
Emitting particles from object intersection
Fuel 's new websites (X post)
Texturing
Big Break Contest Videos
New Plugins
Models and Texture on my updated site
Error Installing Patch tS6 6
Plasma?
Looking for Inspiration
Weird EMail Q
It 's done first week ?
Cherry not cranberry
New game
Camera Animation Problem
Particle plugins?
 
wrong arguments

wrong arguments

2003-11-28       - By deane@(protected)

 Back
Reply:     1     2     3     4  

On Fri, Nov 28, 2003 at 10:49:22AM +0100, "Horv?tth Szabolcs" wrote:
>
> I have a mel script problem that is related to some 4.5 and 5.0 MR
> rendering process changes.  My script calls two different procedures for
> the old and new maya versions by querying the version.  The problem is
> that the mentalrayPreviewRender process definition of 5.0 is different
> than 4.5`s so when the script is sourced under maya 5, it just spits out
> an arror message:
[...]
> The question is, how can I keep the two commands in the same script, to
> work ok with both versions?
[...]
> if (`substring $version 1 1` == "4" && $renderer == "mentalRay")
>   mentalrayPreviewRender 4 "";
> else
> {
>   if (`substring $version 1 1` == "4")
>     renderWindowRender renderRegion renderView;
>   else
>     renderWindowRenderRegion renderView;

Place the command in a string and execute it using eval():

  if (`substring $version 1 1` == "4" && $renderer == "mentalRay")
    eval("mentalrayPreviewRender 4 \"\"");
  else
  [...]

===========================================================================
 - deane                          Gooroos Software: Plugging you into Maya

                         Visit http://www.gooroos.com for more information

-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---
List-help: <mailto:listar@(protected)?Subject=help>
List-archive: <http://www.highend3d.com/maya/devarchive/>