WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 10-29-2003, 10:13 AM
hotspur1 hotspur1 is offline
Member
 
Join Date: Mar 2003
Location: Cambridge, MA
Posts: 54
running scripts without the IDE showing

Is it possible to run a Vizard script from the command line

Vizard.exe -r myscript.py

and not have the splashscreen and/or the Vizard IDE pop up (or perhaps come up as minimized?)
Reply With Quote
  #2  
Old 10-29-2003, 11:17 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Yeah, this is possible with version 2.12 and higher. Try this:

winviz.exe 0 myscript.py

winviz.exe is in the same directory as Vizard.exe. The first argument is a number, which you don't need to worry about, and the second argument is the path to the script, which should usually be the full path, not just the script name.
Reply With Quote
  #3  
Old 10-29-2003, 01:30 PM
hotspur1 hotspur1 is offline
Member
 
Join Date: Mar 2003
Location: Cambridge, MA
Posts: 54
Hmmm....

I have downloaded v2.12 and tried out your suggestion without success...

The first time, I typed

"C:\Program Files\Vizard20\bin\winviz.exe" 0 simpleworld.py

and the 2nd time I changed directories to Vizard's bin directory and typed:

winviz.exe 0 N:\AndyL\PythonPractice\simpleworld.py

and both times I got the following error. (That's a zero as the second arg)

Vizard 2.12
Traceback (most recent call last):
File "<string>", line 12 in ?
IOError: [Errno 2] No such file or directory: '0' (zero)
CameraGroup::_sync() : _syncBarrier not created cannot block
Reply With Quote
  #4  
Old 10-29-2003, 01:45 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
oops...my bad

I got it backwards, the first argument is the script and the second argument is the number, hope i didn't cause too much headache.
Reply With Quote
  #5  
Old 10-29-2003, 08:29 PM
hotspur1 hotspur1 is offline
Member
 
Join Date: Mar 2003
Location: Cambridge, MA
Posts: 54
OK, swapping the arguments go it to launch ok, but I notice that the evaluation splash screen pops up even though I have a licensed copy of Vizard. Is there a way to fix this or make it go away?

Also, I had been passing some other arguments to my scripts via command line (see the thread 15 - "Passing arguments to Vizard"). Is this possible to do when calling winviz directly?

Last edited by hotspur1; 10-29-2003 at 08:34 PM.
Reply With Quote
  #6  
Old 10-30-2003, 10:56 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
oops...another bad

I'll create a fix for that as soon as possible.

You should be able to pass arguments to your script. Just add them after the 0 and you can access them as usual in your script by using viz.args.
Reply With Quote
  #7  
Old 10-30-2003, 11:17 AM
hotspur1 hotspur1 is offline
Member
 
Join Date: Mar 2003
Location: Cambridge, MA
Posts: 54
Thanks Farshid - appreciate all your help.

Just one other matter - I got a copy of the Release notes which shows an example of starting from the command line, but it doesn't include the final '0' - I guess the Release Notes should get corrected....

I also noted that after I run winviz in this way in the Command Window (Win2k), I cannot use the close button anymore to close the window! I have to go to the Task Manager to end the process...

Last edited by hotspur1; 10-30-2003 at 11:21 AM.
Reply With Quote
  #8  
Old 10-30-2003, 11:36 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Thanks for pointing that out.

About the command window, you'll have to take that up with Andy. Either way, you should be able to type "exit" to close it.
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 09:46 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC