Codec for Editing Animation Sequences

upbeatUnique wrote on 4/8/2010, 4:19 PM
Hi,

I have the latest Vegas Video and I am looking to edit an animated project. The footage is all rendered from a 3d package as image sequences. Should I import the image sequences directly into Vegas or should I process each clip as a single movie using an uncompressed 4:2:2 10bit codec (BlackMagicDesign, Sony YUV or Kona)?
The files are 864x486 square pixels, and the final project will be distributed on DVD.
My computer is an i7 2.67Ghz, 9 GB memory and 64bit Windows 7, with a GeForce GTX 260 graphics card.
Is this configuration conducive for using 4:2:2 codec without the hardware boards? What is the best work flow for reducing Hard Drive space but retaining the quality of the original material?
I find this confusing and would like to make sure I start the right way.
Thanks for any help.

Sincerely,
Dan

Comments

PerroneFord wrote on 4/8/2010, 9:38 PM
What options do you have for exporting the image sequences? I'd select PNGs or DPX files personally.
rmack350 wrote on 4/8/2010, 10:31 PM
You definitely don't need a hardware board for this. Those days are long passed.

You don't say what sort of images your 3D program gave you but PNG would be the best choice for Vegas. and you may need a little preprocessing to get the images to a size that'll work. It looks to me like an NTSC Widescreen Standard project in Vegas would expect 873x486 images but if your 3D application won't give you that you can probably adapt. Besides, DVD Architect will probably want 873x480, not 486. For the time being don't worry about that too much. Export a few tests from the 3D app and try things out.

To get the stills into Vegas, first set up your project. Since your images are 486 tall try using the NTSC IMX Widescreen template.

Next, open the file menu and select Import / Media. Browse to the folder with the image sequence and select the first image. Then tick the "open still image sequence" checkbox at the bottom of the dialog and confirm that the end of the range you want to import is listed correctly. Finally, click the "Open" button. Your image sequence will be imported as if it's all one clip. No render required.

Now, what I don't know here is whether Vegas Pro 9c will choke on your images. There's a bug in 9.c that might make this happen if you're in an HD project and mixing in AVCHD footage, but since this isn't what you're proposing maybe there's no issue.

Anyway, step one is to get the image sequences into Vegas. After that you can sort out the next steps.

Rob Mack
Soniclight wrote on 4/9/2010, 12:31 AM
upbeatUnique:

Yup, if you can export from your 3D prog (which one, BTW?) .PNG, that's the way to go: solid, non-lossy format. Just requires the extra steps to import it into Vegas.*

As to drive space, while I would have put it a bit more diplomatically, I agree and have had to surrender to the need to just go and buy the new larger drives myself. I recently paid USD $80 or so for a 1TB at Frys and also bought a 1.5TB for nearly the same around Christmas there. OK, so both were on sale--but even so, they're dirt cheap these days.

I remember the days when a 40 Gb cost about the same :)

______________

* Wish List Mini-Rant:
TheHappyFriar wrote on 4/9/2010, 5:03 AM
I'm assuming that res is 16:9 SD. So be sure when you make the project 16:9 or else it will be messed up.

But while everybody is mentioning PNG, I'd also suggest TGA. Both are lossless 32-bit image formats, so you can render out your alpha channel too if needed. A TGA ~that res should be ~1.1mb in side.

2 hours of TGA's should be ~238gb. I'd say at least get a 500gb drive. They're relatively cheap.

another alternative to PNG/TGA is Quicktime PNG. It's the same size as an image sequence of PNG's & has all the advantages plus you handle it as a single file vs an image sequence.
rmack350 wrote on 4/9/2010, 7:55 AM
plus you handle it as a single file vs an image sequence.

Importing the image sequence as I described also makes it behave as a single file (in vegas), and it has the advantage of never getting Quicktime involved. However, I admit to never having done more than import or export a sequence to test that it works. I know the train goes into the tunnel just fine but I've never seen it come out the other end.

Sometimes people go down these roads on a feature length project and find out at the end that it's all too big to render.

I think one big advantage of TGA is that it's a venerable format that a lot of 3D appps probably support.

When you go to DVD you're going to render to a 720x480 file, even if it's wide screen 16:9 (I was also assuming this was what you had in mind). It seems like you've got a couple of resizes and crops to look forward to so I'd run through the whole process on something short and simple before starting to edit. You always want to test things in this business. In addition, you might throw everything onto a timeline randomly and see if it still renders. Just make something huge as a test.

Yes, it'd be nice if you could drag folders of image sequences into Vegas and have it ask if you want an image sequence. If you're outputting a hundred scenes from a 3D app as image sequences I'd think the process of importing them would be pretty tedious.

Rob Mack



farss wrote on 4/9/2010, 8:23 AM
General rule of thumb I hear from those who do CGI for a living is to export at twice the res of the target e.g. scan live action at 2K and do CGI at 4K. Even the free Daz Studio will export 2K Cineon.
Not to say the OP is planning a cinema release of his masterpiece but the same rules should apply scaled down.
One trap one person ran into ages ago with Vegas and animation / CGI was resampling 16 bit images down to 8bit with Vegas. Vegas does not dither so banding can be a problem that night need wrangling.

