|
headus 3D tools / 3D scans Support Forums
|
|
View previous topic :: View next topic |
Author |
Message |
JamesH
Posts: 17
Joined: 10 Jul 2007
|
Posted: Tue Jul 14, 2009 11:15 am Post subject: Possibility to not auto delete the .out File |
|
|
I'm writing a plugin at the moment and having to use perl, the problem is that I have to use the system command to run UVLayout and the 3D application loses focus until the command has completed. So as soon as UVLayout closes and passes focus back to the app, the .out file has already been deleted.
Would it be possible to modify UVL to allow a parameter passed in to instuct UVL to not delete the .out file ?
What do you think ?
Cheers
James. |
|
Back to top |
|
|
headus Site Admin
Posts: 2899
Joined: 24 Mar 2005
Location: Perth, Australia
|
Posted: Tue Jul 14, 2009 9:09 pm Post subject: |
|
|
Normally you'd want to leave UVLayout running all the time, instead of restarting and exiting again each time you send an object over. The "out" file is being deleted because UVLayout cleans up after itself whenever it exits.
What I recommend is reading up on how to start a background process in Perl, and run UVLayout that way. I've never used perl, but some googling came up with ...
system( "command &")
... but I'm not sure if that a Unix thing only and wont work under Windows.
Maybe the "open" command is a better way? It'll start the command and return control back to the script.
Phil |
|
Back to top |
|
|
JamesH
Posts: 17
Joined: 10 Jul 2007
|
Posted: Tue Jul 14, 2009 11:56 pm Post subject: |
|
|
Thanks for the reply Phil. I've decided to move over to python after realising that perl is proving too difficult to run uvlayout in a background process.
I've run a quick test in python and it seems the functionality I need is there.
I'll post my results in the next few days.
Cheers. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|