VideoHelp Forum




+ Reply to Thread
Results 1 to 13 of 13
  1. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    I'm doing some filtering of a DV-AVI video (720x480) with AVISynth through VDub and I'm compressing back to DV using the Cedocida codec in Fast Recompress Mode. After loading the script into VDub and encoding the output video looks slightly compressed horizontally. When I run the AVISynth script everthing looks good so I don't think doing a LanczosResize(720,480) in the script would make any difference. There's no aspect ratio setting for the Cedocida codec either. I'm lost. Does anyone have any idea what might be causing the distortion?
    Quote Quote  
  2. VirtualDub displays video as square pixel by default. That means a 720x480 source will be displayed as 720:480, or 3:2. This is done so that each pixel in the video is displayed as one pixel on your computer monitor. You see the exact pixels on your monitor, not some scaled representation. If your source has a 16:9 DAR, the video will look squished horizontally. If it has a 4:3 DAR it will look stretched horizontally.

    If you want to see the image with the correct DAR in VirtualDub just right click on the frame and select the DAR you want.

    AVI doesn't really support display aspect ratios. So the DAR information needs to saved within the compressed video data. Some codecs support internal DAR flags (MPEG4, DV, etc.) and some don't (HuffYUV, Lagarith, etc.). Unfortunately, Cedocida doesn't have any way of specifying the DAR. All Cedocida's encodes are flagged as 4:3.

    This generally isn't a problem. Most editing/authoring software will allow you to override the source DAR. So even if the software detects the file as 4:3 DAR you can tell it to treat it as 16:9 DAR instead.
    Quote Quote  
  3. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    What's confusing me is that when I view the video through AVISynth it looks fine, but when I view the video directly (in WMP too, not just VDub) is looks distored. Does AVISynth assume 16:9 and pass something to the player that indicates as much?
    Quote Quote  
  4. Member gadgetguy's Avatar
    Join Date
    Feb 2002
    Location
    West Mitten, USA
    Search Comp PM
    Originally Posted by sd_smoker
    What's confusing me is that when I view the video through AVISynth it looks fine, but when I view the video directly (in WMP too, not just VDub) is looks distored. Does AVISynth assume 16:9 and pass something to the player that indicates as much?
    View through AviSynth?
    "Shut up Wesley!" -- Captain Jean-Luc Picard
    Buy My Books
    Quote Quote  
  5. AviSynth strips away all DAR information. Any program receiving anything through AviSynth has no idea what the DAR is. They will usually assume square pixel.
    Quote Quote  
  6. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    If you want to play the avisynth file in the correct AR, try Media Player Classic. It usually gets it right.

    If you want to see it with the correct AR in Virtualdub, right-click on the preview screen and select the AR you want to view it with.
    Read my blog here.
    Quote Quote  
  7. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    Originally Posted by gadgetguy
    View through AviSynth?
    Sorry, could have been more clear. When I load an AVISynth script with only the line 'AVISouce("file.avi")' into a player everything looks fine. When I open the video directly in the player the aspect ration is off.
    Quote Quote  
  8. Originally Posted by sd_smoker
    When I load an AVISynth script with only the line 'AVISouce("file.avi")' into a player everything looks fine. When I open the video directly in the player the aspect ration is off.
    Then the video has DAR flags and the player is adjusting the AR to suit. AviSynth strips away the DAR flags so the player sees the video as square pixel.
    Quote Quote  
  9. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    Okay, that makes sense. Is there a way to set the proper DAR flags in either AVISynth or VDub?
    Quote Quote  
  10. AviSynth has no knowledge of DAR flags. In VirtualDub you select the DAR when you encode using the compression codec's configuration dialogs.

    If you have an MPEG4 (Divx/Xvid) video you can use MPEG4Modifier to set the DAR flags without reencoding.
    Quote Quote  
  11. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    That was it, thanks. When I applied the AVISynth filters I just re-encoded to DV using Cedocida (which does have DAR flags) and the encoded to DivX without specifying 16:9 NTSC and it apparently defaulted to something else.

    BTW, Mpeg4Modifier is a very cool little program!
    Quote Quote  
  12. Member
    Join Date
    Mar 2007
    Location
    United States
    Search Comp PM
    One more question. I didn't see a place to specify DAR for the Xvid codec. How would I do that? I still haven't decided between DivX and Xvid so I'm experimenting with both...
    Quote Quote  
  13. For XviD in Vdub,

    hit video=>compression=>Xvid=>configure, => "more" button beside the profile level => aspect ratio tab => display aspect ratio

    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!