Bob.
Soniclight wrote on 4/9/2010, 9:06 AM
HappyFriar, you said...

"But while everybody is mentioning PNG, I'd also suggest TGA. Both are lossless 32-bit image formats, so you can render out your alpha channel too if needed."

As far as I know from experience with Particleillusion exports, PNGs also have alpha channel/transparency (I don't have to chromakey my effects in Vegas, they come in ready-to-use), As to TGA, I have seen that format mentioned in conjunction to 3D so it must be more widely used than PNG. That said, I'm relatively new to 3D having only started working with Vue and Daz.

So let me ask this to you and anyone else:

Q: Since both are lossless and seemingly equal in terms of alpha ability, what are the general pros/cons between PNG and TGA?

Later edit/P.S.:

Found this page by a guy at the After Effects forum with some alternate thoughts on the above mentioned and other lossless codecs, incl. a closing comment that PNG can have gamma problems -- though I don't know if this applies to Vegas: Video Codec Advice

There is also Codecs.com and I found this PNG codec there though I don't know anything about it but will give it a try: CorePNG
TheHappyFriar wrote on 4/9/2010, 10:21 AM
Importing the image sequence as I described also makes it behave as a single file (in vegas), and it has the advantage of never getting Quicktime involved.

I agree on the QT, but there are some advantes to the single file vs multiple:
*one file in a folder vs hundreds/thousands/hundreds of thousands
*Imports in to Vegas faster (you click on the file & then hit "import" or you drag/drop. With image sequences Vegas needs to look @ ALL the images first so it can give you a starting & ending #)
*possibly takes up less HD space (because of cluster sizes. 1 file rounded up to 4k cluster or 50,000. Simple math.)

Advantages of image sequences:
*you can start/stop rendering @ any time w/o losing anything rendered prior.
*you can easily replace a bed section by rendering over it.
*standard output by almost every 3D app & NLE

What I'll do some times is I'll render from my 3D app to PNG/TGA & then use Vegas to render a single AVI (some loss less format) or QT PNG.

When you go to DVD you're going to render to a 720x480 file, even if it's wide screen 16:9

Most 3D apps don't support PAR so you need to render everything as a 1.0 PAR. That increases the width. If you don't it will look funny (yeah, you can render to 720x480 & then bring in to Vegas & change the event's PAR to 1.0 but I've gotten better results with more pixels). But if you can change the PAR that's an easier idea (unless you can't figure out what PAR you need!)

Q: Since both are lossless and seemingly equal in terms of alpha ability, what are the general pros/cons between PNG and TGA?

TGA is an older format. It's the "mpeg-1" of stills: anything, and really ANYTHING can read & display TGA's: DOS, Mac, Windows, Linux. Newer portable devices can't but that's because it's assumed you won't use the format. PNG is newer & has the same quality but a small file size. I've never seen a quality difference between TGA & PNG. I tell all my programs to not override anything though. Vegas doesn't override anything in a PNG that I'm aware of, from him saying he's posting in the AE forum that Adobe products do, and that causes issues. Remember, Adobe makes apps for several OS's & each OS can handle things slightly different. Vegas only works on one OS.
rmack350 wrote on 4/9/2010, 10:27 AM
One trap one person ran into ages ago with Vegas and animation / CGI was resampling 16 bit images down to 8bit with Vegas. Vegas does not dither so banding can be a problem that night need wrangling.

Definitely another thing to test. There are so many possible roads to go down that you need to have a workflow map before you start.

Vegas has a 32-bit mode. I don't know how that would affect resampling here but I know when the feature was first introduced I found you could write 128-bit AVI files. Again, you'd want to do some testing to see if/where Vegas breaks things.

As far as frame sizes and color bit depth, it's possible that the OP doesn't need to do any sort of color correction or compositing at all, in which case there's no need to output higher rez stills or color over 8-bit.

Codecs-wise, you don't have to work directly with the image sequence. I'm just saying you can. As Soniclight's link explains, there are a number of quicktime codecs that will work. I think in recent threads we've also talked about Lagarith, JPEG2000, DNxHD, Cineform, and MXF.

MXF is an odd one. The spec says that you could wrap just about anything inside it. Vegas offers DV, an IMX format (that might be good for this), and an MPEG2 format for HD. I'd stay far away from the DV and MPEG2 for animation but the IMX variation might be usable. MXF is probably not a first choice but I wanted to touch on it.

If you need 16-bit color then the PNG.mov format is probably a good choice. Spend a little money for Quicktime Pro and use it to convert the image sequences to PNG.mov files.

Also, look around at recent posts about Quicktime. Current versions break things so you need to work with an older version. There are links around here somewhere to places to get one of those installers.

Rob Mack
rmack350 wrote on 4/9/2010, 10:34 AM
The point made in Soniclight's link about network performance and image sequences is a good one.

TGA is also referred to as Targa. Friends using the Video Toaster always referred to it. Very common format.

Rob
Soniclight wrote on 4/10/2010, 1:17 AM
OT Comment: Looks we old timers here ran with this subject but the author of the original opening post never came back. Yet. It also looks like it's that person's first post (just joined a couple of days ago). So...

Mr./Ms. UpbeatUnique, join the discussion at some point :)
upbeatUnique wrote on 4/10/2010, 2:32 PM
I'm here. I've just been side tracked and haven't had the time to post.
Thanks to all for the suggestions. I think I'll try keeping them as image sequences and see if the edit gets bogged down, and if so, I'll look into some of the movie files.
I'm apprehensive about using Quicktime as it now doesn't work in the 64 bit version of XSI and I have seen some posts about it being buggy in Vegas.
I have plenty of hard drive space for the files. I was mostly concerned with having so many files floating around, for organization.
I thought the pixel size for widescreen dvd was 720x486 at 1.2 par (or 864x486), this is the size XSI spits out. Is it just DVD architect that uses 480 or is that the standard for DVD all over?
Thanks again for taking the time to help out. Best to all.

