Opened 15 years ago
Closed 14 years ago
#876 closed defect (fixed)
ljpeg: fix 12/16bpp decoding for images with odd width
| Reported by: | ami_stuff | Owned by: | |
|---|---|---|---|
| Priority: | normal | Component: | swscale |
| Version: | git-master | Keywords: | mjpeg ljpeg |
| Cc: | Blocked By: | ||
| Blocking: | Reproduced by developer: | yes | |
| Analyzed by developer: | no |
Description
there is a vertical line on the right side in the output tiff image
https://ffmpeg.org/trac/ffmpeg/attachment/ticket/855/12_line.jpg
https://ffmpeg.org/trac/ffmpeg/attachment/ticket/855/16_line.jpg
ffmpeg -i 12_line.jpg out.tif
ffmpeg version 0.9.0.git-dc7ad85, Copyright (c) 2000-2012 the FFmpeg developers
built on Jan 4 2012 22:15:52 with gcc 4.5.0
libavutil 51. 34.100 / 51. 34.100
libavcodec 53. 50.100 / 53. 50.100
libavformat 53. 29.100 / 53. 29.100
libavdevice 53. 4.100 / 53. 4.100
libavfilter 2. 57.101 / 2. 57.101
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 5.100 / 0. 5.100
libpostproc 51. 2.100 / 51. 2.100
[mjpeg @ 0x10fef3e0] Warning: not compiled with thread support, using thread emulation
Input #0, image2, from '12_line.jpg':
Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
Codec 0x8 is not in the full list.
Stream #0:0: Video: mjpeg, gray16be, 639x439, 25 tbr, 25 tbn, 25 tbc
Incompatible pixel format 'gray16be' for codec 'tiff', auto-selecting format 'rgb48le'
[buffer @ 0x10ff1c60] w:639 h:439 pixfmt:gray16be tb:1/1000000 sar:0/1 sws_param:
[buffersink @ 0x10ff1fe0] auto-inserting filter 'auto-inserted scale 0' between the filter 'src' and the filter 'out'
[scale @ 0x10ff2560] w:639 h:439 fmt:gray16be -> w:639 h:439 fmt:rgb48le flags:0x4
[tiff @ 0x10ff0be0] Warning: not compiled with thread support, using thread emulation
[mjpeg @ 0x10fef3e0] Warning: not compiled with thread support, using thread emulation
Output #0, image2, to 'out.tif':
Metadata:
encoder : Lavf53.29.100
Codec 0x62 is not in the full list.
Stream #0:0: Video: tiff, rgb48le, 639x439, q=2-31, 200 kb/s, 90k tbn, 25 tbc
Stream mapping:
Stream #0:0 -> #0:0 (mjpeg -> tiff)
Press [q] to stop, [?] for help
frame= 1 fps= 0 q=0.0 Lsize= 0kB time=00:00:00.04 bitrate= 0.0kbits/s
video:1578kB audio:0kB global headers:0kB muxing overhead -100.000000%
Attachments (1)
Change History (6)
comment:1 by , 15 years ago
| Reproduced by developer: | set |
|---|---|
| Status: | new → open |
| Version: | unspecified → git-master |
comment:2 by , 15 years ago
| Keywords: | mjpeg ljpeg added |
|---|
comment:3 by , 15 years ago
| Component: | undetermined → avcodec |
|---|
by , 15 years ago
comment:5 by , 14 years ago
| Component: | avcodec → swscale |
|---|---|
| Resolution: | → fixed |
| Status: | open → closed |
Fixed in 9206ac80a5c3256738b887cf3cfe39f385ebc672.
swscale: handle last pixel if lines have an odd width.
Note:
See TracTickets
for help on using tickets.



this is actually a bug in swscale (anything to rgb48le) triggered when input have odd width
ffmpeg -i 599.png -pif_fmt rgb48le out.tif