OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The LibYuv Project Authors. All rights reserved. | 2 * Copyright 2012 The LibYuv Project Authors. All rights reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #include "libyuv/mjpeg_decoder.h" | 11 #include "libyuv/mjpeg_decoder.h" |
12 | 12 |
13 #ifdef HAVE_JPEG | 13 #ifdef HAVE_JPEG |
14 #include <assert.h> | 14 #include <assert.h> |
15 | 15 |
16 #if !defined(__pnacl__) && !defined(__CLR_VER) && \ | 16 #if !defined(__pnacl__) && !defined(__CLR_VER) && \ |
17 !defined(COVERAGE_ENABLED) && !defined(TARGET_IPHONE_SIMULATOR) | 17 !defined(COVERAGE_ENABLED) && !defined(TARGET_IPHONE_SIMULATOR) |
18 // Must be included before jpeglib. | 18 // Must be included before jpeglib. |
19 #include <setjmp.h> | 19 #include <setjmp.h> |
20 #define HAVE_SETJMP | 20 #define HAVE_SETJMP |
| 21 |
| 22 #if defined(_MSC_VER) |
| 23 // disable warning 4324: structure was padded due to __declspec(align()) |
| 24 #pragma warning(disable:4324) |
| 25 #endif |
| 26 |
21 #endif | 27 #endif |
22 struct FILE; // For jpeglib.h. | 28 struct FILE; // For jpeglib.h. |
23 | 29 |
24 // C++ build requires extern C for jpeg internals. | 30 // C++ build requires extern C for jpeg internals. |
25 #ifdef __cplusplus | 31 #ifdef __cplusplus |
26 extern "C" { | 32 extern "C" { |
27 #endif | 33 #endif |
28 | 34 |
29 #include <jpeglib.h> | 35 #include <jpeglib.h> |
30 | 36 |
(...skipping 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
557 if (subsample_x[0] == 1 && subsample_y[0] == 1) { | 563 if (subsample_x[0] == 1 && subsample_y[0] == 1) { |
558 return kJpegYuv400; | 564 return kJpegYuv400; |
559 } | 565 } |
560 } | 566 } |
561 return kJpegUnknown; | 567 return kJpegUnknown; |
562 } | 568 } |
563 | 569 |
564 } // namespace libyuv | 570 } // namespace libyuv |
565 #endif // HAVE_JPEG | 571 #endif // HAVE_JPEG |
566 | 572 |
OLD | NEW |