#249 closed defect (fixed)
Fix the filter remove-logo
Reported by: | Peter Basista | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | avfilter |
Version: | git-master | Keywords: | remove-logo mpfilter |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | yes | |
Analyzed by developer: | no |
Description
Whenever I try to use the remove-logo filter, I get a segmentation fault:
ffmpeg -i input.avi -vcodec libx264 -acodec copy -vf mp=remove-logo:logo.ppm output.avi
That's the ending of what I get:
[mp @ 0x13e5280] This is a unholy filter, it will be purified by the ffmpeg exorcist team
which will change its syntax from dark -vf mp to light -vf.
Thou shalst not make spells or scripts that depend on it
Segmentation fault
I am posting it as an enhancement, not as a defect. I was told that this filter is facing to be dropped and it would be the best to port it to libavfilter.
Attachments (4)
Change History (17)
comment:1 by , 14 years ago
Priority: | normal → minor |
---|---|
Status: | new → open |
comment:2 by , 14 years ago
Okay, here is the complete ffmpeg output with the segmentation fault:
ffmpeg -i input.avi -vcodec mpeg2video -sameq -acodec copy -vf mp=remove-logo:logo.pgm -y output.avi
ffmpeg version git-N-30306-g6b899e1, Copyright (c) 2000-2011 the FFmpeg developers
built on May 27 2011 12:55:55 with gcc 4.5.2
configuration: --enable-gpl
libavutil 51. 2. 2 / 51. 2. 2
libavcodec 53. 6. 0 / 53. 6. 0
libavformat 53. 2. 0 / 53. 2. 0
libavdevice 53. 0. 0 / 53. 0. 0
libavfilter 2. 11. 0 / 2. 11. 0
libswscale 0. 14. 0 / 0. 14. 0
libpostproc 51. 2. 0 / 51. 2. 0
Input #0, avi, from 'input.avi':
Metadata:
encoder : Lavf53.2.0
Duration: 00:01:00.04, start: 0.000000, bitrate: 3798 kb/s
Stream #0.0: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 16:15 DAR 4:3], 15000 kb/s, PAR 64:45 DAR 16:9, 25 fps, 25 tbr, 25 tbn, 50 tbc
Stream #0.1: Audio: mp2, 48000 Hz, stereo, s16, 192 kb/s
[buffer @ 0x29a1c00] w:720 h:576 pixfmt:yuv420p tb:1/1000000 sar:64/45 sws_param:
[mp @ 0x29ccda0] This is a unholy filter, it will be purified by the ffmpeg exorcist team
which will change its syntax from dark -vf mp to light -vf.
Thou shalst not make spells or scripts that depend on it
Segmentation fault
And here is the gdb output:
gdb ffmpeg_g
GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/peter/code/ffmpeg/ffmpeg_g...done.
(gdb) r -i input.avi -vcodec mpeg2video -sameq -acodec copy -vf mp=remove-logo:logo.pgm -y output.avi
Starting program: /home/peter/code/ffmpeg/ffmpeg_g -i input.avi -vcodec mpeg2video -sameq -acodec copy -vf mp=remove-logo:logo.pgm -y output.avi
[Thread debugging using libthread_db enabled]
ffmpeg version git-N-30306-g6b899e1, Copyright (c) 2000-2011 the FFmpeg developers
built on May 27 2011 12:55:55 with gcc 4.5.2
configuration: --enable-gpl
libavutil 51. 2. 2 / 51. 2. 2
libavcodec 53. 6. 0 / 53. 6. 0
libavformat 53. 2. 0 / 53. 2. 0
libavdevice 53. 0. 0 / 53. 0. 0
libavfilter 2. 11. 0 / 2. 11. 0
libswscale 0. 14. 0 / 0. 14. 0
libpostproc 51. 2. 0 / 51. 2. 0
Input #0, avi, from 'input.avi':
Metadata:
encoder : Lavf53.2.0
Duration: 00:01:00.04, start: 0.000000, bitrate: 3798 kb/s
Stream #0.0: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 16:15 DAR 4:3], 15000 kb/s, PAR 64:45 DAR 16:9, 25 fps, 25 tbr, 25 tbn, 50 tbc
Stream #0.1: Audio: mp2, 48000 Hz, stereo, s16, 192 kb/s
[buffer @ 0x12b8c00] w:720 h:576 pixfmt:yuv420p tb:1/1000000 sar:64/45 sws_param:
[mp @ 0x12e3da0] This is a unholy filter, it will be purified by the ffmpeg exorcist team
which will change its syntax from dark -vf mp to light -vf.
Thou shalst not make spells or scripts that depend on it
Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0 0x0000000000000000 in ?? ()
#1 0x000000000044ad6b in query_formats (ctx=0x12e3da0)
at libavfilter/vf_mp.c:796
#2 0x0000000000444c42 in query_formats (graph=0x12e2f60, log_ctx=0x0)
at libavfilter/avfiltergraph.c:147
#3 0x0000000000445296 in ff_avfilter_graph_config_formats (graph=0x12e2f60,
log_ctx=<value optimized out>) at libavfilter/avfiltergraph.c:220
#4 0x000000000044540b in avfilter_graph_config (graphctx=0x12e2f60,
log_ctx=0x0) at libavfilter/avfiltergraph.c:236
#5 0x0000000000438173 in configure_video_filters (nb_output_files=1,
input_files=0x12e3530, nb_input_files=1, stream_maps=0x0,
nb_stream_maps=<value optimized out>, output_files=0xd55f20)
at ffmpeg.c:428
#6 transcode (nb_output_files=1, input_files=0x12e3530, nb_input_files=1,
stream_maps=0x0, nb_stream_maps=<value optimized out>,
output_files=0xd55f20) at ffmpeg.c:2277
#7 0x000000000043d44e in main (argc=<value optimized out>,
argv=<value optimized out>) at ffmpeg.c:4530
(gdb) disass $pc-32,$pc+32
Dump of assembler code from 0xffffffffffffffe0 to 0x20:
End of assembler dump.
(gdb) info all-registers
rax 0x0 0
rbx 0x32315659 842094169
rcx 0x7fffffffd350 140737488343888
rdx 0x990091 10027153
rsi 0x32315659 842094169
rdi 0x12cc920 19712288
rbp 0x9905d0 0x9905d0
rsp 0x7fffffffd428 0x7fffffffd428
r8 0x7ffff7207288 140737339486856
r9 0x7ffff7207228 140737339486760
r10 0x60 96
r11 0x8 8
r12 0x12cc6e0 19711712
r13 0x12e3da0 19807648
r14 0x12e2f60 19804000
r15 0x0 0
rip 0x0 0
eflags 0x10246 [ PF ZF IF RF ]
cs 0x33 51
ss 0x2b 43
ds 0x0 0
es 0x0 0
fs 0x0 0
---Type <return> to continue, or q <return> to quit---
gs 0x0 0
st0 -nan(0x7f80808183858687) (raw 0xffff7f80808183858687)
st1 -nan(0x7f008000800081) (raw 0xffff007f008000800081)
st2 -nan(0x8181818384868889) (raw 0xffff8181818384868889)
st3 -nan(0x81008100810083) (raw 0xffff0081008100810083)
st4 -nan(0x8181818283858687) (raw 0xffff8181818283858687)
st5 -nan(0x81008100810082) (raw 0xffff0081008100810082)
st6 -nan(0x8080808081828283) (raw 0xffff8080808081828283)
st7 -nan(0x80008000800080) (raw 0xffff0080008000800080)
fctrl 0x37f 895
fstat 0x0 0
ftag 0xffff 65535
fiseg 0x0 0
fioff 0x0 0
foseg 0x0 0
fooff 0x0 0
fop 0x0 0
xmm0 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {
0x8000000000000000, 0x8000000000000000}, v16_int8 = {0x0, 0x0, 0x0, 0xff,
0x0, 0x0, 0xff, 0xff, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff},
v8_int16 = {0x0, 0xff00, 0x0, 0xffff, 0x0, 0x0, 0x0, 0xffff}, v4_int32 = {
0xff000000, 0xffff0000, 0x0, 0xffff0000}, v2_int64 = {0xffff0000ff000000,
0xffff000000000000}, uint128 = 0xffff000000000000ffff0000ff000000}
---Type <return> to continue, or q <return> to quit---
xmm1 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0xff, 0xff, 0xff, 0x0 <repeats 13 times>}, v8_int16 = {0xffff,
0xff, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0xffffff, 0x0, 0x0, 0x0},
v2_int64 = {0xffffff, 0x0}, uint128 = 0x00000000000000000000000000ffffff}
xmm2 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x6f, 0x75, 0x74, 0x0 <repeats 13 times>}, v8_int16 = {0x756f,
0x74, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x74756f, 0x0, 0x0, 0x0},
v2_int64 = {0x74756f, 0x0}, uint128 = 0x0000000000000000000000000074756f}
xmm3 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0,
0x8000000000000000}, v16_int8 = {0xff, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xff}, v8_int16 = {0xff, 0x0, 0x0,
0x0, 0x0, 0xff, 0x0, 0xff00}, v4_int32 = {0xff, 0x0, 0xff0000,
0xff000000}, v2_int64 = {0xff, 0xff00000000ff0000},
uint128 = 0xff00000000ff000000000000000000ff}
xmm4 {v4_float = {0x0, 0x1, 0x3, 0x3}, v2_double = {0x0, 0x20},
v16_int8 = {0x0, 0x0, 0x0, 0xe0, 0x95, 0x9c, 0xe7, 0x3f, 0x40, 0x40, 0x40,
0x40, 0x40, 0x40, 0x40, 0x40}, v8_int16 = {0x0, 0xe000, 0x9c95, 0x3fe7,
0x4040, 0x4040, 0x4040, 0x4040}, v4_int32 = {0xe0000000, 0x3fe79c95,
0x40404040, 0x40404040}, v2_int64 = {0x3fe79c95e0000000,
0x4040404040404040}, uint128 = 0x40404040404040403fe79c95e0000000}
xmm5 {v4_float = {0x0, 0x1, 0x0, 0x0}, v2_double = {0x1, 0x0},
v16_int8 = {0x6d, 0x7d, 0xbf, 0xbb, 0x27, 0xaf, 0xf5, 0x3f, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x7d6d, 0xbbbf, 0xaf27, 0x3ff5, 0x0,
---Type <return> to continue, or q <return> to quit---
0x0, 0x0, 0x0}, v4_int32 = {0xbbbf7d6d, 0x3ff5af27, 0x0, 0x0}, v2_int64 = {
0x3ff5af27bbbf7d6d, 0x0}, uint128 = 0x00000000000000003ff5af27bbbf7d6d}
xmm6 {v4_float = {0x0, 0xfffffffd, 0x0, 0x0}, v2_double = {
0xffffffffffffffd2, 0x0}, v16_int8 = {0x5b, 0xaa, 0xa2, 0x2a, 0x9e, 0x6,
0x47, 0xc0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0xaa5b,
0x2aa2, 0x69e, 0xc047, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x2aa2aa5b,
0xc047069e, 0x0, 0x0}, v2_int64 = {0xc047069e2aa2aa5b, 0x0},
uint128 = 0x0000000000000000c047069e2aa2aa5b}
xmm7 {v4_float = {0x0, 0x1, 0x0, 0x0}, v2_double = {0x1, 0x0},
v16_int8 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf0, 0x3f, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x0, 0x0, 0x0, 0x3ff0, 0x0, 0x0, 0x0,
0x0}, v4_int32 = {0x0, 0x3ff00000, 0x0, 0x0}, v2_int64 = {
0x3ff0000000000000, 0x0}, uint128 = 0x00000000000000003ff0000000000000}
xmm8 {v4_float = {0x0, 0xfffffffd, 0x0, 0x0}, v2_double = {
0xffffffffffffffd2, 0x0}, v16_int8 = {0xe0, 0xe6, 0x35, 0x67, 0x9e, 0x6,
0x47, 0xc0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0xe6e0,
0x6735, 0x69e, 0xc047, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x6735e6e0,
0xc047069e, 0x0, 0x0}, v2_int64 = {0xc047069e6735e6e0, 0x0},
uint128 = 0x0000000000000000c047069e6735e6e0}
xmm9 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0, 0x0, 0x0, 0x0, 0x68, 0xc8, 0xbc, 0x3b, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x0, 0x0, 0xc868, 0x3bbc, 0x0, 0x0, 0x0,
0x0}, v4_int32 = {0x0, 0x3bbcc868, 0x0, 0x0}, v2_int64 = {
---Type <return> to continue, or q <return> to quit---
0x3bbcc86800000000, 0x0}, uint128 = 0x00000000000000003bbcc86800000000}
xmm10 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0, 0x0, 0x46, 0x84, 0x24, 0x59, 0xd6, 0x3e, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x0, 0x8446, 0x5924, 0x3ed6, 0x0,
0x0, 0x0, 0x0}, v4_int32 = {0x84460000, 0x3ed65924, 0x0, 0x0}, v2_int64 = {
0x3ed6592484460000, 0x0}, uint128 = 0x00000000000000003ed6592484460000}
xmm11 {v4_float = {0x9689a800, 0x0, 0x0, 0x0}, v2_double = {0x0,
0x0}, v16_int8 = {0x6a, 0xa2, 0x65, 0x50, 0xf2, 0xea, 0x8f, 0xbd, 0x0,
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0xa26a, 0x5065, 0xeaf2,
0xbd8f, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x5065a26a, 0xbd8feaf2, 0x0,
0x0}, v2_int64 = {0xbd8feaf25065a26a, 0x0},
uint128 = 0x0000000000000000bd8feaf25065a26a}
xmm12 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc4, 0x3c, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x0, 0x0, 0x0, 0x3cc4, 0x0, 0x0, 0x0,
0x0}, v4_int32 = {0x0, 0x3cc40000, 0x0, 0x0}, v2_int64 = {
0x3cc4000000000000, 0x0}, uint128 = 0x00000000000000003cc4000000000000}
xmm13 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
v16_int8 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x80, 0x59, 0xbc, 0x0, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x0, 0x0, 0x8000, 0xbc59, 0x0, 0x0, 0x0,
0x0}, v4_int32 = {0x0, 0xbc598000, 0x0, 0x0}, v2_int64 = {
0xbc59800000000000, 0x0}, uint128 = 0x0000000000000000bc59800000000000}
xmm14 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0},
---Type <return> to continue, or q <return> to quit---
v16_int8 = {0x8e, 0x85, 0x83, 0xe8, 0xf0, 0x24, 0x53, 0x3c, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x858e, 0xe883, 0x24f0, 0x3c53, 0x0,
0x0, 0x0, 0x0}, v4_int32 = {0xe883858e, 0x3c5324f0, 0x0, 0x0}, v2_int64 = {
0x3c5324f0e883858e, 0x0}, uint128 = 0x00000000000000003c5324f0e883858e}
xmm15 {v4_float = {0x0, 0x3, 0x0, 0x0}, v2_double = {0x2d, 0x0},
v16_int8 = {0xc0, 0x9, 0xf2, 0x16, 0xb5, 0xdf, 0x46, 0x40, 0x0, 0x0, 0x0,
0x0, 0x0, 0x0, 0x0, 0x0}, v8_int16 = {0x9c0, 0x16f2, 0xdfb5, 0x4046, 0x0,
0x0, 0x0, 0x0}, v4_int32 = {0x16f209c0, 0x4046dfb5, 0x0, 0x0}, v2_int64 = {
0x4046dfb516f209c0, 0x0}, uint128 = 0x00000000000000004046dfb516f209c0}
mxcsr 0x1fa0 [ PE IM DM ZM OM UM PM ]
(gdb)
I would also like to note that the gdb disass command presented here:
http://ffmpeg.org/bugreports.html
is not working. Here is what I get when I run it:
(gdb) disass $pc-32 $pc+32
A syntax error in expression, near `$pc+32'.
Instead, a little different syntax, with a comma, appears to work:
(gdb) disass $pc-32,$pc+32
Dump of assembler code from 0xffffffffffffffe0 to 0x20:
End of assembler dump.
But I am not sure if this is what you wanted.
follow-up: 4 comment:3 by , 14 years ago
Priority: | minor → normal |
---|---|
Type: | enhancement → defect |
Could you start gdb again and post the version of gdb (gdb -v) and the output of
(gdb) help disass
The issue is reproducible:
(gdb) r -i test.ts -an -vf mp=remove-logo:out0225.ppm out.avi ffmpeg version git-N-30308-g041dbd3, Copyright (c) 2000-2011 the FFmpeg developers built on May 27 2011 15:42:14 with gcc 4.5.3 configuration: --cc=/usr/local/gcc-4.5.3/bin/gcc --enable-gpl --disable-optimizations libavutil 51. 2. 2 / 51. 2. 2 libavcodec 53. 6. 0 / 53. 6. 0 libavformat 53. 2. 0 / 53. 2. 0 libavdevice 53. 0. 0 / 53. 0. 0 libavfilter 2. 11. 0 / 2. 11. 0 libswscale 0. 14. 0 / 0. 14. 0 libpostproc 51. 2. 0 / 51. 2. 0 [mpeg2video @ 0x14820e0] mpeg_decode_postinit() failure Last message repeated 1 times [mpegts @ 0x147abc0] max_analyze_duration 5000000 reached at 5000000 [NULL @ 0x14a3e00] start time is not set in av_estimate_timings_from_pts [NULL @ 0x14a7f00] start time is not set in av_estimate_timings_from_pts [NULL @ 0x14a9f80] start time is not set in av_estimate_timings_from_pts [NULL @ 0x14ac000] start time is not set in av_estimate_timings_from_pts [NULL @ 0x14ae080] start time is not set in av_estimate_timings_from_pts [NULL @ 0x14b0100] start time is not set in av_estimate_timings_from_pts Input #0, mpegts, from 'test.ts': Duration: 00:00:20.58, start: 73344.586911, bitrate: 4074 kb/s Program 10101 Stream #0.0[0x3f2]: Video: mpeg2video (Main), yuv420p, 720x576 [PAR 64:45 DAR 16:9], 4300 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc Stream #0.1[0x3f3](ger): Audio: mp2, 48000 Hz, stereo, s16, 160 kb/s (clean effects) Stream #0.2[0x3f4](eng): Audio: mp2, 48000 Hz, stereo, s16, 160 kb/s (clean effects) Stream #0.3[0x3f5](ger): Audio: ac3, 48000 Hz, stereo, s16, 448 kb/s (clean effects) Stream #0.4[0x3f6]: Data: [6][0][0][0] / 0x0006 Stream #0.5[0x3f7](ger): Subtitle: [6][0][0][0] / 0x0006 Stream #0.6[0x1b63]: Data: [11][0][0][0] / 0x000B Stream #0.7[0x1b64]: Data: [11][0][0][0] / 0x000B Stream #0.8[0x1b6d]: Data: [12][0][0][0] / 0x000C Stream #0.9[0x1b77]: Data: [11][0][0][0] / 0x000B Stream #0.10[0x1bbd]: Data: [5][0][0][0] / 0x0005 Program 10102 Program 10120 Program 10122 File 'out.avi' already exists. Overwrite ? [y/N] y [buffer @ 0x147dd20] w:720 h:576 pixfmt:yuv420p tb:1/1000000 sar:64/45 sws_param: [mp @ 0x1521e00] This is a unholy filter, it will be purified by the ffmpeg exorcist team which will change its syntax from dark -vf mp to light -vf. Thou shalst not make spells or scripts that depend on it Program received signal SIGSEGV, Segmentation fault. 0x0000000000464296 in convert_mask_to_strength_mask (vf=0x1481140, mask=0x148b310) at libavfilter/libmpcodecs/vf_remove_logo.c:384 384 *(current_pixel - mask->width) >= current_pass) (gdb) bt #0 0x0000000000464296 in convert_mask_to_strength_mask (vf=0x1481140, mask=0x148b310) at libavfilter/libmpcodecs/vf_remove_logo.c:384 #1 0x00000000004655e1 in vf_open (vf=0x1481140, args=0x1521d6c "out0225.ppm") at libavfilter/libmpcodecs/vf_remove_logo.c:872 #2 0x000000000042c4bb in init (ctx=0x1521e00, args=0x1521d6c "out0225.ppm", opaque=0x0) at libavfilter/vf_mp.c:780 #3 0x0000000000420315 in avfilter_init_filter (filter=0x1521e00, args=0x1521d60 "remove-logo:out0225.ppm", opaque=0x0) at libavfilter/avfilter.c:712 #4 0x0000000000422bb0 in create_filter (filt_ctx=0x7fffffffcf88, ctx=0x14aa5c0, index=0, filt_name=0x1521ce0 "mp", args=0x1521d60 "remove-logo:out0225.ppm", log_ctx=0x0) at libavfilter/graphparser.c:130 #5 0x0000000000422c8d in parse_filter (filt_ctx=0x7fffffffcf88, buf=0x7fffffffcf60, graph=0x14aa5c0, index=0, log_ctx=0x0) at libavfilter/graphparser.c:165 #6 0x0000000000423290 in avfilter_graph_parse (graph=0x14aa5c0, filters=0x14827fa "", open_inputs=0x15223a0, open_outputs=0x14808e0, log_ctx=0x0) at libavfilter/graphparser.c:347 #7 0x000000000040596a in configure_video_filters (ist=0x14817c0, ost=0x147fde0) at ffmpeg.c:420 #8 0x000000000040c684 in transcode (output_files=0xf08380, nb_output_files=1, input_files=0x1482580, nb_input_files=1, stream_maps=0x0, nb_stream_maps=0) at ffmpeg.c:2277 #9 0x0000000000412ec3 in main (argc=7, argv=0x7fffffffddd8) at ffmpeg.c:4530 (gdb) disass $pc-32 $pc+32 Dump of assembler code from 0x464276 to 0x4642b6: 0x0000000000464276 <convert_mask_to_strength_mask+209>: mov %eax,%eax 0x0000000000464278 <convert_mask_to_strength_mask+211>: add -0x20(%rbp),%rax 0x000000000046427c <convert_mask_to_strength_mask+215>: movzbl (%rax),%eax 0x000000000046427f <convert_mask_to_strength_mask+218>: movsbl %al,%eax 0x0000000000464282 <convert_mask_to_strength_mask+221>: cmp -0x18(%rbp),%eax 0x0000000000464285 <convert_mask_to_strength_mask+224>: jl 0x4642b8 <convert_mask_to_strength_mask+275> 0x0000000000464287 <convert_mask_to_strength_mask+226>: mov -0x38(%rbp),%rax 0x000000000046428b <convert_mask_to_strength_mask+230>: mov (%rax),%eax 0x000000000046428d <convert_mask_to_strength_mask+232>: mov %eax,%eax 0x000000000046428f <convert_mask_to_strength_mask+234>: neg %rax 0x0000000000464292 <convert_mask_to_strength_mask+237>: add -0x20(%rbp),%rax 0x0000000000464296 <convert_mask_to_strength_mask+241>: movzbl (%rax),%eax 0x0000000000464299 <convert_mask_to_strength_mask+244>: movsbl %al,%eax 0x000000000046429c <convert_mask_to_strength_mask+247>: cmp -0x18(%rbp),%eax 0x000000000046429f <convert_mask_to_strength_mask+250>: jl 0x4642b8 <convert_mask_to_strength_mask+275> 0x00000000004642a1 <convert_mask_to_strength_mask+252>: mov -0x20(%rbp),%rax 0x00000000004642a5 <convert_mask_to_strength_mask+256>: movzbl (%rax),%eax 0x00000000004642a8 <convert_mask_to_strength_mask+259>: lea 0x1(%rax),%edx 0x00000000004642ab <convert_mask_to_strength_mask+262>: mov -0x20(%rbp),%rax 0x00000000004642af <convert_mask_to_strength_mask+266>: mov %dl,(%rax) 0x00000000004642b1 <convert_mask_to_strength_mask+268>: movl $0x1,-0x14(%rbp) End of assembler dump. (gdb) info register rax 0x7ffff7f3bc11 140737353333777 rbx 0x1521fd0 22159312 rcx 0x240 576 rdx 0x2 2 rsi 0x148b310 21541648 rdi 0x1481140 21500224 rbp 0x7fffffffcb90 0x7fffffffcb90 rsp 0x7fffffffcb88 0x7fffffffcb88 r8 0x7ffff7fcd6f0 140737353930480 r9 0x0 0 r10 0x22 34 r11 0x246 582 r12 0x14aa5c0 21669312 r13 0x7fffffffddd0 140737488346576 r14 0x0 0 r15 0x0 0 rip 0x464296 0x464296 <convert_mask_to_strength_mask+241> eflags 0x10207 [ CF PF IF RF ] cs 0x33 51 ss 0x2b 43 ds 0x0 0 es 0x0 0 fs 0x0 0 gs 0x0 0 fctrl 0x37f 895 fstat 0x0 0 ftag 0xffff 65535 fiseg 0x0 0 fioff 0x0 0 foseg 0x0 0 fooff 0x0 0 fop 0x0 0 mxcsr 0x1fa0 [ PE IM DM ZM OM UM PM ]
comment:4 by , 14 years ago
Replying to cehoyos:
Could you start gdb again and post the version of gdb (gdb -v) and the output of
(gdb) help disass
Of course. The version was also printed in my previous post. Here is it:
gdb -v
GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
(gdb) help disass
Disassemble a specified section of memory.
Default is the function surrounding the pc of the selected frame.
With a /m modifier, source lines are included (if available).
With a /r modifier, raw instructions in hex are included.
With a single argument, the function surrounding that address is dumped.
Two arguments (separated by a comma) are taken as a range of memory to dump,
in the form of "start,end", or "start,+length".
comment:5 by , 14 years ago
Owner: | removed |
---|
by , 13 years ago
by , 13 years ago
by , 13 years ago
by , 13 years ago
Attachment: | result.png added |
---|
follow-up: 9 comment:7 by , 13 years ago
ppm does not crash atm, but result,png looks very bad,
pgm crashes:
(gdb) r -i test2.ts -an -vf mp=remove-logo:out.pgm out2.avi Starting program: ffmpeg_g -i test2.ts -an -vf mp=remove-logo:out.pgm out2.avi [Thread debugging using libthread_db enabled] ffmpeg version N-32542-g3867035, Copyright (c) 2000-2011 the FFmpeg developers built on Sep 13 2011 10:00:27 with gcc 4.5.3 configuration: --cc=/usr/local/gcc-4.5.3/bin/gcc --enable-gpl libavutil 51. 16. 0 / 51. 16. 0 libavcodec 53. 13. 0 / 53. 13. 0 libavformat 53. 12. 0 / 53. 12. 0 libavdevice 53. 3. 0 / 53. 3. 0 libavfilter 2. 40. 0 / 2. 40. 0 libswscale 2. 1. 0 / 2. 1. 0 libpostproc 51. 2. 0 / 51. 2. 0 [mpegts @ 0x12f4780] parser not found for codec dvb_teletext, packets or times may be invalid. [mpeg2video @ 0x12fbcc0] mpeg_decode_postinit() failure Last message repeated 4 times [mpegts @ 0x12f4780] PES packet size mismatch Last message repeated 3 times [NULL @ 0x131d9c0] start time is not set in estimate_timings_from_pts [NULL @ 0x1321ac0] start time is not set in estimate_timings_from_pts [NULL @ 0x1323b40] start time is not set in estimate_timings_from_pts [NULL @ 0x1325bc0] start time is not set in estimate_timings_from_pts [NULL @ 0x1327c40] start time is not set in estimate_timings_from_pts [NULL @ 0x1329cc0] start time is not set in estimate_timings_from_pts [mpegts @ 0x12f4780] PES packet size mismatch Last message repeated 3 times Input #0, mpegts, from 'test2.ts': Duration: 00:00:05.76, start: 12860.063633, bitrate: 2907 kb/s Program 10101 Stream #0.0[0x3f2]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420p, 720x576 [SAR 64:45 DAR 16:9], 4300 kb/s, 25.62 fps, 25 tbr, 90k tbn, 50 tbc Stream #0.1[0x3f3](ger): Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo, s16, 160 kb/s (clean effects) Stream #0.2[0x3f4](eng): Audio: mp2 ([3][0][0][0] / 0x0003), 48000 Hz, stereo, s16, 160 kb/s (clean effects) Stream #0.3[0x3f5](ger): Audio: ac3 ([6][0][0][0] / 0x0006), 48000 Hz, stereo, s16, 448 kb/s (clean effects) Stream #0.4[0x3f6]: Data: none ([6][0][0][0] / 0x0006) Stream #0.5[0x3f7](ger): Subtitle: dvb_teletext ([6][0][0][0] / 0x0006) Stream #0.6[0x1b63]: Data: none ([11][0][0][0] / 0x000B) Stream #0.7[0x1b64]: Data: none ([11][0][0][0] / 0x000B) Stream #0.8[0x1b6d]: Data: none ([12][0][0][0] / 0x000C) Stream #0.9[0x1b77]: Data: none ([11][0][0][0] / 0x000B) Stream #0.10[0x1bbd]: Data: none ([5][0][0][0] / 0x0005) Program 10102 Program 10120 Program 10122 [buffer @ 0x12fb860] w:720 h:576 pixfmt:yuv420p tb:1/1000000 sar:64/45 sws_param: [mp @ 0x12fb980] This is a unholy filter, it will be purified by the ffmpeg exorcist team which will change its syntax from dark -vf mp to light -vf. Thou shalst not make spells or scripts that depend on it Output #0, avi, to 'out2.avi': Metadata: ISFT : Lavf53.12.0 Stream #0.0: Video: mpeg4 (FMP4 / 0x34504D46), yuv420p, 720x576 [SAR 64:45 DAR 16:9], q=2-31, 200 kb/s, 25 tbn, 25 tbc Stream mapping: Stream #0.0 -> #0.0 (mpeg2video -> mpeg4) Press [q] to stop, [?] for help [mpeg2video @ 0x12fbcc0] warning: first frame is no keyframe Program received signal SIGSEGV, Segmentation fault. convert_yv12 (plane=<value optimized out>, y=143, x=<value optimized out>, image=0x33d0090, value_out=<value optimized out>, vf=<value optimized out>, logo_mask=<value optimized out>) at libavfilter/libmpcodecs/vf_remove_logo.c:744 744 get_blur(vf, &output, filter, source_image, x, y, plane); (gdb) bt #0 0x0000000000456698 in convert_yv12 (plane=<value optimized out>, y=143, x=<value optimized out>, image=0x33d0090, value_out=<value optimized out>, vf=<value optimized out>, logo_mask=<value optimized out>) #1 0x0000000000456956 in put_image (vf=0x131a140, mpi=0x33d0090, pts=849433000000) at libavfilter/libmpcodecs/vf_remove_logo.c:789 #2 0x000000000042712f in end_frame (inlink=0x33143e0) at libavfilter/vf_mp.c:872 #3 0x000000000041bb9f in avfilter_end_frame (link=0x33143e0) at libavfilter/avfilter.c:584 #4 0x000000000042f908 in request_frame (link=0x33143e0) at libavfilter/vsrc_buffer.c:192 #5 0x000000000041b13e in avfilter_request_frame (link=<value optimized out>) at libavfilter/avfilter.c:514 #6 0x0000000000426ee0 in request_frame (outlink=0x33145a0) at libavfilter/vf_mp.c:832 #7 0x000000000041b13e in avfilter_request_frame (link=<value optimized out>) at libavfilter/avfilter.c:514 #8 0x000000000041f5d4 in av_buffersink_get_buffer_ref (ctx=<value optimized out>, bufref=0x12f9d60, flags=0) at libavfilter/sink_buffer.c:128 #9 0x0000000000408dfc in output_packet (ist=<value optimized out>, ist_index=0, ost_table=0x12f9b20, nb_ostreams=1, pkt=<value optimized out>) at ffmpeg.c:1825 #10 0x000000000040dbad in transcode (output_files=0x12f80e0, nb_output_files=<value optimized out>, input_files=0x12fa7b0, nb_input_files=1) at ffmpeg.c:2591 #11 0x0000000000410ad1 in main (argc=<value optimized out>, argv=<value optimized out>) at ffmpeg.c:4373 (gdb) disass $pc-32 $pc+32 Dump of assembler code from 0x456678 to 0x4566b8: 0x0000000000456678 <get_blur+449>: mov %rax,%rbp 0x000000000045667b <get_blur+452>: nopl 0x0(%rax,%rax,1) 0x0000000000456680 <get_blur+457>: cmp 0x14(%rsp),%r15d 0x0000000000456685 <get_blur+462>: jg 0x4566cc <get_blur+533> 0x0000000000456687 <get_blur+464>: lea (%r9,%rbp,1),%rsi 0x000000000045668b <convert_yv12+651>: mov %r12,%rcx 0x000000000045668e <convert_yv12+654>: mov %r9,%rax 0x0000000000456691 <convert_yv12+657>: xor %edx,%edx 0x0000000000456693 <convert_yv12+659>: nopl 0x0(%rax,%rax,1) 0x0000000000456698 <get_blur+481>: cmpb $0x0,(%rax) 0x000000000045669b <get_blur+484>: jne 0x4566b5 <get_blur+510> 0x000000000045669d <get_blur+486>: mov (%r11),%rdi 0x00000000004566a0 <get_blur+489>: mov (%rdi,%rdx,1),%rdi 0x00000000004566a4 <get_blur+493>: mov (%rdi,%r8,1),%edi 0x00000000004566a8 <get_blur+497>: test %edi,%edi 0x00000000004566aa <get_blur+499>: je 0x4566b5 <get_blur+510> 0x00000000004566ac <get_blur+501>: movzbl (%rcx),%edi 0x00000000004566af <get_blur+504>: add $0x1,%ebx 0x00000000004566b2 <get_blur+507>: add %edi,%r10d 0x00000000004566b5 <get_blur+510>: add $0x1,%rax End of assembler dump. (gdb) info register rax 0x10139be08 4315528712 rbx 0x0 0 rcx 0x7ffff54165b0 140737308091824 rdx 0x0 0 rsi 0x10139bf71 4315529073 rdi 0x7 7 rbp 0x169 0x169 rsp 0x7fffffffb240 0x7fffffffb240 r8 0x4 4 r9 0x10139be08 4315528712 r10 0x0 0 r11 0x131b040 20033600 r12 0x7ffff54165b0 140737308091824 r13 0x1 1 r14 0x169 361 r15 0x0 0 rip 0x456698 0x456698 <get_blur+481> eflags 0x10246 [ PF ZF IF RF ] cs 0x33 51 ss 0x2b 43 ds 0x0 0 es 0x0 0 fs 0x0 0 gs 0x0 0 fctrl 0x37f 895 fstat 0x0 0 ftag 0xffff 65535 fiseg 0x0 0 fioff 0x0 0 foseg 0x0 0 fooff 0x0 0 fop 0x0 0 mxcsr 0x1fa0 [ PE IM DM ZM OM UM PM ]
comment:8 by , 13 years ago
with --disable-optimizations:
Program received signal SIGSEGV, Segmentation fault. 0x000000000046d69d in get_blur (vf=0x14a2140, value_out=0x7fffffffbed4, logo_mask=0x1482520, image=0x3558090, x=180, y=143, plane=1) at libavfilter/libmpcodecs/vf_remove_logo.c:455 455 if (!(*logo_mask_read_position) && mask[mask_size][i - start_posx][j - start_posy]) (gdb) bt #0 0x000000000046d69d in get_blur (vf=0x14a2140, value_out=0x7fffffffbed4, logo_mask=0x1482520, image=0x3558090, x=180, y=143, plane=1) at libavfilter/libmpcodecs/vf_remove_logo.c:455 #1 0x000000000046e167 in convert_yv12 (vf=0x14a2140, source=0x7ffff5416440 "\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200\200"..., source_stride=368, source_image=0x3558090, width=360, height=288, destination=0x7ffff5396940 "\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377"..., destination_stride=360, is_image_direct=0, filter=0x1482520, plane=1, logo_start_x=0, logo_start_y=0, logo_end_x=359, logo_end_y=287) at libavfilter/libmpcodecs/vf_remove_logo.c:744 #2 0x000000000046e48f in put_image (vf=0x14a2140, mpi=0x3558090, pts=849433000000) at libavfilter/libmpcodecs/vf_remove_logo.c:789 #3 0x0000000000436341 in end_frame (inlink=0x349c3e0) at libavfilter/vf_mp.c:872 #4 0x0000000000423d35 in avfilter_end_frame (link=0x349c3e0) at libavfilter/avfilter.c:584 #5 0x0000000000442012 in request_frame (link=0x349c3e0) at libavfilter/vsrc_buffer.c:192 #6 0x00000000004239d8 in avfilter_request_frame (link=0x349c3e0) at libavfilter/avfilter.c:514 #7 0x000000000043614b in request_frame (outlink=0x349c5a0) at libavfilter/vf_mp.c:832 #8 0x00000000004239d8 in avfilter_request_frame (link=0x349c5a0) at libavfilter/avfilter.c:514 #9 0x00000000004287fa in av_buffersink_get_buffer_ref (ctx=0x147fce0, bufref=0x1481d60, flags=0) at libavfilter/sink_buffer.c:128 #10 0x000000000040acfa in output_packet (ist=0x14814a0, ist_index=0, ost_table=0x1481b20, nb_ostreams=1, pkt=0x7fffffffd920) at ffmpeg.c:1825 #11 0x000000000040dc87 in transcode (output_files=0x14800e0, nb_output_files=1, input_files=0x14827b0, nb_input_files=1) at ffmpeg.c:2591 #12 0x0000000000413ff0 in main (argc=7, argv=0x7fffffffddd8) at ffmpeg.c:4373 (gdb) disass $pc-32 $pc+32 Dump of assembler code from 0x46d67d to 0x46d6bd: 0x000000000046d67d <get_blur+296>: add %ecx,-0x73(%rax) 0x000000000046d680 <get_blur+299>: add $0x2,%al 0x000000000046d682 <get_blur+301>: mov %rax,-0x28(%rbp) 0x000000000046d686 <get_blur+305>: mov -0x3c(%rbp),%eax 0x000000000046d689 <get_blur+308>: mov %eax,-0x10(%rbp) 0x000000000046d68c <get_blur+311>: jmpq 0x46d74d <get_blur+504> 0x000000000046d691 <get_blur+316>: mov -0x38(%rbp),%eax 0x000000000046d694 <get_blur+319>: mov %eax,-0xc(%rbp) 0x000000000046d697 <get_blur+322>: jmp 0x46d708 <get_blur+435> 0x000000000046d699 <get_blur+324>: mov -0x28(%rbp),%rax 0x000000000046d69d <get_blur+328>: movzbl (%rax),%eax 0x000000000046d6a0 <get_blur+331>: test %al,%al 0x000000000046d6a2 <get_blur+333>: jne 0x46d6fa <get_blur+421> 0x000000000046d6a4 <get_blur+335>: mov -0x34(%rbp),%eax 0x000000000046d6a7 <get_blur+338>: cltq 0x000000000046d6a9 <get_blur+340>: shl $0x3,%rax 0x000000000046d6ad <get_blur+344>: add -0x30(%rbp),%rax 0x000000000046d6b1 <get_blur+348>: mov (%rax),%rax 0x000000000046d6b4 <get_blur+351>: mov -0x38(%rbp),%edx 0x000000000046d6b7 <get_blur+354>: mov -0xc(%rbp),%ecx 0x000000000046d6ba <get_blur+357>: mov %ecx,%ebx 0x000000000046d6bc <get_blur+359>: sub %edx,%ebx End of assembler dump. (gdb) info register rax 0x101523e08 4317134344 rbx 0xffffffdb 4294967259 rcx 0x0 0 rdx 0x168 360 rsi 0x7fffffffbed4 140737488338644 rdi 0x14a2140 21635392 rbp 0x7fffffffbe80 0x7fffffffbe80 rsp 0x7fffffffbe78 0x7fffffffbe78 r8 0xb4 180 r9 0x8f 143 r10 0x8080808080808080 -9187201950435737472 r11 0x167 359 r12 0x11f 287 r13 0x168 360 r14 0x120 288 r15 0x0 0 rip 0x46d69d 0x46d69d <get_blur+328> eflags 0x10293 [ CF AF SF IF RF ] cs 0x33 51 ss 0x2b 43 ds 0x0 0 es 0x0 0 fs 0x0 0 gs 0x0 0 fctrl 0x37f 895 fstat 0x0 0 ftag 0xffff 65535 fiseg 0x0 0 fioff 0x0 0 foseg 0x0 0 fooff 0x0 0 fop 0x0 0 mxcsr 0x1fa0 [ PE IM DM ZM OM UM PM ]
comment:9 by , 13 years ago
Replying to cehoyos:
ppm does not crash atm, but result,png looks very bad,
This is probably expected because the black areas in out.ppm are not completely black.
A patch that was meant to improve remove-logo was never applied, afaict:
http://thread.gmane.org/gmane.comp.video.mplayer.devel/37219
comment:11 by , 13 years ago
The original idea of this filter was significantly higher quality than delogo iirc (see mplayer-dev-eng), the problem is that you need a nearly completely black ppm, iiuc.
It is even possible that the filter works fine if the needed input is provided...
comment:12 by , 13 years ago
Resolution: | → fixed |
---|---|
Status: | open → closed |
removelogo filter added in:
commit 2f83681c79a7419bec14ed6f40bf3a69b5dd16c2 Author: Stefano Sabatini <stefasab@gmail.com> Date: Sat Mar 10 14:01:28 2012 +0100 lavfi: port libmpcodecs remove-logo filter The code is based on the remove-logo filter in MPlayer/libmpcodecs, by Robert Edele, relicensed to LGPL with consent of the author. Address trac issue #249.
Please test the new filter and open a new ticket if it doesn't work for you.
comment:13 by , 12 years ago
Keywords: | mpfilter added |
---|
What would be useful:
Complete, uncut output and backtrace as explained on http://ffmpeg.org/bugreports.html