VideoHelp Forum




+ Reply to Thread
Results 1 to 16 of 16
  1. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    I notice that when using the resize filter to set a 4:3 image inside a 16:9 image with pillarboxing, there's an issue with the right side of the image. The color is missing from the part right up against the border.

    Anyone familiar with this and how it can be cured?

    Thanks.

    Click image for larger version

Name:	edge issue.jpg
Views:	301
Size:	125.5 KB
ID:	15090
    Quote Quote  
  2. Was the chroma shifted earlier in the process, as is often done with VHS caps?
    Quote Quote  
  3. Use mod4 (or larger) frame sizes.
    Quote Quote  
  4. Banned
    Join Date
    Oct 2004
    Location
    New York, US
    Search Comp PM
    Why not do this in Avisynth? If you want 160-pixel borders at each side:
    AddBorders(160,0,160,0)
    The default border color in Avisynth is RGB 000 (black).

    jagabo is correct, in YUV your frame dimension should be at least mod-4 (dimension is evenly divisible by 4) for better colorspace conversions. There are some plugins that require mod-8 dimensions in processing, usually noted in the plugin's documenation. You're likely going thru at least one YUV colorspace step anyway, just to get your capture into VirtualDub to begin with, because your capture is either YV12 (4:2:0) or YUY2 (4:2:2) and you're using QTGMC. So to properly move your Avisynth processing for work in VirtualDub:

    Code:
    AddBorders(160,0,160,0)
    ConvertToRGB32(matrix="rec601",interlaced=true) 
    # <- or interlaced=false, whichever applies)
    Also, you might consider using the Rec709 HD matrix if you're going HD. There's not that much difference, it's mostly in saturation levels. Opening a YUV video directly in VirtualDub without specifying the conversion will use Vdub's rec601 matrix by default.
    Last edited by sanlyn; 24th Mar 2014 at 12:18.
    Quote Quote  
  5. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by jagabo View Post
    Use mod4 (or larger) frame sizes.
    Translation?
    Quote Quote  
  6. Banned
    Join Date
    Oct 2004
    Location
    New York, US
    Search Comp PM
    Originally Posted by brassplyer View Post
    Originally Posted by jagabo View Post
    Use mod4 (or larger) frame sizes.
    Translation?
    You have the answer 2 posts earlier:

    Originally Posted by sanlyn View Post
    ...frame dimension should be at least mod-4 (dimension is evenly divisible by 4)...
    The number 640 is evenly divisible by 4 -> : 640 / 4 = 160
    The number 790 is not evenly divisible by 4 (decimal remaining) -> : 790 / 4 = 197.5
    Last edited by sanlyn; 24th Mar 2014 at 12:18.
    Quote Quote  
  7. Keep at least mod4 sizes at every operation (crop, resize, addborders).

    And of course, make sure it wasn't in your source or caused by any other filtering you did.
    Quote Quote  
  8. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by manono View Post
    Was the chroma shifted earlier in the process, as is often done with VHS caps?
    Not earlier in the chain but after - the chroma shift appears to be what's causing it. It appears every other frame.

    It doesn't appear I can just crop it out either, when I crop that edge, the problem area just moves over.
    Quote Quote  
  9. Originally Posted by brassplyer View Post
    Originally Posted by manono View Post
    Was the chroma shifted earlier in the process, as is often done with VHS caps?
    Not earlier in the chain but after - the chroma shift appears to be what's causing it. It appears every other frame.
    Well then of course you're getting the discoloration. You're shifting gray chroma from the black borders onto the picture. Perform the chroma shift before adding the borders.
    Quote Quote  
  10. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by jagabo View Post
    Originally Posted by brassplyer View Post
    Originally Posted by manono View Post
    Was the chroma shifted earlier in the process, as is often done with VHS caps?
    Not earlier in the chain but after - the chroma shift appears to be what's causing it. It appears every other frame.
    Well then of course you're getting the discoloration. You're shifting gray chroma from the black borders onto the picture. Perform the chroma shift before adding the borders.
    Isn't chroma the color component? I think it's more that the color is being shifted to the left exposing the luma but yeah.
    Quote Quote  
  11. If you shift "black" chroma over onto the color picture you will be left with a greyscale picture.
    Quote Quote  
  12. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by jagabo View Post
    If you shift "black" chroma over onto the color picture you will be left with a greyscale picture.
    The filter addresses chroma I and Q, which is the black chroma?
    Quote Quote  
  13. Both I and Q from the black borders will both have "gray" chroma values (128). When you perform a chroma shift you are moving the colors (to the left in this case) but leaving the luma (greyscale) picture in place.
    Last edited by jagabo; 10th Dec 2012 at 20:50.
    Quote Quote  
  14. Banned
    Join Date
    Oct 2004
    Location
    New York, US
    Search Comp PM
    I keep looking at the image in post #1. Why did it "gray-out" only a portion of the lower part of the right border, but had far less effect on other parts of the same border?
    Last edited by sanlyn; 24th Mar 2014 at 12:18.
    Quote Quote  
  15. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by sanlyn View Post
    I keep looking at the image in post #1. Why did it "gray-out" only a portion of the lower part of the right border, but had far less effect on other parts of the same border?
    Dunno. If I kill the chroma shift filter the issue goes away. I may just live with it without the filter since the chroma issue isn't terrible particularly with the color noise filter that's also in the chain. And I think I may not even be accurately identifying the issue, maybe not shift so much as bleed.
    Quote Quote  
  16. Banned
    Join Date
    Oct 2004
    Location
    New York, US
    Search Comp PM
    I had a similar problem -- not with a chroma shift filter, but with a strong anti-rainbow plugin used on 20 pixels of discoloration along a border. Different story, but if you refer to FlaXen's VirtualDub VHS filter, make sure the chroma denoising switches are turned off. I find the "VHS" shifter to be an OK finishing touch for very small 1 or 2 pixel shifts, but stronger shift/bleeding is more effectively handled in YUV.

    Chroma shift:
    - Try the ChromaShift() plugin: http://avisynth.org.ru/docs/english/externalfilters/chromashift.htm

    Bleeding, and some chroma shift as well:
    - Try a light dose (or two) of this popular technique: mergechroma(aWarpSharp(depth=20.0, thresh=0.75, blurlevel=1, cm=1)). Tweak "depth" and "blurlevel" for stronger effect, but don't go insane with the numbers, Often works best by running it 2 times in a row with the lower values shown. For stronger de-coloring try depth up to 30 or blurlevel up to 3.

    There's no total fix for chroma bleed or shift. The cleanest technique is a few rather gentle filter passes instead of a sledgehammer.
    Last edited by sanlyn; 24th Mar 2014 at 12:19.
    Quote Quote  



Similar Threads

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