OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MEDIA_BASE_YUV_CONVERT_H_ | 5 #ifndef MEDIA_BASE_YUV_CONVERT_H_ |
6 #define MEDIA_BASE_YUV_CONVERT_H_ | 6 #define MEDIA_BASE_YUV_CONVERT_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 | 9 |
10 namespace media { | 10 namespace media { |
(...skipping 13 matching lines...) Expand all Loading... |
24 ROTATE_180, // Rotate upside down. | 24 ROTATE_180, // Rotate upside down. |
25 ROTATE_270, // Rotate counter clockwise. | 25 ROTATE_270, // Rotate counter clockwise. |
26 MIRROR_ROTATE_0, // Mirror horizontally. | 26 MIRROR_ROTATE_0, // Mirror horizontally. |
27 MIRROR_ROTATE_90, // Mirror then Rotate clockwise. | 27 MIRROR_ROTATE_90, // Mirror then Rotate clockwise. |
28 MIRROR_ROTATE_180, // Mirror vertically. | 28 MIRROR_ROTATE_180, // Mirror vertically. |
29 MIRROR_ROTATE_270, // Transpose. | 29 MIRROR_ROTATE_270, // Transpose. |
30 }; | 30 }; |
31 | 31 |
32 // Filter affects how scaling looks. | 32 // Filter affects how scaling looks. |
33 enum ScaleFilter { | 33 enum ScaleFilter { |
34 FILTER_NONE, // No filter (point sampled). | 34 FILTER_NONE = 0, // No filter (point sampled). |
35 FILTER_BILINEAR, // Bilinear filter. | 35 FILTER_BILINEAR_H = 1, // Bilinear horizontal filter. |
| 36 FILTER_BILINEAR_V = 2, // Bilinear vertical filter. |
| 37 FILTER_BILINEAR = 3, // Bilinear filter. |
36 }; | 38 }; |
37 | 39 |
38 // Convert a frame of YUV to 32 bit ARGB. | 40 // Convert a frame of YUV to 32 bit ARGB. |
39 // Pass in YV16/YV12 depending on source format | 41 // Pass in YV16/YV12 depending on source format |
40 void ConvertYUVToRGB32(const uint8* yplane, | 42 void ConvertYUVToRGB32(const uint8* yplane, |
41 const uint8* uplane, | 43 const uint8* uplane, |
42 const uint8* vplane, | 44 const uint8* vplane, |
43 uint8* rgbframe, | 45 uint8* rgbframe, |
44 int width, | 46 int width, |
45 int height, | 47 int height, |
(...skipping 15 matching lines...) Expand all Loading... |
61 int ystride, | 63 int ystride, |
62 int uvstride, | 64 int uvstride, |
63 int rgbstride, | 65 int rgbstride, |
64 YUVType yuv_type, | 66 YUVType yuv_type, |
65 Rotate view_rotate, | 67 Rotate view_rotate, |
66 ScaleFilter filter); | 68 ScaleFilter filter); |
67 | 69 |
68 } // namespace media | 70 } // namespace media |
69 | 71 |
70 #endif // MEDIA_BASE_YUV_CONVERT_H_ | 72 #endif // MEDIA_BASE_YUV_CONVERT_H_ |
OLD | NEW |