VideoHelp Forum




+ Reply to Thread
Results 1 to 7 of 7
  1. I am using Avisynth/VirtualDubMod. I am trying to simply deinterlace a video with QTGMC, but I'm having a problem with getting an occasional glitch. The glitch is 1-2 frames are tinted green. Code and x264vfw are below.

    Code:
    setmemorymax(1024)
    setmtmode(3,8)
    avisource("video.avi")
    setmtmode(2)
    ConvertToYV12(interlaced=true)
    AssumeTFF()
    QTGMC(preset="slower")
    Crop(0,0,-12,-8).AddBorders(6,4,6,4)
    Distributor()
    return last
    Image Attached Thumbnails Click image for larger version

Name:	x264vfw.JPG
Views:	531
Size:	80.7 KB
ID:	33016  

    Quote Quote  
  2. Here is an example of what the glitch looks like. It is usually green but can occasionally be red also.
    Image Attached Thumbnails Click image for larger version

Name:	Glitch.JPG
Views:	328
Size:	113.5 KB
ID:	33018  

    Quote Quote  
  3. Member
    Join Date
    May 2014
    Location
    Memphis TN, US
    Search PM
    Difficult to say. All I can see here is that you're deinterlacing "a video". What format of video?

    Why are you deinterlacing?

    Why is your sample image 1327x887 (1.496:1) ? Is this PAL? Did you upscale the original to that size? If you're working with YUV color, you can't crop or resize using odd numbered dimensions or you'll screw up the colors, along with a lot of other things.

    Are you sure you need Distributor()?

    Do you have the correct and updated versions of RemoveGrain, Masktools, etc., for Avisynth MT?

    Other questions occurred, but these will do for a start I guess.
    - My sister Ann's brother
    Quote Quote  
  4. What are the source AVI dimensions ?



    You shouldn't need distributor in vdub . Some applications work faster with it when using MT (e.g. ffmpeg), but you actually get slower results in vdub



    Is the error repeatable ? Do the glitches appear always in the same frame? e.g. if you preview the script in vdub (not the encoded result), are the same frames always affected ?



    You have to systematically debug it, work step by step

    Is it a decoding/playback issue of the output? Try another decoder/player (ie. is error real?)

    Is it x264vfw's fault? Unlikely. Try encoding with another codec eg. lagarith or ut video codec => do glitches occur ?

    Try encoding in non MT mode => do errors occur ?

    Start removing filters one by one , check the output

    Is it a source decoding error?

    Also check hardware stability / Ram issues. If overclocked, go back to defaults
    Quote Quote  
  5. Originally Posted by LMotlow View Post
    Difficult to say. All I can see here is that you're deinterlacing "a video". What format of video?

    Why are you deinterlacing?

    Why is your sample image 1327x887 (1.496:1) ? Is this PAL? Did you upscale the original to that size? If you're working with YUV color, you can't crop or resize using odd numbered dimensions or you'll screw up the colors, along with a lot of other things.

    Are you sure you need Distributor()?

    Do you have the correct and updated versions of RemoveGrain, Masktools, etc., for Avisynth MT?

    Other questions occurred, but these will do for a start I guess.
    The video is HuffYUV. I'm deinterlacing because I want to view it on a computer and upload to YouTube. The video is 720x480, the sample was just stretched in VLC when I took a screenshot. I'm not sure about needing Distributor(), but if I leave setmtmode how it is and remove Distributor() it will process exremely slowly.

    I believe I have the correct and updated versions of the plugins you listed. I used that same code (with the addition of MCTD) and plugins before to edit a video and had no problems. The only difference is I had the x264vfw ratefacter at 5 previously, but I don't want such a large filesize for the current video.
    Quote Quote  
  6. Originally Posted by poisondeathray View Post
    What are the source AVI dimensions ?



    You shouldn't need distributor in vdub . Some applications work faster with it when using MT (e.g. ffmpeg), but you actually get slower results in vdub



    Is the error repeatable ? Do the glitches appear always in the same frame? e.g. if you preview the script in vdub (not the encoded result), are the same frames always affected ?



    You have to systematically debug it, work step by step

    Is it a decoding/playback issue of the output? Try another decoder/player (ie. is error real?)

    Is it x264vfw's fault? Unlikely. Try encoding with another codec eg. lagarith or ut video codec => do glitches occur ?

    Try encoding in non MT mode => do errors occur ?

    Start removing filters one by one , check the output

    Is it a source decoding error?

    Also check hardware stability / Ram issues. If overclocked, go back to defaults
    The source dimensions are 720x480. If I remove distributor and leave everything else the same, it processes extremely slowly. The glitches do not appear to happen at the same time every time. I tried playing the video in both VLC and WMP and both have the glitch. I did try another encoder (xvid) and vdub crashed.

    I also tried in non MT mode and it does appear to work fine. I may just have to go with non MT mode, but I'm just surprised it's not working since I previously used the same code with the addition of MCTD (although x264vfw ratefactor was 5) and had no problems.
    Quote Quote  
  7. There was some talk of avstp.dll not playing nice with MT Avisynth in a thread at doom9 recently. http://forum.doom9.org/showthread.php?t=153589&page=47
    Different artefacts, and it could be completely unrelated, but if you have avstp.dll auto-loading in your Avisynth plugins folder, removing it might be something to try if all else fails.

    Or maybe don't use the vfw version of the x264 encoder to see if that makes a difference. If you're not using any VirtualDub filtering you could load the script into a GUI capable of opening scripts and using the command line encoder. MeGUI comes to mind. By default, it uses it's own portable version of Avisynth+, and I don't know how stable it is when it comes to multithreading, but you can uncheck the option in MeGUI's settings labelled "always use the included Avisynth" and after restarting MeGUI it'll use any installed version. From there it's just a matter of loading the script into the video section, configuring the encoder (although you appear to be using the defaults with Tune grain and CRF25, so that should be easy), adding the job to the queue and running it.

    It's always possible it's a decoding issue, in which case you might want to try something other than Avisource. Maybe give L-Smash a shot. It'd look something like:

    LoadPlugin("C:\Program Files\lsmash\LSMASHSource.dll")
    LWLibavVideoSource("video.avi")
    Quote Quote  



Similar Threads

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