VideoHelp Forum




+ Reply to Thread
Results 1 to 7 of 7
  1. I have files from mini DV tapes that I want to de-interlace with AviSynth's yadif plugin, then de-shake with VirtualDub. They play fine in players, and when I drag them onto VirtualDub, VirtualDubMod, and NanDub. But the chroma is wrong when I drag a simple AviSynth script onto VirtualDubMod.

    AviSource("sampleDirectStreamCopy.avi")

    produces this:
    Click image for larger version

Name:	weddingColorBad.png
Views:	519
Size:	551.0 KB
ID:	1436


    Adding
    ConvertToYUY2(), or including interlaced=true doesn't help. I've tried separate attempts using ConvertToRGB(), TopFieldFirst, BottomFieldFirst, ComplementParity, and AssumeFieldBased.

    I saw this post about chroma channels being applied to the wrong fields of the luma channel, but I'm not cropping. This happens to the original files. I also converted the files from DV Type I to Type II, but that didn't change anything.

    info() says it is YV12, 720x480 at 29.9700
    FieldBased (Separated) Video: NO
    Parity: Bottom Field First

    However GSpot 2.60 thinks it's interlaced and the TFF icon is lit, which I believe means top field first.

    Here is a second of the video including the first frame.

    I have come up with a workaround but the file sizes are nuts. It will work if I re-save the video as uncompressed, or with Huffyuv and open that in a script which includes ConvertToYUY2(). But the uncompressed file size is 870% larger. Huffyuv is 625%. Huffyuv includes the lossy option to convert to YUY2 and then it's 300% larger. But I want to de-interlace and de-shake before sacrificing any color if I can help it. Any ideas on scripts and combinations I didn't try?
    Quote Quote  
  2. your sample works fine for me without your issues in avisynth, by opening the .avs in vdub or avsp

    what decoder are you using?

    I'm using cedocida for the vfw decoder (which is invoked when AVISource() is used). Directshow players use a directshow decoder which is different (invoked when DirectShowSource() is used)
    Quote Quote  
  3. Force your DV decoder to output YUY2. That will avoid interlaced YV12 problems.

    I didn't see anything unusual in the clip you posted (I opened the video in VirtualDub with ffdshow decoding the DV). But you should post a sample with much more motion of colored objects. The sample was interlaced, bottom field first.

    Your sample image is displaying some other type of problem. Colors are being applied in the wrong places:

    Click image for larger version

Name:	mod2.png
Views:	463
Size:	1,021.8 KB
ID:	1439

    Here's your sample Yadif deinterlaced in VirtualDub (Xvid AVI):
    Image Attached Files
    Last edited by jagabo; 21st Apr 2010 at 10:01.
    Quote Quote  
  4. FIRST it works now! Thanks so much! I did

    loadcplugin("C:\AV\AviSynth 2.5\plugins\yadif.dll")
    DirectShowSource("sampleDirectStreamCopy.avi")
    ConvertToYUY2()
    Yadif()

    How do I find out what decoder is being used by AviSynth? It looks like I installed cedocida in the past and forgot about it, but it shows up in the virtualdubmod compression options.

    Are there downsides to using DirectShowSource in speed, accuracy, or integrity?

    jagabo, I'll post a messed-up clip in several minutes.
    Quote Quote  
  5. Here's five seconds of it with more motion and saved with Xvid single pass quantization 1.97. The script is:

    loadcplugin("C:\AV\AviSynth 2.5\plugins\yadif.dll")
    AviSource("sampleWithMotion.avi")
    ConvertToYUY2()
    Yadif()
    Image Attached Files
    Quote Quote  
  6. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by Neimo View Post
    loadcplugin("C:\AV\AviSynth 2.5\plugins\yadif.dll")
    AviSource("sampleWithMotion.avi")
    ConvertToYUY2()
    Yadif()
    You need to use ConvertToYUY2(interlaced=true)
    Quote Quote  
  7. So DirectShowSource() is giving you proper colors and AviSource() is giving the bad colors seen in the Xvid AVI? The difference is which DV decoder is being used. DirectShowSource() will use a DirectShow DV decoder. AviSource() will use a VFW decoder. So this would indicate there is something wrong with the VFW DV decoder you have installed. Get rid of it and try using Cedocida instead. Cedocida usually puts out YUY2 from NTSC DV sources so you won't need the ConvertToYUY2() or ConvertToYuy2(interlaced=true).

    The nature of your color errors in your samples is not what you would see from ConvertToYUY2() with the wrong interlaced argument. Interlaced chroma errors are usually much more subtle.

    Attached is your Xvid AVI fixed with the following script:
    src=AVISource("sampleWithMotionBadColorXvidQuantiz ation2.avi")
    U=UtoY(src).Crop(0,0,180,-0).BilinearResize(360,240)
    V=VtoY(src).Crop(0,0,180,-0).BilinearResize(360,240)
    YtoUV(U,V,src)
    Tweak(sat=1.3)
    This is not a fix for your real problem though.
    Image Attached Files
    Last edited by jagabo; 21st Apr 2010 at 19:51.
    Quote Quote  



Similar Threads

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