VideoHelp Forum
+ Reply to Thread
Results 1 to 8 of 8
Thread
  1. I cropped 2 from the left, and 4 from the right, then added black borders to fill in what was cropped off.

    I cant crop and addborders of 3 on both sides due to limitations. I know how to shift chroma around, but I have never done the luma and or the rest of the image with it.

    How can I shift the entire image to the right 1 pixel, so its 3 pixels wide black borders on both sides?
    Quote Quote  
  2. One way is to convert to 4:4:4 to bypass the chroma subsampling restrictions then crop and addborders of 3

    For 8bit 444 it would be ConvertToYV24()
    Quote Quote  
  3. Code:
    Overlay(last, last, x=1, y=0)
    Code:
    PointResize(720,480, -1,0,720,480)
    Quote Quote  
  4. Originally Posted by jagabo View Post
    Code:
    Overlay(last, last, x=1, y=0)
    Code:
    PointResize(720,480, -1,0,720,480)

    Do I use both of those in the same script or is it just 2 different ways of doing it?


    EDIT:
    The top one seems to work fine. So far this looks like just what I need. Thanks a lot!

    The bottom one works as well but it seems to mess with chroma. It doesnt look like a full image shift while keeping everything in place. Kind of resembles chroma sharpening with awarpsharp2 after it has been shifted over or chroma shifting. I notice colors along edges in slightly different areas. I assume this is because it's a 1 pixel shift. It seems a lot less obvious or not happening at all when doing by an even number.
    Last edited by killerteengohan; 29th Apr 2023 at 02:16.
    Quote Quote  
  5. Video Damager VoodooFX's Avatar
    Join Date
    Oct 2021
    Location
    At Doom9
    Search PM
    Originally Posted by killerteengohan View Post
    The bottom one works as well but it seems to mess with chroma.
    Try:
    Code:
    Spline64Resize(720, 480, -1, 0, 720, 480)
    Quote Quote  
  6. Originally Posted by killerteengohan View Post
    The bottom one works as well but it seems to mess with chroma. It doesnt look like a full image shift while keeping everything in place. Kind of resembles chroma sharpening with awarpsharp2 after it has been shifted over or chroma shifting. I notice colors along edges in slightly different areas. I assume this is because it's a 1 pixel shift. It seems a lot less obvious or not happening at all when doing by an even number.
    All resizing methods will mess with subsampled chroma when shifting by an odd number of pixels. Because to shift the luma by 1 pixel requires the chroma be shifted by half a pixel. Shifting by half a pixel requires some sort of re-sampling.

    The given PointResize ends up shifting the chroma by one pixel instead of half a pixel (because 1/2 rounds up to 1). You can keep the chroma where it is with MergeChroma(PointResize(720,480, -1,0,720,480), last) (which is equivalent to what the Overlay method does). But that just means the chroma is shifted left by half a pixel rather than right by half a pixel (relative to the luma). Other resizing methods will apply their resizing method to the chroma when shifting by half a pixel. So BilinearResize will blur the chroma a bit, Spline64Resize will sharpen it a bit.
    Quote Quote  
  7. Originally Posted by jagabo View Post
    Originally Posted by killerteengohan View Post
    The bottom one works as well but it seems to mess with chroma. It doesnt look like a full image shift while keeping everything in place. Kind of resembles chroma sharpening with awarpsharp2 after it has been shifted over or chroma shifting. I notice colors along edges in slightly different areas. I assume this is because it's a 1 pixel shift. It seems a lot less obvious or not happening at all when doing by an even number.
    All resizing methods will mess with subsampled chroma when shifting by an odd number of pixels. Because to shift the luma by 1 pixel requires the chroma be shifted by half a pixel. Shifting by half a pixel requires some sort of re-sampling.

    The given PointResize ends up shifting the chroma by one pixel instead of half a pixel (because 1/2 rounds up to 1). You can keep the chroma where it is with MergeChroma(PointResize(720,480, -1,0,720,480), last) (which is equivalent to what the Overlay method does). But that just means the chroma is shifted left by half a pixel rather than right by half a pixel (relative to the luma). Other resizing methods will apply their resizing method to the chroma when shifting by half a pixel. So BilinearResize will blur the chroma a bit, Spline64Resize will sharpen it a bit.
    That first one works fine so I'm not too worried about the second bottom method. If I wanted to use that second method I could always just take the chroma from before using that second one and then shift it with chroma shift to fix the chroma like this I would think.

    Code:
    source = last
    PointResize(720,480, -1,0,720,480)
    MergeChroma(last, source)
    ChromaShiftSP(x=-1.00, y=0.00)
    Anyways, the first one did exactly what I needed and I thank you for showing me it.
    Quote Quote  
  8. You should decide which method to use depending on the source. For example, if the chroma is a little blurry, using a resizer that sharpens it may look better.
    Quote Quote  



Similar Threads

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