script for exporting layers
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
script for exporting layers
hello with another question!
Currently I'm working with files that have footage in them. On top of the footage there are a few other layer with rotoscopes of different parts of the footage, all in the same length as the footage. In order to export the resulty into a compositing program, I need to export each layer seperately into a movie, and name each movie as the corresponding layer.
The way I do it now is manual, going through each layer, making it solely visible, and exporting that to a file. could there be any way of automating the process, by creating a script that will:
1. export each layer seperately into a whole movie file
2. name the exported files as the corresponding layers
I know it's a bit outside the capabilities of the current code, but maybe someone can prove me wrong?
thanks for any suggestion,
a.
Currently I'm working with files that have footage in them. On top of the footage there are a few other layer with rotoscopes of different parts of the footage, all in the same length as the footage. In order to export the resulty into a compositing program, I need to export each layer seperately into a movie, and name each movie as the corresponding layer.
The way I do it now is manual, going through each layer, making it solely visible, and exporting that to a file. could there be any way of automating the process, by creating a script that will:
1. export each layer seperately into a whole movie file
2. name the exported files as the corresponding layers
I know it's a bit outside the capabilities of the current code, but maybe someone can prove me wrong?
thanks for any suggestion,
a.
I think it could be done easily with a george script ... (I don't exactly remember but I think I wrote a script which was exporting all my layers last year, I will search it in my HD)I know it's a bit outside the capabilities of the current code, but maybe someone can prove me wrong?
Btw, the george scripts experts will certainly answer soon
Fabrice Debarge / Beta-Team member / Author of the user-manual.
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
Re: script for exporting layers
I actually wrote this line to provoke the capable people. I don't for a second undermine the power of the code...malcooning wrote: I know it's a bit outside the capabilities of the current code, but maybe someone can prove me wrong?
http://www.tvpaint.com/forum/viewtopic.php?t=537
well done Manuel ! (haven't tried it at the moment however)
well done Manuel ! (haven't tried it at the moment however)
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
Manuel,
this is brilliant. it's exactly what I neede!
You just saved me LOADS of time!
thank you so much.
But I do have one issue:
I changed the extention in the script file to '.mov'. The first time I ran the script, it brought up a session window, in which I could choose the codec to render the quicktime. That was brilliant. But every time I run the script no, it no longer brings up the codec dialogue. Furthermore, how do I set the export to be Millions+ colors, RGB+A, premultimplied Alpha, and 'No Background' options chosen? (I tried to export once normally, setting everything as above, thinking that the script will remember the export setting for next use, but it didn't.)
sorry, one more thing: is there a way to setup a defult directory for the script to export to, instead of punching in the whole path each time?
Cheers,
A.
this is brilliant. it's exactly what I neede!
You just saved me LOADS of time!
thank you so much.
But I do have one issue:
I changed the extention in the script file to '.mov'. The first time I ran the script, it brought up a session window, in which I could choose the codec to render the quicktime. That was brilliant. But every time I run the script no, it no longer brings up the codec dialogue. Furthermore, how do I set the export to be Millions+ colors, RGB+A, premultimplied Alpha, and 'No Background' options chosen? (I tried to export once normally, setting everything as above, thinking that the script will remember the export setting for next use, but it didn't.)
sorry, one more thing: is there a way to setup a defult directory for the script to export to, instead of punching in the whole path each time?
Cheers,
A.
About the path , open the script and replace
by
Code: Select all
tv_ReqString "Enter Path (ending by \)"
path = result
Code: Select all
path = "d:\mypath\"
Manuel
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
I was trying that, and I exported a few times with setting to include an alpha channel, and made sure that no background is rendered. the files I exported were fine. But as soon as I used the script to export, it automatically added the background to the exported files. (just in case, 'none' was selected in the layer panel).
This happenes with AVI and QT alike.
Could this has to do something with the "tv_savemode" line, where 'AVI', or 'QT' should include more parameters?
Any idea? (did you try this yourself, just to make sure?)
This happenes with AVI and QT alike.
Could this has to do something with the "tv_savemode" line, where 'AVI', or 'QT' should include more parameters?
Any idea? (did you try this yourself, just to make sure?)
I have added :
to the script, but still have no alpha with qt.
I'm not a QT expert and don't have the latest drivers.
I can't help more, sorry.
Code: Select all
tv_AlphaSaveMode PreMultiply
I'm not a QT expert and don't have the latest drivers.
I can't help more, sorry.
Manuel
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
ok,
I've checked both QT and AVI exports. it seems that it does export as the last setup that was defined in the export session. Which means that it does export alpha only, or rgb+alpha.
The problem here is that via the script, it always adds the 'background' option. regardless of whether it was ticked off at the export dialogue. It happenes both with AVI and QT here.
do you manage to export AVI with alpha via the script?
is there a way to add a line into the script that slects 'no background'?
Zigotto, I've tried restarting with saved config, but it didn't make a difference, apart from allowing again to choose a codec for QT.
Thanks for your efforts Manuel.
I've checked both QT and AVI exports. it seems that it does export as the last setup that was defined in the export session. Which means that it does export alpha only, or rgb+alpha.
The problem here is that via the script, it always adds the 'background' option. regardless of whether it was ticked off at the export dialogue. It happenes both with AVI and QT here.
do you manage to export AVI with alpha via the script?
is there a way to add a line into the script that slects 'no background'?
Zigotto, I've tried restarting with saved config, but it didn't make a difference, apart from allowing again to choose a codec for QT.
Thanks for your efforts Manuel.
- malcooning
- Posts: 2114
- Joined: 29 Mar 2006, 12:43
- Location: Tel Aviv
- Contact:
Manuel,
I kiss you. this script is perfect. works like a charm, and very smooth.
This should be embedded in the next release of tvpaint for certain.
Thank you for taking time to see to this script.
by the way, the changes that you made, do they mean that now, when exporting, each layer is rendered into a custom brush, and then the seperate brushes are exported to movies?
I wish I had the patience to learn the code and write my own scripts.
This will add a whole new dimension of tvpaint experince for me!
thank you millions.
A.
I kiss you. this script is perfect. works like a charm, and very smooth.
This should be embedded in the next release of tvpaint for certain.
Thank you for taking time to see to this script.
by the way, the changes that you made, do they mean that now, when exporting, each layer is rendered into a custom brush, and then the seperate brushes are exported to movies?
I wish I had the patience to learn the code and write my own scripts.
This will add a whole new dimension of tvpaint experince for me!
thank you millions.
A.