[FFmpeg-user] ocr howto set whitelist

Paul B Mahol onemda at gmail.com
Fri May 17 20:03:30 EEST 2019


On 5/17/19, Thomas Seilund <tps at netmaster.dk> wrote:
>
> On 17/05/2019 16.13, Paul B Mahol wrote:
>> On 5/17/19, Thomas Seilund <tps at netmaster.dk> wrote:
>>> Hi all
>>>
>>> I run this command as webcam connected at /dev/video2 points a piece of
>>> paper with the text "123a".
>>>
>>> FFREPORT=file=ffreport.log:level=32 ffmpeg -y -loglevel debug -f v4l2
>>> -input_format mjpeg -s hd480 -r 30 -i /dev/video2 -filter_complex
>>> "[0:0]fps=1,ocr=language=eng:whitelist=0123456789,metadata=print:key=lavfi.ocr.text,null[X]"
>>> -map '[X]' -pix_fmt yuv420p -f xv Title
>>>
>>> Above I set whitelist to "0123456789" but still I see
>>> "[Parsed_metadata_2 @ 0x55fb2537b9c0] lavfi.ocr.text=123a" in log file
>>> ffreport.log
>>>
>>> Why is the letter "a" recognized when the letter "a" is not in the
>>> whitelist?
>> Probably because blacklist is empty.
>
> Thanks
>
> New command but same behaviour:
>
> FFREPORT=file=ffreport.log:level=32 ffmpeg -y -loglevel debug -f v4l2
> -input_format mjpeg -s hd480 -r 30 -i /dev/video2 -filter_complex
> "[0:0]fps=1,ocr=language=eng:whitelist=0123456789:blacklist=abc,metadata=print:key=lavfi.ocr.text,null[X]"
> -map '[X]' -pix_fmt yuv420p -f xv Title

It is tesseract bug, not ours. It worked before just fine.

>
>>
>>> It is difficult to find ex. of ffmpeg with the ocr filter - any hints?
>>>
>>> Thanks in advance
>>>
>>> Thomas S
>>>
>>> _______________________________________________
>>> ffmpeg-user mailing list
>>> ffmpeg-user at ffmpeg.org
>>> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>>>
>>> To unsubscribe, visit link above, or email
>>> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
>> _______________________________________________
>> ffmpeg-user mailing list
>> ffmpeg-user at ffmpeg.org
>> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>>
>> To unsubscribe, visit link above, or email
>> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
> To unsubscribe, visit link above, or email
> ffmpeg-user-request at ffmpeg.org with subject "unsubscribe".


More information about the ffmpeg-user mailing list