Michael Niedermayer
c49fa2a514
avcodec/dds: Fix runtime error: left shift of 145 by 24 places cannot be represented in type 'int'
...
Fixes: 1891/clusterfuzz-testcase-minimized-6274417925554176
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-29 13:51:42 +02:00
Michael Niedermayer
afb4632cc3
avcodec/dds: Fix runtime error: left shift of 210 by 24 places cannot be represented in type 'int'
...
Fixes: 1510/clusterfuzz-testcase-minimized-5826231746428928
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-13 01:40:43 +02:00
Michael Niedermayer
8a8335de03
avcodec/dds: Fix runtime error: left shift of 1 by 31 places cannot be represented in type 'int'
...
Fixes: 1380/clusterfuzz-testcase-minimized-650122545122508
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-06 23:23:39 +02:00
Clément Bœsch
67e370ee52
lavc: fix usages of av_get_codec_tag_string()
2017-03-29 14:49:29 +02:00
Andreas Cadhalpun
90ebf3c428
dds: limit 4 bpp handling to AV_PIX_FMT_PAL8
...
This fixes NULL pointer dereferencing for formats, where frame->data[1]
is not allocated.
The problem was introduced in commit
257fbc3af4
.
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-11-16 19:29:45 +01:00
Paul B Mahol
257fbc3af4
avcodec/dds: add support for 4bpp format
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2016-09-21 13:40:04 +02:00
Clément Bœsch
f36fcf7b6c
Merge commit '4b2e69397b84d1c1a29ffae6e9f106f2c32b1869'
...
* commit '4b2e69397b84d1c1a29ffae6e9f106f2c32b1869':
dds: Add support for monochrome images
Merged-by: Clément Bœsch <clement@stupeflix.com>
2016-06-21 12:29:46 +02:00
Derek Buitenhuis
d62984d8a0
Merge commit '22e49e6edead9c83696f20127988f659b952ce65'
...
* commit '22e49e6edead9c83696f20127988f659b952ce65':
dds: Simplify postprocessing check
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-05-08 23:50:09 +01:00
Derek Buitenhuis
6ebec1049e
Merge commit '02538636261fdec9c70f4185b23147c636f269b4'
...
* commit '02538636261fdec9c70f4185b23147c636f269b4':
dds: Add support for alpha-only files
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-05-08 23:49:26 +01:00
Derek Buitenhuis
6c00703685
Merge commit '9a9fb710bcf4657e030467cfe2556cb0e2c01afc'
...
* commit '9a9fb710bcf4657e030467cfe2556cb0e2c01afc':
dds: Add support for rgb555 files
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-05-08 23:49:04 +01:00
Vittorio Giovara
4b2e69397b
dds: Add support for monochrome images
2016-04-26 16:30:18 -04:00
Vittorio Giovara
6eb2505855
dds: Drop gray-alpha swapping
...
The original sample was generated with invalid software.
2016-04-26 16:30:04 -04:00
Carl Eugen Hoyos
139cbeb75e
lavc/dds: Fix GRAY8A decoding.
...
Fixes ticket #4667 .
2016-04-15 21:06:34 +02:00
Vittorio Giovara
22e49e6ede
dds: Simplify postprocessing check
2016-04-06 12:13:50 -04:00
Vittorio Giovara
0253863626
dds: Add support for alpha-only files
...
Due to how pixel format conversion is done, they behave the same way
as gray files.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-04-06 12:13:49 -04:00
Vittorio Giovara
9a9fb710bc
dds: Add support for rgb555 files
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-04-06 12:13:47 -04:00
Ganesh Ajjanagadde
5979c740f5
lavc/dds: replace rint by lrint
...
avoids float to int cast.
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-12-26 20:29:22 -08:00
Andreas Cadhalpun
603ebab8d7
dds: disable palette flag for compressed dds
...
Having both is not valid and can cause a NULL pointer dereference of
frame->data[1] later.
Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-14 21:52:11 +01:00
Andreas Cadhalpun
0a8bff788b
dds: disable palette flag for compressed images
...
Having both is not valid and can cause a NULL pointer dereference of
frame->data[1] later.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-11-14 03:40:20 +01:00
Andreas Cadhalpun
7b2211bfc4
dds: add missing newline to log messages
...
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-12 04:39:14 +01:00
Andreas Cadhalpun
29b1752861
dds: validate compressed source buffer size
...
A too small buffer will cause segfaults somewhere below
decompress_texture_thread.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-12 04:39:14 +01:00
Andreas Cadhalpun
e6459c655e
dds: validate source buffer size before copying
...
If it is too small av_image_copy_plane segfaults.
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-12 04:39:14 +01:00
Andreas Cadhalpun
edd0c1d78a
dds: add missing newline to log messages
...
Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-11 21:49:51 +01:00
Andreas Cadhalpun
9a37d47644
dds: validate compressed source buffer size
...
A too small buffer will cause segfaults somewhere below
decompress_texture_thread.
Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-11 21:49:51 +01:00
Andreas Cadhalpun
1675809d2d
dds: validate source buffer size before copying
...
If it is too small av_image_copy_plane segfaults.
Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-11-11 21:49:51 +01:00
Michael Niedermayer
444e9874a7
Merge commit 'def97856de6021965db86c25a732d78689bd6bb0'
...
* commit 'def97856de6021965db86c25a732d78689bd6bb0':
lavc: AV-prefix all codec capabilities
Conflicts:
cmdutils.c
ffmpeg.c
ffplay.c
libavcodec/8svx.c
libavcodec/aacenc.c
libavcodec/ac3dec.c
libavcodec/adpcm.c
libavcodec/alac.c
libavcodec/atrac3plusdec.c
libavcodec/bink.c
libavcodec/dnxhddec.c
libavcodec/dvdec.c
libavcodec/dvenc.c
libavcodec/ffv1dec.c
libavcodec/ffv1enc.c
libavcodec/fic.c
libavcodec/flacdec.c
libavcodec/flacenc.c
libavcodec/flvdec.c
libavcodec/fraps.c
libavcodec/frwu.c
libavcodec/gifdec.c
libavcodec/h261dec.c
libavcodec/hevc.c
libavcodec/iff.c
libavcodec/imc.c
libavcodec/libopenjpegdec.c
libavcodec/libvo-aacenc.c
libavcodec/libvorbisenc.c
libavcodec/libvpxdec.c
libavcodec/libvpxenc.c
libavcodec/libx264.c
libavcodec/mjpegbdec.c
libavcodec/mjpegdec.c
libavcodec/mpegaudiodec_float.c
libavcodec/msmpeg4dec.c
libavcodec/mxpegdec.c
libavcodec/nvenc_h264.c
libavcodec/nvenc_hevc.c
libavcodec/pngdec.c
libavcodec/qpeg.c
libavcodec/ra288.c
libavcodec/rv10.c
libavcodec/s302m.c
libavcodec/sp5xdec.c
libavcodec/takdec.c
libavcodec/tiff.c
libavcodec/tta.c
libavcodec/utils.c
libavcodec/v210dec.c
libavcodec/vp6.c
libavcodec/vp9.c
libavcodec/wavpack.c
libavcodec/yop.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:50:18 +02:00
Vittorio Giovara
def97856de
lavc: AV-prefix all codec capabilities
...
Express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:58 +01:00
Martin Storsjö
44f7df0c98
dds: Write the palette in the native endian form
...
This fixes the palette on big endian, broken (or, differing from
little endian) since 57214b2f7
.
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-07-23 19:07:43 +03:00
Tom Butterworth
ebe8b5d947
dds: Fix the slice size computation
...
A bug was introduced in 6b2b26e7af
whereby when
frame height wasn't divisible by the number of threads, pixels would be omitted
from the bottom rows during decode.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-07-23 10:45:40 +02:00
Michael Niedermayer
157fa73992
Merge commit 'ebe8b5d947c41449c684f17c6826fe6bc46c0360'
...
* commit 'ebe8b5d947c41449c684f17c6826fe6bc46c0360':
dds: Fix the slice size computation
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-23 12:20:53 +02:00
Michael Niedermayer
eaf15bba03
Merge commit 'ea4d46e72945cba37feb7aa154eb970732f513e4'
...
* commit 'ea4d46e72945cba37feb7aa154eb970732f513e4':
dds: Fix enum declaration
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-22 17:14:24 +02:00
Michael Niedermayer
d08d8b61aa
dds: Fix 32bpp bitmaps decoding
...
Found-By: ami_stuff
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-22 13:35:44 +01:00
Vittorio Giovara
57214b2f7f
dds: Fix palette decoding
...
Red and blue channels were decoded in the wrong order.
Found-By: ami_stuff
2015-07-22 13:35:44 +01:00
Vittorio Giovara
ea4d46e729
dds: Fix enum declaration
...
Drop the global variables with anonymous enum type.
2015-07-22 13:35:43 +01:00
Michael Niedermayer
8fe00dd18a
Merge commit '6b2b26e7af3ede0abfb46eb5725c26d1083f50bc'
...
* commit '6b2b26e7af3ede0abfb46eb5725c26d1083f50bc':
dds: Decode using optimal slices sizes
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-21 20:35:59 +02:00
Luca Barbato
6b2b26e7af
dds: Decode using optimal slices sizes
...
Enjoy some cache locality and use less threads.
About the same speedup provided to HAP.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-07-21 12:14:25 +02:00
Michael Niedermayer
5c583b1419
avcodec/dds: Flip more R<->B cases
...
Fixes Ticket4665
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-20 00:03:11 +02:00
Michael Niedermayer
36a87c2dc7
avcodec/dds: fix paletted files
...
Fixes Ticket4664
The changed fate tests lack red/blue shades and thus look correct
either way
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-19 23:26:59 +02:00
Luca Barbato
4d55484391
dds: Fix palette mode on big endian
...
Found-By: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-06-24 14:45:16 +01:00
Michael Niedermayer
21d2e3d602
avcodec/dds: Fix palettes on big endian
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-22 23:59:28 +02:00
Michael Niedermayer
ff68b83968
Merge commit '5c018ee18895f88e9e1d2174059dcdd48bf872d2'
...
* commit '5c018ee18895f88e9e1d2174059dcdd48bf872d2':
DirectDraw Surface image decoder
Conflicts:
Changelog
configure
doc/general.texi
libavcodec/Makefile
libavcodec/version.h
tests/fate/image.mak
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-22 23:34:56 +02:00
Vittorio Giovara
5c018ee188
DirectDraw Surface image decoder
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-06-22 15:23:08 +01:00