VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Results 1 to 8 of 8
Thread
  1. Usually I'm always cropping off even numbers from all 4 sides if they ever need it to get rid of black bars. Even the programs I use auto select multiple of 2.

    Would it hurt anything if I cropped 21 off the top and 21 off the bottom as long as the total of the top and bottom is an even number? in this case 42?

    It wont let me crop by an odd number. Says YUV image can only be cropped by mod 2.
    Quote Quote  
  2. If source is YV12 4:2:0, you can't crop by odd numbers by normal methods

    You can get around that and crop by odd values by using the internal crop resizer by specifying src_left, src_top, src_width, src_height

    http://avisynth.nl/index.php/Resize

    eg. lets say source is 1920x1080, and you want to crop 21 off top, and bottom each

    spline36resize(last.width, last.height-42, src_top=21, src_height=-21)
    Quote Quote  
  3. Member
    Join Date
    Sep 2012
    Location
    Australia
    Search Comp PM
    Are you resizing afterwards?

    YV12 chroma samples are 2x2 luma samples in size, it's the chroma that needs to be cropped to even numbers (relative to luma), there's no way around that short of switching to yv24 or RGB.
    Quote Quote  
  4. Originally Posted by ndjamena View Post
    Are you resizing afterwards?

    YV12 chroma samples are 2x2 luma samples in size, it's the chroma that needs to be cropped to even numbers (relative to luma), there's no way around that short of switching to yv24 or RGB.
    You can use the avisynth internal crop resizer and stay in YV12 . Quality is worse if you convert to yv24 (and especially RGB), because you have control over separate dimensions when you use the crop resizer

    e.g. see this thread , post #4
    https://forum.videohelp.com/threads/368265-ConvertToYV24-Pros-and-Cons
    Quote Quote  
  5. Originally Posted by poisondeathray View Post
    eg. lets say source is 1920x1080, and you want to crop 21 off top, and bottom each

    spline36resize(last.width, last.height-42, src_top=21, src_height=-21)
    Note that this will blur the chroma channels a little bit. I'd recommend agaist it if not absolutely necessary.
    Quote Quote  
  6. Originally Posted by jagabo View Post
    Originally Posted by poisondeathray View Post
    eg. lets say source is 1920x1080, and you want to crop 21 off top, and bottom each

    spline36resize(last.width, last.height-42, src_top=21, src_height=-21)
    Note that this will blur the chroma channels a little bit. I'd recommend agaist it if not absolutely necessary.


    For sure, it's always better to crop by 2 in YV12 .
    Last edited by poisondeathray; 13th Nov 2014 at 19:32.
    Quote Quote  
  7. Thanks, I just ended up cropping 22 from the top and bottom and taking 2 off left and right to keep the image from stretching up and down. Its better than blurring or going through conversion hassles.
    Quote Quote  
  8. I have a similar question but more with regards to 'blurring'. I really want to use internal resizer cropping simply because I don't like the fact I overcrop 2 pixel rows for nothing using crop() function, but apparently doing it the other way isn't exactly safe either. Does this 'blurring' thing hold true for other resize methods too?
    Quote Quote