Changeset 1bdc212 in ffmpeg
- Timestamp:
- Dec 18, 2011, 2:04:44 AM (13 years ago)
- Branches:
- master
- Children:
- 38331d20
- Parents:
- 1a2484fc (diff), 0ea5b442 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Michael Niedermayer <michaelni@gmx.at> (12/18/11 01:23:57)
- git-committer:
- Michael Niedermayer <michaelni@gmx.at> (12/18/11 02:04:44)
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
configure
r1a2484fc r1bdc212 117 117 --enable-runtime-cpudetect detect cpu capabilities at runtime (bigger binary) 118 118 --enable-hardcoded-tables use hardcoded tables instead of runtime generation 119 --disable-safe-bitstream-reader 120 disable buffer boundary checking in bitreaders 121 (faster, but may crash) 119 122 --enable-memalign-hack emulate memalign, interferes with memory debuggers 120 123 --disable-everything disable all components listed below … … 1061 1064 rtpdec 1062 1065 runtime_cpudetect 1066 safe_bitstream_reader 1063 1067 shared 1064 1068 sinewin … … 1813 1817 enable network 1814 1818 enable optimizations 1819 enable safe_bitstream_reader 1815 1820 enable static 1816 1821 enable swscale_alpha -
libavcodec/adpcm.c
r1a2484fc r1bdc212 102 102 break; 103 103 } 104 if(avctx->channels > max_channels){ 105 return -1; 104 if (avctx->channels <= 0 || avctx->channels > max_channels) { 105 av_log(avctx, AV_LOG_ERROR, "Invalid number of channels\n"); 106 return AVERROR(EINVAL); 106 107 } 107 108 -
libavcodec/dct-test.c
r1a2484fc r1bdc212 171 171 #define AANSCALE_BITS 12 172 172 173 static uint8_t cropTbl[256 + 2 * MAX_NEG_CROP];174 175 173 static int64_t gettime(void) 176 174 { … … 557 555 ff_ref_dct_init(); 558 556 idct_mmx_init(); 559 560 for (i = 0; i < 256; i++)561 cropTbl[i + MAX_NEG_CROP] = i;562 for (i = 0; i < MAX_NEG_CROP; i++) {563 cropTbl[i] = 0;564 cropTbl[i + MAX_NEG_CROP + 256] = 255;565 }566 557 567 558 for (;;) { -
libavcodec/get_bits.h
r1a2484fc r1bdc212 28 28 29 29 #include <stdint.h> 30 #include <stdlib.h>31 #include <assert.h>32 #include "libavutil/bswap.h"33 30 #include "libavutil/common.h" 34 31 #include "libavutil/intreadwrite.h" … … 36 33 #include "mathops.h" 37 34 38 /* bit input */ 39 /* buffer, buffer_end and size_in_bits must be present and used by every reader */ 35 /* 36 * Safe bitstream reading: 37 * optionally, the get_bits API can check to ensure that we 38 * don't read past input buffer boundaries. This is protected 39 * with CONFIG_SAFE_BITSTREAM_READER at the global level, and 40 * then below that with UNCHECKED_BITSTREAM_READER at the per- 41 * decoder level. This means that decoders that check internally 42 * can "#define UNCHECKED_BITSTREAM_READER 1" to disable 43 * overread checks. 44 * Boundary checking causes a minor performance penalty so for 45 * applications that won't want/need this, it can be disabled 46 * globally using "#define CONFIG_SAFE_BITSTREAM_READER 0". 47 */ 48 #ifndef UNCHECKED_BITSTREAM_READER 49 #define UNCHECKED_BITSTREAM_READER !CONFIG_SAFE_BITSTREAM_READER 50 #endif 51 40 52 typedef struct GetBitContext { 41 53 const uint8_t *buffer, *buffer_end; 42 54 int index; 43 55 int size_in_bits; 56 int size_in_bits_plus8; 44 57 } GetBitContext; 45 58 … … 94 107 will increment the internal bit counter (see SKIP_CACHE & SKIP_BITS) 95 108 96 LAST_SKIP_CACHE(name, gb, num)97 will remove the next num bits from the cache if it is needed for UPDATE_CACHE otherwise it will do nothing98 99 109 LAST_SKIP_BITS(name, gb, num) 100 is equivalent to LAST_SKIP_CACHE; SKIP_COUNTER110 like SKIP_BITS, to be used if next call is UPDATE_CACHE or CLOSE_READER 101 111 102 112 for examples see get_bits, show_bits, skip_bits, get_vlc … … 109 119 #endif 110 120 111 # define OPEN_READER(name, gb)\121 #define OPEN_READER(name, gb) \ 112 122 unsigned int name##_index = (gb)->index; \ 113 123 av_unused unsigned int name##_cache 114 124 115 # define CLOSE_READER(name, gb) (gb)->index = name##_index 116 117 # ifdef ALT_BITSTREAM_READER_LE 125 #define CLOSE_READER(name, gb) (gb)->index = name##_index 126 127 #ifdef ALT_BITSTREAM_READER_LE 128 118 129 # ifdef LONG_BITSTREAM_READER 119 # define UPDATE_CACHE(name, gb) \120 name##_cache = AV_RL64((gb)->buffer+(name##_index>>3)) >> (name##_index&0x07)130 # define UPDATE_CACHE(name, gb) name##_cache = \ 131 AV_RL64((gb)->buffer + (name##_index >> 3)) >> (name##_index & 7) 121 132 # else 122 # define UPDATE_CACHE(name, gb) \123 name##_cache = AV_RL32((gb)->buffer+(name##_index>>3)) >> (name##_index&0x07)133 # define UPDATE_CACHE(name, gb) name##_cache = \ 134 AV_RL32((gb)->buffer + (name##_index >> 3)) >> (name##_index & 7) 124 135 # endif 125 136 126 # define SKIP_CACHE(name, gb, num) name##_cache >>= (num) 137 # define SKIP_CACHE(name, gb, num) name##_cache >>= (num) 138 139 #else 140 141 # ifdef LONG_BITSTREAM_READER 142 # define UPDATE_CACHE(name, gb) name##_cache = \ 143 AV_RB64((gb)->buffer + (name##_index >> 3)) >> (32 - (name##_index & 7)) 127 144 # else 128 # ifdef LONG_BITSTREAM_READER 129 # define UPDATE_CACHE(name, gb) \ 130 name##_cache = AV_RB64((gb)->buffer+(name##_index >> 3)) >> (32 - (name##_index & 0x07)) 131 # else 132 # define UPDATE_CACHE(name, gb) \ 133 name##_cache = AV_RB32((gb)->buffer+(name##_index>>3)) << (name##_index&0x07) 145 # define UPDATE_CACHE(name, gb) name##_cache = \ 146 AV_RB32((gb)->buffer + (name##_index >> 3)) << (name##_index & 7) 134 147 # endif 135 148 136 # define SKIP_CACHE(name, gb, num) name##_cache <<= (num) 137 # endif 138 139 // FIXME name? 149 # define SKIP_CACHE(name, gb, num) name##_cache <<= (num) 150 151 #endif 152 153 #if UNCHECKED_BITSTREAM_READER 140 154 # define SKIP_COUNTER(name, gb, num) name##_index += (num) 141 142 # define SKIP_BITS(name, gb, num) do { \ 155 #else 156 # define SKIP_COUNTER(name, gb, num) \ 157 name##_index = FFMIN((gb)->size_in_bits_plus8, name##_index + (num)) 158 #endif 159 160 #define SKIP_BITS(name, gb, num) do { \ 143 161 SKIP_CACHE(name, gb, num); \ 144 162 SKIP_COUNTER(name, gb, num); \ 145 163 } while (0) 146 164 147 # define LAST_SKIP_BITS(name, gb, num) SKIP_COUNTER(name, gb, num) 148 # define LAST_SKIP_CACHE(name, gb, num) 149 150 # ifdef ALT_BITSTREAM_READER_LE 165 #define LAST_SKIP_BITS(name, gb, num) SKIP_COUNTER(name, gb, num) 166 167 #ifdef ALT_BITSTREAM_READER_LE 151 168 # define SHOW_UBITS(name, gb, num) zero_extend(name##_cache, num) 152 153 169 # define SHOW_SBITS(name, gb, num) sign_extend(name##_cache, num) 154 # 170 #else 155 171 # define SHOW_UBITS(name, gb, num) NEG_USR32(name##_cache, num) 156 157 172 # define SHOW_SBITS(name, gb, num) NEG_SSR32(name##_cache, num) 158 # endif 159 160 # define GET_CACHE(name, gb) ((uint32_t)name##_cache) 161 162 static inline int get_bits_count(const GetBitContext *s){ 173 #endif 174 175 #define GET_CACHE(name, gb) ((uint32_t)name##_cache) 176 177 static inline int get_bits_count(const GetBitContext *s) 178 { 163 179 return s->index; 164 180 } 165 181 166 182 static inline void skip_bits_long(GetBitContext *s, int n){ 183 #if UNCHECKED_BITSTREAM_READER 167 184 s->index += n; 185 #else 186 s->index += av_clip(n, -s->index, s->size_in_bits_plus8 - s->index); 187 #endif 168 188 } 169 189 … … 172 192 * if MSB not set it is negative 173 193 * @param n length in bits 174 * @author BERO175 */ 176 static inline int get_xbits(GetBitContext *s, int n){194 */ 195 static inline int get_xbits(GetBitContext *s, int n) 196 { 177 197 register int sign; 178 198 register int32_t cache; … … 186 206 } 187 207 188 static inline int get_sbits(GetBitContext *s, int n){ 208 static inline int get_sbits(GetBitContext *s, int n) 209 { 189 210 register int tmp; 190 211 OPEN_READER(re, s); … … 199 220 * Read 1-25 bits. 200 221 */ 201 static inline unsigned int get_bits(GetBitContext *s, int n){ 222 static inline unsigned int get_bits(GetBitContext *s, int n) 223 { 202 224 register int tmp; 203 225 OPEN_READER(re, s); … … 212 234 * Show 1-25 bits. 213 235 */ 214 static inline unsigned int show_bits(GetBitContext *s, int n){ 236 static inline unsigned int show_bits(GetBitContext *s, int n) 237 { 215 238 register int tmp; 216 239 OPEN_READER(re, s); … … 220 243 } 221 244 222 static inline void skip_bits(GetBitContext *s, int n) {223 //Note gcc seems to optimize this to s->index+=n for the ALT_READER :)) 245 static inline void skip_bits(GetBitContext *s, int n) 246 { 224 247 OPEN_READER(re, s); 225 248 UPDATE_CACHE(re, s); … … 228 251 } 229 252 230 static inline unsigned int get_bits1(GetBitContext *s){ 253 static inline unsigned int get_bits1(GetBitContext *s) 254 { 231 255 unsigned int index = s->index; 232 256 uint8_t result = s->buffer[index>>3]; … … 238 262 result >>= 8 - 1; 239 263 #endif 240 index++; 264 #if !UNCHECKED_BITSTREAM_READER 265 if (s->index < s->size_in_bits_plus8) 266 #endif 267 index++; 241 268 s->index = index; 242 269 … … 244 271 } 245 272 246 static inline unsigned int show_bits1(GetBitContext *s){ 273 static inline unsigned int show_bits1(GetBitContext *s) 274 { 247 275 return show_bits(s, 1); 248 276 } 249 277 250 static inline void skip_bits1(GetBitContext *s){ 278 static inline void skip_bits1(GetBitContext *s) 279 { 251 280 skip_bits(s, 1); 252 281 } … … 255 284 * Read 0-32 bits. 256 285 */ 257 static inline unsigned int get_bits_long(GetBitContext *s, int n){ 258 if (n <= MIN_CACHE_BITS) return get_bits(s, n); 286 static inline unsigned int get_bits_long(GetBitContext *s, int n) 287 { 288 if (n <= MIN_CACHE_BITS) 289 return get_bits(s, n); 259 290 else { 260 291 #ifdef ALT_BITSTREAM_READER_LE … … 271 302 * Read 0-32 bits as a signed integer. 272 303 */ 273 static inline int get_sbits_long(GetBitContext *s, int n) { 304 static inline int get_sbits_long(GetBitContext *s, int n) 305 { 274 306 return sign_extend(get_bits_long(s, n), n); 275 307 } … … 278 310 * Show 0-32 bits. 279 311 */ 280 static inline unsigned int show_bits_long(GetBitContext *s, int n){ 281 if (n <= MIN_CACHE_BITS) return show_bits(s, n); 312 static inline unsigned int show_bits_long(GetBitContext *s, int n) 313 { 314 if (n <= MIN_CACHE_BITS) 315 return show_bits(s, n); 282 316 else { 283 317 GetBitContext gb = *s; … … 300 334 * because some optimized bitstream readers read 32 or 64 bit at once and could read over the end 301 335 * @param bit_size the size of the buffer in bits 302 * 303 * While GetBitContext stores the buffer size, for performance reasons you are 304 * responsible for checking for the buffer end yourself (take advantage of the padding)! 305 */ 306 static inline void init_get_bits(GetBitContext *s, 307 const uint8_t *buffer, int bit_size) 336 */ 337 static inline void init_get_bits(GetBitContext *s, const uint8_t *buffer, 338 int bit_size) 308 339 { 309 340 int buffer_size = (bit_size+7)>>3; … … 315 346 s->buffer = buffer; 316 347 s->size_in_bits = bit_size; 348 s->size_in_bits_plus8 = bit_size + 8; 317 349 s->buffer_end = buffer + buffer_size; 318 350 s->index = 0; … … 356 388 * is undefined. 357 389 */ 358 #define GET_VLC(code, name, gb, table, bits, max_depth) do { \ 390 #define GET_VLC(code, name, gb, table, bits, max_depth) \ 391 do { \ 359 392 int n, nb_bits; \ 360 393 unsigned int index; \ … … 387 420 } while (0) 388 421 389 #define GET_RL_VLC(level, run, name, gb, table, bits, max_depth, need_update) do { \ 422 #define GET_RL_VLC(level, run, name, gb, table, bits, max_depth, need_update) \ 423 do { \ 390 424 int n, nb_bits; \ 391 425 unsigned int index; \ … … 413 447 414 448 /** 415 * Parse a vlc code , faster than get_vlc().449 * Parse a vlc code. 416 450 * @param bits is the number of bits which will be read at once, must be 417 451 * identical to nb_bits in init_vlc() … … 421 455 */ 422 456 static av_always_inline int get_vlc2(GetBitContext *s, VLC_TYPE (*table)[2], 423 int bits, int max_depth)457 int bits, int max_depth) 424 458 { 425 459 int code; … … 434 468 } 435 469 436 static inline int decode012(GetBitContext *gb){ 470 static inline int decode012(GetBitContext *gb) 471 { 437 472 int n; 438 473 n = get_bits1(gb); … … 443 478 } 444 479 445 static inline int decode210(GetBitContext *gb){ 480 static inline int decode210(GetBitContext *gb) 481 { 446 482 if (get_bits1(gb)) 447 483 return 0; … … 458 494 459 495 #ifdef TRACE 460 static inline void print_bin(int bits, int n){ 496 static inline void print_bin(int bits, int n) 497 { 461 498 int i; 462 499 … … 469 506 470 507 static inline int get_bits_trace(GetBitContext *s, int n, char *file, 471 const char *func, int line){ 508 const char *func, int line) 509 { 472 510 int r = get_bits(s, n); 473 511 … … 479 517 static inline int get_vlc_trace(GetBitContext *s, VLC_TYPE (*table)[2], 480 518 int bits, int max_depth, char *file, 481 const char *func, int line){ 519 const char *func, int line) 520 { 482 521 int show = show_bits(s, 24); 483 522 int pos = get_bits_count(s); … … 493 532 } 494 533 static inline int get_xbits_trace(GetBitContext *s, int n, char *file, 495 const char *func, int line){ 534 const char *func, int line) 535 { 496 536 int show = show_bits(s, n); 497 537 int r = get_xbits(s, n); -
libavcodec/mpeg4videodec.c
r1a2484fc r1bdc212 931 931 932 932 last= SHOW_UBITS(re, &s->gb, 1); SKIP_CACHE(re, &s->gb, 1); 933 run= SHOW_UBITS(re, &s->gb, 6); LAST_SKIP_CACHE(re, &s->gb, 6);933 run= SHOW_UBITS(re, &s->gb, 6); 934 934 SKIP_COUNTER(re, &s->gb, 1+1+6); 935 935 UPDATE_CACHE(re, &s->gb); … … 948 948 949 949 level= level * qmul + qadd; 950 level = (level ^ SHOW_SBITS(re, &s->gb, 1)) - SHOW_SBITS(re, &s->gb, 1); LAST_SKIP_CACHE(re, &s->gb, 1);950 level = (level ^ SHOW_SBITS(re, &s->gb, 1)) - SHOW_SBITS(re, &s->gb, 1); 951 951 SKIP_COUNTER(re, &s->gb, 1+11+5+1); 952 952 … … 965 965 SKIP_CACHE(re, &s->gb, 2); 966 966 last= SHOW_UBITS(re, &s->gb, 1); SKIP_CACHE(re, &s->gb, 1); 967 run= SHOW_UBITS(re, &s->gb, 6); LAST_SKIP_CACHE(re, &s->gb, 6);967 run= SHOW_UBITS(re, &s->gb, 6); 968 968 SKIP_COUNTER(re, &s->gb, 2+1+6); 969 969 UPDATE_CACHE(re, &s->gb); … … 982 982 av_log(s->avctx, AV_LOG_ERROR, "2. marker bit missing in 3. esc\n"); 983 983 return -1; 984 } ; LAST_SKIP_CACHE(re, &s->gb, 1);984 } 985 985 986 986 SKIP_COUNTER(re, &s->gb, 1+12+1); -
libavcodec/mpegaudiodec.c
r1a2484fc r1bdc212 24 24 * MPEG Audio decoder 25 25 */ 26 27 #define UNCHECKED_BITSTREAM_READER 1 26 28 27 29 #include "libavutil/audioconvert.h" … … 1435 1437 s->in_gb = s->gb; 1436 1438 init_get_bits(&s->gb, s->last_buf, s->last_buf_size*8); 1439 #if CONFIG_SAFE_BITSTREAM_READER 1440 s->gb.size_in_bits_plus8 += EXTRABYTES * 8; 1441 #endif 1437 1442 skip_bits_long(&s->gb, 8*(s->last_buf_size - main_data_begin)); 1438 1443 } -
libavcodec/msmpeg4.c
r1a2484fc r1bdc212 1692 1692 last= SHOW_UBITS(re, &s->gb, 1); SKIP_CACHE(re, &s->gb, 1); 1693 1693 run= SHOW_UBITS(re, &s->gb, 6); SKIP_CACHE(re, &s->gb, 6); 1694 level= SHOW_SBITS(re, &s->gb, 8); LAST_SKIP_CACHE(re, &s->gb, 8);1694 level= SHOW_SBITS(re, &s->gb, 8); 1695 1695 SKIP_COUNTER(re, &s->gb, 1+6+8); 1696 1696 }else{ -
libavcodec/wmavoice.c
r1a2484fc r1bdc212 25 25 * @author Ronald S. Bultje <rsbultje@gmail.com> 26 26 */ 27 28 #define UNCHECKED_BITSTREAM_READER 1 27 29 28 30 #include <math.h> -
library.mak
r1a2484fc r1bdc212 98 98 99 99 $(EXAMPLES) $(TESTPROGS) $(TOOLS): $(THIS_LIB) $(DEP_LIBS) 100 $(TESTPROGS): $(SUBDIR)$(LIBNAME) 100 101 101 102 examples: $(EXAMPLES) -
libswscale/swscale.c
r1a2484fc r1bdc212 484 484 for (i = 0; i < (dstW >> 1); i++) { 485 485 int j; 486 int Y1 = 1 << 14;487 int Y2 = 1 << 14;486 int Y1 = (1 << 14) - 0x40000000; 487 int Y2 = (1 << 14) - 0x40000000; 488 488 489 489 for (j = 0; j < lumFilterSize; j++) { … … 493 493 Y1 >>= 15; 494 494 Y2 >>= 15; 495 if ((Y1 | Y2) & 0x10000) { 496 Y1 = av_clip_uint16(Y1); 497 Y2 = av_clip_uint16(Y2); 498 } 499 output_pixel(&dest[i * 2 + 0], Y1); 500 output_pixel(&dest[i * 2 + 1], Y2); 495 Y1 = av_clip_int16(Y1); 496 Y2 = av_clip_int16(Y2); 497 output_pixel(&dest[i * 2 + 0], 0x8000 + Y1); 498 output_pixel(&dest[i * 2 + 1], 0x8000 + Y2); 501 499 } 502 500 } … … 852 850 for (i = 0; i < (dstW >> 1); i++) { 853 851 int j; 854 int Y1 = 0;855 int Y2 = 0;852 int Y1 = -0x40000000; 853 int Y2 = -0x40000000; 856 854 int U = -128 << 23; // 19 857 855 int V = -128 << 23; … … 869 867 // 8bit: 12+15=27; 16-bit: 12+19=31 870 868 Y1 >>= 14; // 10 869 Y1 += 0x10000; 871 870 Y2 >>= 14; 871 Y2 += 0x10000; 872 872 U >>= 14; 873 873 V >>= 14; … … 1016 1016 1017 1017 static av_always_inline void 1018 yuv2rgb_write(uint8_t *_dest, int i, int Y1, intY2,1019 int U, int V, int A1, intA2,1018 yuv2rgb_write(uint8_t *_dest, int i, unsigned Y1, unsigned Y2, 1019 unsigned U, unsigned V, unsigned A1, unsigned A2, 1020 1020 const void *_r, const void *_g, const void *_b, int y, 1021 1021 enum PixelFormat target, int hasAlpha) … … 1554 1554 int rsh, int gsh, int bsh, int S) 1555 1555 { 1556 const int ry = RY << rsh, gy = GY << gsh, by = BY << bsh ,1557 1556 const int ry = RY << rsh, gy = GY << gsh, by = BY << bsh; 1557 const unsigned rnd = (32<<((S)-1)) + (1<<(S-7)); 1558 1558 int i; 1559 1559 … … 1577 1577 { 1578 1578 const int ru = RU << rsh, gu = GU << gsh, bu = BU << bsh, 1579 rv = RV << rsh, gv = GV << gsh, bv = BV << bsh ,1580 rnd = (256<<((S)-1)) + (1<<(S-7));1579 rv = RV << rsh, gv = GV << gsh, bv = BV << bsh; 1580 const unsigned rnd = (256u<<((S)-1)) + (1<<(S-7)); 1581 1581 int i; 1582 1582 … … 1602 1602 const int ru = RU << rsh, gu = GU << gsh, bu = BU << bsh, 1603 1603 rv = RV << rsh, gv = GV << gsh, bv = BV << bsh, 1604 rnd = (256U<<(S)) + (1<<(S-6)), maskgx = ~(maskr | maskb); 1604 maskgx = ~(maskr | maskb); 1605 const unsigned rnd = (256U<<(S)) + (1<<(S-6)); 1605 1606 int i; 1606 1607 -
libswscale/swscale_unscaled.c
r1a2484fc r1bdc212 668 668 } 669 669 670 671 #define IS_DIFFERENT_ENDIANESS(src_fmt, dst_fmt, pix_fmt) \ 672 ((src_fmt == pix_fmt ## BE && dst_fmt == pix_fmt ## LE) || \ 673 (src_fmt == pix_fmt ## LE && dst_fmt == pix_fmt ## BE)) 674 675 670 676 void ff_get_unscaled_swscale(SwsContext *c) 671 677 { … … 697 703 if (srcFormat==PIX_FMT_BGR24 && (dstFormat==PIX_FMT_YUV420P || dstFormat==PIX_FMT_YUVA420P) && !(flags & SWS_ACCURATE_RND)) 698 704 c->swScale= bgr24ToYv12Wrapper; 699 700 /* bswap 16 bits per component packed formats */701 if ((srcFormat == PIX_FMT_RGB48LE && dstFormat == PIX_FMT_RGB48BE) ||702 (srcFormat == PIX_FMT_RGB48BE && dstFormat == PIX_FMT_RGB48LE) ||703 (srcFormat == PIX_FMT_BGR48LE && dstFormat == PIX_FMT_BGR48BE) ||704 (srcFormat == PIX_FMT_BGR48BE && dstFormat == PIX_FMT_BGR48LE) ||705 (srcFormat == PIX_FMT_GRAY16LE && dstFormat == PIX_FMT_GRAY16BE) ||706 (srcFormat == PIX_FMT_GRAY16BE && dstFormat == PIX_FMT_GRAY16LE))707 c->swScale = packed_16bpc_bswap;708 705 709 706 /* RGB/BGR -> RGB/BGR (no dither needed forms) */ … … 735 732 if (isAnyRGB(srcFormat) && isPlanar(srcFormat) && isByteRGB(dstFormat)) 736 733 c->swScale= planarRgbToRgbWrapper; 734 735 /* bswap 16 bits per pixel/component packed formats */ 736 if (IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_BGR444) || 737 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_BGR48) || 738 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_BGR555) || 739 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_BGR565) || 740 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_GRAY16) || 741 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_RGB444) || 742 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_RGB48) || 743 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_RGB555) || 744 IS_DIFFERENT_ENDIANESS(srcFormat, dstFormat, PIX_FMT_RGB565)) 745 c->swScale = packed_16bpc_bswap; 737 746 738 747 if (usePal(srcFormat) && isByteRGB(dstFormat)) -
tests/fate.mak
r1a2484fc r1bdc212 90 90 fate-ea-tgv-ima-ea-sead: CMD = framecrc -i $(SAMPLES)/ea-tgv/INTEL_S.TGV -pix_fmt rgb24 91 91 FATE_TESTS += fate-ea-tqi-adpcm 92 fate-ea-tqi-adpcm: CMD = framecrc -i $(SAMPLES)/ea-wve/networkBackbone-partial.wve 92 fate-ea-tqi-adpcm: CMD = framecrc -i $(SAMPLES)/ea-wve/networkBackbone-partial.wve -frames:v 26 93 93 FATE_TESTS += fate-ea-vp60 94 94 fate-ea-vp60: CMD = framecrc -i $(SAMPLES)/ea-vp6/g36.vp6 -
tests/ref/fate/ea-tqi-adpcm
r1a2484fc r1bdc212 50 50 1, 144000, 5936, 0x2174304d 51 51 0, 150000, 115200, 0x0c256424 52 0, 156000, 115200, 0xa9cdd8d2
Note:
See TracChangeset
for help on using the changeset viewer.