diff options
| author | The Android Open Source Project <initial-contribution@android.com> | 2009-02-10 15:44:00 -0800 |
|---|---|---|
| committer | The Android Open Source Project <initial-contribution@android.com> | 2009-02-10 15:44:00 -0800 |
| commit | d24b8183b93e781080b2c16c487e60d51c12da31 (patch) | |
| tree | fbb89154858984eb8e41556da7e9433040d55cd4 /include/ui/PixelFormat.h | |
| parent | f1e484acb594a726fb57ad0ae4cfe902c7f35858 (diff) | |
| download | frameworks_base-d24b8183b93e781080b2c16c487e60d51c12da31.zip frameworks_base-d24b8183b93e781080b2c16c487e60d51c12da31.tar.gz frameworks_base-d24b8183b93e781080b2c16c487e60d51c12da31.tar.bz2 | |
auto import from //branches/cupcake/...@130745
Diffstat (limited to 'include/ui/PixelFormat.h')
| -rw-r--r-- | include/ui/PixelFormat.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/include/ui/PixelFormat.h b/include/ui/PixelFormat.h index b65c959..14af823 100644 --- a/include/ui/PixelFormat.h +++ b/include/ui/PixelFormat.h @@ -71,6 +71,10 @@ enum { PIXEL_FORMAT_YCbCr_422_SP= GGL_PIXEL_FORMAT_YCbCr_422_SP, PIXEL_FORMAT_YCbCr_420_SP= GGL_PIXEL_FORMAT_YCbCr_420_SP, + PIXEL_FORMAT_YCbCr_422_P = GGL_PIXEL_FORMAT_YCbCr_422_P, + PIXEL_FORMAT_YCbCr_420_P = GGL_PIXEL_FORMAT_YCbCr_420_P, + PIXEL_FORMAT_YCbCr_422_I = GGL_PIXEL_FORMAT_YCbCr_422_I, + PIXEL_FORMAT_YCbCr_420_I = GGL_PIXEL_FORMAT_YCbCr_420_I, // New formats can be added if they're also defined in // pixelflinger/format.h @@ -80,7 +84,19 @@ typedef int32_t PixelFormat; struct PixelFormatInfo { + enum { // components + ALPHA = 1, + RGB = 2, + RGBA = 3, + LUMINANCE = 4, + LUMINANCE_ALPHA = 5, + Y_CB_CR_SP = 6, + Y_CB_CR_P = 7, + Y_CB_CR_I = 8, + }; + inline PixelFormatInfo() : version(sizeof(PixelFormatInfo)) { } + size_t getScanlineSize(unsigned int width) const; size_t version; PixelFormat format; size_t bytesPerPixel; @@ -93,7 +109,9 @@ struct PixelFormatInfo uint8_t l_green; uint8_t h_blue; uint8_t l_blue; - uint32_t reserved[2]; + uint8_t components; + uint8_t reserved0[3]; + uint32_t reserved1; }; // Consider caching the results of these functions are they're not |
