[MEncoder-users] cropdetect cuts off bottom of subtitles

Raphael mencoder at lesshaste.plus.com
Sat Jan 21 23:55:18 CET 2006


RC wrote:
> On Sat, 21 Jan 2006 14:47:08 +0000
> Raphael <mencoder at lesshaste.plus.com> wrote:
>
>   
>>> But if you cropdetect the same part you are encoding, and the source
>>> is a dvd (so  no random noise) then surely it should just scan from
>>> the bottom and  top (and left and right) until it hits something
>>> non-black.
>>>       
>
> Yes, although it might just ignore the subtitles as noise.  Or perhaps
> it's finding the right dimentions, and the rounding is just
> (unfortunately) cutting off (up to) 7 lines off the bottom, which cuts
> off the bottom of your subtitles.
>
>   
>>> You  should then get the minimum and maximum in the
>>> appropriate directions  rounded so that you don't chop any of the
>>> film out.
>>>       
>
> No, it doesn't round the numbers up, always down.  It's that simple.  If
> you don't want it to do that, you can change the default action of
> cropdetect.  See the man page.
>
> However, if you disable rounding, make sure you use scale to make the
> final dimentions even multiples of 16 before encoding.
>
>   
>> It occurs to me (after talking on IRC) that maybe cropdetect doesn't 
>> actually store the maximum lit area it ever finds. 
>>     
>
> If you watch the output of cropdetect for a while, you'll see that this
> obviously isn't true.  The dimentions cropdetect outputs NEVER decrease.
>   


Thanks. There appear to be two distinct and contradictory stories on the 
mailing list sadly.  I also noticed that the dimensions never decrease 
which directly contradicts the previous two replies ("The value output 
by cropdetect is the value for the current frame." and "  yes, (I think)
I check only cropdetect on the scene with the most subs. Then I know for 
sure I got all subs and as few as black possible. ")

Also,  what do the "limit" values mean exactly in this part of the man 
page.  What is 24?


cropdetect[=limit:round]
 Calculates necessary cropping parameters and prints the  recommended  
parame-
 ters to stdout.
          <limit>
               Threshold,  which  can be optionally specified from 
nothing (0)
               to everything (255) (default: 24).


Raphael





More information about the MEncoder-users mailing list