DV to AVI, To do or not to do

Discussion in 'Digital camcorders' started by sumsaris, Sep 30, 2006.

  1. sumsaris

    sumsaris Member

    Joined:
    Dec 1, 2003
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    11
    Alright, after unsuccessfully attempting to attack my problem with the divx/xvid crowd I'm wondering if this forum isn't where I should be looking for answers. In short, my problem is trying to get a decent xvid encode from a DV source (Panasonic GS400) rendered with Pinnacle Studio 9 that will result in a file size 1/3 or less than that of a DVD. Now, I've tried doing it two ways: direct encode and indirect (via the Pinnacle-produced DVD). The latter (the DVD step went fine) produced better quality (less noise, superior color & contrast) but neither gave me anything close to quality under 3000kb/s bitrate with a 4/3 aspect ratio. On all but the most static scenes there would be blocking artifacts in a blue sky for example. On more difficult scenes such as panning from a moving bus the blocks would 'attack' the image like a sliding curtain or an upward flowing waterfall.

    Questions: Is a DV source INHERENTLY more difficult to encode to either a DVD or xvid file compared to the process a commercial film undergoes? In other words if I sent my home movie to Disney would they be able to produce a DVD of the same quality as say, Pirates of the Caribbean? Why or why not? If not, is this why some people can get a 1/4 to 1/6 file size reduction to make backups of their commercial DVDs and myself only 1/2? Is part of the answer connected with the fact that most DVD movies are widescreen? That is, a 1500 mb widescreen file encoded from a 4.7 gb DVD is a lot 'easier' to produce 1500 mb full-screen 4/3 file. The potential compression ratio would seem to be halved. And this inspite of all the denoising, smoothing, quarter pixeling and deshaking make-up masks that people attempt to apply.

    I don't know if this makes any sense. Anyway, if anyone out there has any answers or has actually managed to do an xvid encode from DV that they're happy with I'd certainly appreciate the feedback.
     
  2. TPFKAS

    TPFKAS Regular member

    Joined:
    Jan 1, 2005
    Messages:
    1,011
    Likes Received:
    0
    Trophy Points:
    46
    Hi sumsaris,
    No
    Yes, they will be able to produce a better DVD because:
    1. They use professional encoders based on professional hardware.
    2. They have the knowledge to optimise encoding settings scene by scene if necessary.
    And no, they wil not be able to produce the same level of quality compared to Pirate of the Carribean because they shot it with professional equipment under well controlled lighting conditions.
    No

    First of all don't go first from DV to DVD, just go direct from DV to XviD, if that is what you want. You can simply use VirtualDUB to do that. Secondly, use the best settings that you can find to optimize between size and quality (e,g, VBR two-pass encoding) and apply any filters that attack specific problems that you encoounter.
     
  3. sumsaris

    sumsaris Member

    Joined:
    Dec 1, 2003
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    11
    Yeah, thanks for the answer TPFKAS. Unfortunately, your well-intended answers I sort of anticipated. Also, I looked closer at my source files this weekend, and the blocking artifacts I'm referring to not only could be found on what I'd thought were nearly perfect DVDs they were also noticeable to a very small extent on my source/captured AVIs too. And I'm sure it doesn't take much to amplify such faults in any compression format used down the line.

    So, I suppose my new line of questioning is the following: Has anyone had problems with capturing under Pinnacle Studio 9.4 and/or with Panasonic GS camcorders? My motherboard is a relatively recent Asrock K7VT4A with VIA chipsets. Pinnacle's pre-capture test has always reflected a 20-28 mb transfer capability, so it's as odd as it is disappointing. Thanks for any feedback.
     
  4. TPFKAS

    TPFKAS Regular member

    Joined:
    Jan 1, 2005
    Messages:
    1,011
    Likes Received:
    0
    Trophy Points:
    46
    If you capture in DV-AVI through a Firewire connection, you should see no difference in whatever software you use because it is a real digital data transfer. However, you can run into dropped frames if system is unable to keep up the transfer and writing it to hard disk. My advice, don't use the expensive programs for capturing. They just load more stuff into memory than is needed for the transfer. Go for a simple low CPU consuming program like WinDV. Robust simple and free of charge. When done you can import it into a video editor (like Pinnacle's), and go from there.
     
  5. sumsaris

    sumsaris Member

    Joined:
    Dec 1, 2003
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    11
    I'll give the proggie a shot next time around. Still, doesn't explain my delicate little blue blocks flying around at 28 mb/s sec. Guess I'll just have go resort to a little digital vaseline.
     
  6. TPFKAS

    TPFKAS Regular member

    Joined:
    Jan 1, 2005
    Messages:
    1,011
    Likes Received:
    0
    Trophy Points:
    46
    If they are in your source captured AVI: are you sure they are not already there on tape? You might want to clean the head.
     
  7. sumsaris

    sumsaris Member

    Joined:
    Dec 1, 2003
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    11
    Thanks for your continuing interest TPFKAS. Now after a near all-nighter I've finally got a decent handle on this problem. It's one of dual facets. One has to do with my source material,the other with mechanics of the mpeg4 codecs.

    As for the first, to summarize, the blue sky blocks are glaring in mpg4 (2000kbs avg), slight with mpeg2 (8000kbs), and nearly invisible in the rendered source (28000kbs).The source however, exhibits what I can't describe other than fine but strong noise in the (well-lit)sky that I would not think possible for a 3CCD such as the Panasonic GS400. I may be all wrong here. I know that under low light conditions the camcorder is not brilliantly fast. Not bad, but not good either. It is even inferior to my old Sony TR705 Hi8, the only consumer camcorder ever made IMHO for the hand's of a user rather than a spec sheet. If only they could put the GS400 electronics in that TR705 box and I'd be in seventh heaven. Anyway, that's side issue. So, is the noise reasonable in a camera of this calibre, and could it translate into encoding anomalies in EITHER/OR mpeg4 or mpeg2 formats? This is my central question.

    You suggested a simpler program to capture so as not to 'overload' the system with all the peripherals within the Pinnacle (or Premiere for that) programs. If your theory is correct, this suggests that if Pinnacle is not showing dropped frames, there must be another aspect of the capture process that may be degrading the quality of the input? What? Or possibly, after having edited my DV source in Pinnacle with all the whistles and bells, could having saved to a final DV file (an AVI with the same codec as the source) contributed to a degradation of quality? Pinnacle is notorious for being resource heavy during rendering and I admit my system running on a Sempron 1500 with a mere 750mb ram is not particularly optimized for video editing. Could codec parameters be at play here? Pinnacle's is called 'DV Codec', very imaginative name and hardly helpful. What about Panasonic, Canopus, and others? Similarly, perhaps the mpeg2 codec used by Pinnacle might not be as fine-tuned as others. Has anyone done tests to compare the different DVD codecs out there? Do others allow for more tweaking than the basic Pinnacle window?

    As for the problem of getting my already slightly degraded DV to Divx/Xvid, it seems I'd neglected the crucial difference between average bitrate and point-to-point bitrate. One of my problematic areas was at the very beginning of the 16 min clip where a sound intro of 15 sec fades into the opening minute of a series of relatively static images. Viewing the changing bitrates under ffdshow gives a uniform 22-25kbs for the blackened out portion. Normal you say. But once the image kicks in the bitrate is runs up to a mere 300-400 kbs and by the time it reaches 'cruising speed' we're at best about 1400/kbs. All my test portions had been run in difficult jumpy scenes where the bitrate was showing 3000-3500 kbs nearly wiping out any blocking. And remember, this is a full-screen 4/3 720x576 job. Most people who are successfully doing those, ahem, 'copies' of their widescreen DVDs at 1500kb/s are doing resolutions at 720x280 or less. Meaning, they theoretically only need half the bitrate for the same quality. So, in fact I shouldn't be all that disappointed with fairly decent quality at 3000kbs. In fact the solution is to create zones in xvid that will force the encoder to run at an 400Okbs at specific points to wipeout the worst of those blocks for good. It's more work and will mean a slightly less ideal compression savings, but that's the price I must pay for having a less than topnotch source.

    In short, I've got to figure out if my camcorder or Pinnacle is the source of the quality-control problem. I don't think the brand of the tapes is an issue. Perhaps it's a dirty tapehead question. Doubtful. The tape stems from a time when the camcorder was only months old. Oof, enough said. Appreciate any further feedback. Thanks
     
  8. TPFKAS

    TPFKAS Regular member

    Joined:
    Jan 1, 2005
    Messages:
    1,011
    Likes Received:
    0
    Trophy Points:
    46
    Long story and I am not sure if I the info below will help you, but let's go.

    About 3CCD camcorders: they inherently have more problems with low light conditions. The reason for that is that the light is split into the three primary colors by a prism. The prism will lead to some loss of luminance.

    About DV codecs: even if they all are compliant with the standard (or at least they should be) there are quality differences between them. Personally I have never investigated it and I always use the native Microsoft DV-codec, built into Windows and am satisfied with it. The only time I use another DV codec is when I need use applications that rely on VFW compatible codecs. I hate programs that are shipped with their own codec...and I must say that I am personally not a Pinnacle fan, because I have heard too many people complain about unstability of their software. Anyway, be sure to always use the same codec with which the video was compressed to also play the video. This is already a good reason not to allow "third party" codecs on your machine. Also make sure that you don't recompress your footage when you export it from the timeline of a video editor. Always use "smart rendering" i.e. all untouched frames will not be rendered again during export but simply directly copied from the original.
    Here are a couple of interesting links:
    http://forum.doom9.org/showthread.php?s=&threadid=58110
    http://people.csail.mit.edu/tbuehler/video/codecs/avi.html#dv

    About encoding to mpeg-2: don't trust the built-in encoders in video editing programs. Their capabilities are usually quite limited. Export your footage as DV-AVI and encode it with a decent stand alone one (e.g Canopus, Mainconcept or TMPGEnc). And use a high bitrate (say 8000kb/s) and if you have to use a lower bitrate for file size reasons use a 2-pass variable bitrate process. The same goes for encoding to DivX/XViD.

    If you use low bitrate you are certain to encounter "blockiness". This gets very evident in areas with very subtile color or texture differences. Do a test by filming running water and encode that with a low bitrate. You'll see what I mean. To prevent that, sophisticated encoders offer all types of extra filters to smooth the image. The blockiness will go away, but you will get some blur in return.

    Hope this helps.
     
    Last edited: Oct 5, 2006
  9. sumsaris

    sumsaris Member

    Joined:
    Dec 1, 2003
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    11
    Your comments re/ 3CCD seem to confirm the possible noise problem in the GS400. As I don't have any of the initial capture DV files (only the processed AVIs which were used for the DVD burns and, now, for the Xvid conversion I have no way of knowing if a codec issue interfered in all this.

    Your first link was quite interesting, if only pulling me deeper into the maelstrom of color spaces and such. Even the participant 'experts' seemed to be groping for answers now and then. At least there is agreement that all DV encoders are not alike. As for mine, I still am not sure what Pinnacle is using when it renders my final project. According to G-Sport it seems to be the system furnished Microsoft one. Yet according Avicodec, it's identified as Sony Digital Video??! And why isn't the Pinnacle home-brew the default codec? When you speak of 'smart-render' I presume you refer to that Pinnacle Studio button on the make-AVI page that reads "same as project". Otherwise, I'm in the dark as to where such a function might be. I've only tried once to make a DVD at less than 90% quality. At 60% and 4500kbs you're starting to push it and indeed pick up the artifacts. Curious, you brought up water as a test to push the limits of the encoder. Its monochrome texture seems to compare itself to fog or for that matter an my bright blue skies.

    The Doom link showed me how little I know about colour spaces and their conversions. On that subject, what I do know is that DV and Mpeg2 use the yuv12 space. Also that VirtualDub converts anything to RGB 24 or 32. A simple look in the filestats with ffdshow confirm this. What I don't get is why divx or xvid files apparently show up as yuv2? I thought with Pal it was just one of the two former that came into play. Time to open Video Primer for the Unnerded again.

    As an offchance possibilty, would the use of a third party wide-lens on the camcorder deteriorate capture/encoding quality or am I looking to hard now. Mine is quite decent, and I use almost exclusively.

    Thanks for input TFDSK, every bit helps.
     
  10. TPFKAS

    TPFKAS Regular member

    Joined:
    Jan 1, 2005
    Messages:
    1,011
    Likes Received:
    0
    Trophy Points:
    46
    OK. About DV codecs. If you have more DV codecs are installed on your system you are never sure what happens during playback and during rendering. I never used AVIcodec, but I prefer Gspot. It displays the FourCC code of the codec and also indicates which codecs installed on your system is able to process the video. As I said earlier I think that it is best to just have on DV codec on your system so that you are sure that this codec is ths only one that is used both for playing and rendering. I would just remove the Pinnacle codec and see if Studio still works OK.

    About Smart Rendering. I am not sure where to find a setting in Studio where you can change it, but probably Studio does that by default. I know that the term Smart Rendering has been used in the past by Pinnacle (at least it was 10 years ago when I used Studio myself) so if you check out the manual or their website you should be able to find something about it.

    But, to be honest, we´re realy looking at the far edges of quality detoriation here. If your source is decent quality and you use a decent encoder, you should not see any artifacts on a normal TV. I don´t think your lens has to do anything with it.
     

Share This Page