Dan
farss wrote on 4/10/2010, 3:05 PM
Generally when working with intermediates I thinks it's best to keep to a PAR of 1. If your animations are short I'd use uncompressed AVI. It simply works in everything. If those files are too big and strain your disk systems then the Sony YUV codec which is 4:2:2 is probably going to be more than adequate and so far I've not had any issue with it not working in anything, even on a Mac. The nice thing with that codec is it comes in both 8 and 10bit.

Bob.
rmack350 wrote on 4/10/2010, 6:56 PM
As far as the dimensions of an mpeg2 file for DVD goes.I think it's 720x480. MPEG2 needs to have dimensions divisible by 4 (I think).

The 486 dimension comes from older edit systems that would digitize from analog sources. It's a standard size, to be sure, but nearly 6 rows of the image (4 at top and 2 at bottom?) would normally be black. There was often other signal in this space that wasn't particularly visual. You could think of those 6 rows as time between one frame and the next, although that's probably oversimplifying it a bit.

Most programs have scaled their output as a 4:3 ratio or a 16:9 ratio and left it at that, thinking the math was right. It isn't really, and because the SD frame has analog roots there's generally a little more picture side to side beyond that 4:3 aperture.

So, most programs used a kind of rote frame ratio and they all follow the same convention. It's not necessarily mathematically correct but when they all do things the same way it doesn't much matter. Vegas, on the other hand, calculated things correctly in terms of sample rates. They are correct in their SD frame sizes but they don't match the convention. This is why a corrected standard def NTSC still from the Vegas timeline would be 654.5...x480 instead of 640x480.

So anyway how does any of this affect you? If I dropped an 864x486 clip onto an NTSC Widescreen IMX timeline (I'm choosing the imx template because its 486 PX tall, not for any other reason) I'd expect to see a black column at the left and right edges of frame. (This is why you do tests). If you're not seeing it and you're using Vegas 9 then you probably have "Adjust source media to better match project or render settings" ticked in your project settings, in which case your media has been scaled to fill the frame but the top and bottom edges are now cropped out a tiny bit.

What to do? Knowing my final output was a DVD, and knowing about the new "Adjust source..." feature (new to V9) I'd probably set my project to NTSC DV widescreen, tick the "Adjust source.." checkbox, and accept that I'm going to lose a little of the top and bottom edges of the frame. It's easy, it's done, everything works.

If that little loss of the top and bottom was unacceptable then I'd find a tool (like photoshop) to batch process all my frames.

Or consider just setting up a custom template to edit with in Vegas. There is a button in the Vegas project settings dialog that allows you to match the project settings to a media file. In fact, maybe this is really the best solution. Edit in a project that matches your media and then let the MPEG2 renderer scale it all to the right size.

Anybody here have some ideas about field order?

Rob
TheHappyFriar wrote on 4/11/2010, 5:02 AM
since it's a DVD field order doesn't really matter unless you're mixing it with interlaced/progressive footage. IE if you're mixing the digital footage with interlaced camera, you need to match the camera. The 3d app should have an interlace option. If you're just putting 3d content on DVD, you can render progressive, render in Vegas to DV NTSC DVD format & it will burn & the DVD player will deinterlace for you. I've done that DOZENS of times.

As long as everything matches in the same video file the player will "fix" it for you, won't look any worse & will be easier to create/edit. You can mix stuff on the DVD, just not in the came single rendered file.

But I'd render it out @ 873x480 @ 1 PAR for Widescreen & 655x480 @ 1 PAR for 4:3, or a higher ratio of that (the recommendation of 2x the res is a good one, but it could backfire if you have small lines & they start to have flickering during the rescale. Rendering @ the lower res could solve this in the 3d render).
upbeatUnique wrote on 4/11/2010, 7:11 AM
Excellent. Thanks for the info on the file sizes. I had been adjusting the Vegas project to match my output frames. But now I will render to the Vegas project size (873x480).
I have not worked with interlaced frames, all progressive.
I have not tried the 2x res before, but I will probably test it out to see what looks best.
Thanks for the feedback, great forum!