diff options
author | Jamie Gennis <jgennis@google.com> | 2011-11-21 16:50:49 -0800 |
---|---|---|
committer | Jamie Gennis <jgennis@google.com> | 2011-11-21 17:45:29 -0800 |
commit | 29ead941b377cb87bcc7fe48208b96d84d649d43 (patch) | |
tree | ff73e2af9973ecd0826d4c1ba27a80f2c6116e44 /include/hardware/gralloc.h | |
parent | fb410365ca67d36d4c81d7826712c6a05437612f (diff) | |
download | hardware_libhardware-29ead941b377cb87bcc7fe48208b96d84d649d43.zip hardware_libhardware-29ead941b377cb87bcc7fe48208b96d84d649d43.tar.gz hardware_libhardware-29ead941b377cb87bcc7fe48208b96d84d649d43.tar.bz2 |
Gralloc: add a usage bit for video encoding
This change adds a new Gralloc usage bit to indicate that a buffer will
be passed to the HW video encoder.
Change-Id: I75c3fc514906e5b18fb60345a2d9c5a606403633
Diffstat (limited to 'include/hardware/gralloc.h')
-rw-r--r-- | include/hardware/gralloc.h | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/include/hardware/gralloc.h b/include/hardware/gralloc.h index 9daad1c..f8beb5e 100644 --- a/include/hardware/gralloc.h +++ b/include/hardware/gralloc.h @@ -47,40 +47,42 @@ __BEGIN_DECLS enum { /* buffer is never read in software */ - GRALLOC_USAGE_SW_READ_NEVER = 0x00000000, + GRALLOC_USAGE_SW_READ_NEVER = 0x00000000, /* buffer is rarely read in software */ - GRALLOC_USAGE_SW_READ_RARELY = 0x00000002, + GRALLOC_USAGE_SW_READ_RARELY = 0x00000002, /* buffer is often read in software */ - GRALLOC_USAGE_SW_READ_OFTEN = 0x00000003, + GRALLOC_USAGE_SW_READ_OFTEN = 0x00000003, /* mask for the software read values */ - GRALLOC_USAGE_SW_READ_MASK = 0x0000000F, + GRALLOC_USAGE_SW_READ_MASK = 0x0000000F, /* buffer is never written in software */ - GRALLOC_USAGE_SW_WRITE_NEVER = 0x00000000, + GRALLOC_USAGE_SW_WRITE_NEVER = 0x00000000, /* buffer is never written in software */ - GRALLOC_USAGE_SW_WRITE_RARELY = 0x00000020, + GRALLOC_USAGE_SW_WRITE_RARELY = 0x00000020, /* buffer is never written in software */ - GRALLOC_USAGE_SW_WRITE_OFTEN = 0x00000030, + GRALLOC_USAGE_SW_WRITE_OFTEN = 0x00000030, /* mask for the software write values */ - GRALLOC_USAGE_SW_WRITE_MASK = 0x000000F0, + GRALLOC_USAGE_SW_WRITE_MASK = 0x000000F0, /* buffer will be used as an OpenGL ES texture */ - GRALLOC_USAGE_HW_TEXTURE = 0x00000100, + GRALLOC_USAGE_HW_TEXTURE = 0x00000100, /* buffer will be used as an OpenGL ES render target */ - GRALLOC_USAGE_HW_RENDER = 0x00000200, + GRALLOC_USAGE_HW_RENDER = 0x00000200, /* buffer will be used by the 2D hardware blitter */ - GRALLOC_USAGE_HW_2D = 0x00000400, + GRALLOC_USAGE_HW_2D = 0x00000400, /* buffer will be used by the HWComposer HAL module */ - GRALLOC_USAGE_HW_COMPOSER = 0x00000800, + GRALLOC_USAGE_HW_COMPOSER = 0x00000800, /* buffer will be used with the framebuffer device */ - GRALLOC_USAGE_HW_FB = 0x00001000, + GRALLOC_USAGE_HW_FB = 0x00001000, + /* buffer will be used with the HW video encoder */ + GRALLOC_USAGE_HW_VIDEO_ENCODER = 0x00010000, /* mask for the software usage bit-mask */ - GRALLOC_USAGE_HW_MASK = 0x00001F00, + GRALLOC_USAGE_HW_MASK = 0x00011F00, /* buffer should be displayed full-screen on an external display when * possible */ - GRALLOC_USAGE_EXTERNAL_DISP = 0x00002000, + GRALLOC_USAGE_EXTERNAL_DISP = 0x00002000, /* Must have a hardware-protected path to external display sink for * this buffer. If a hardware-protected path is not available, then @@ -88,14 +90,14 @@ enum { * external sink, or (less desirable) do not route the entire * composition to the external sink. */ - GRALLOC_USAGE_PROTECTED = 0x00004000, + GRALLOC_USAGE_PROTECTED = 0x00004000, /* implementation-specific private usage flags */ - GRALLOC_USAGE_PRIVATE_0 = 0x10000000, - GRALLOC_USAGE_PRIVATE_1 = 0x20000000, - GRALLOC_USAGE_PRIVATE_2 = 0x40000000, - GRALLOC_USAGE_PRIVATE_3 = 0x80000000, - GRALLOC_USAGE_PRIVATE_MASK = 0xF0000000, + GRALLOC_USAGE_PRIVATE_0 = 0x10000000, + GRALLOC_USAGE_PRIVATE_1 = 0x20000000, + GRALLOC_USAGE_PRIVATE_2 = 0x40000000, + GRALLOC_USAGE_PRIVATE_3 = 0x80000000, + GRALLOC_USAGE_PRIVATE_MASK = 0xF0000000, }; /*****************************************************************************/ |