diff options
author | Pawin Vongmasa | 2016-11-30 20:44:34 -0600 |
---|---|---|
committer | Pawin Vongmasa | 2016-11-30 22:00:57 -0600 |
commit | 26497205484ba80b41dd9df51ca190d785e92cb9 (patch) | |
tree | 4bdef6620e474cd1783e9df50ba92f81763a9364 | |
parent | 9e321eb5b6209638e1b54f281781622b256fe66e (diff) | |
download | platform-hardware-interfaces-26497205484ba80b41dd9df51ca190d785e92cb9.tar.gz platform-hardware-interfaces-26497205484ba80b41dd9df51ca190d785e92cb9.tar.xz platform-hardware-interfaces-26497205484ba80b41dd9df51ca190d785e92cb9.zip |
Make Status an enum and move it from media to media.omx.
Bug: 31399200
Test: None.
Change-Id: I28a891030f24b3d9aa2938ae61bf02b060feee05
-rw-r--r-- | media/1.0/types.hal | 1 | ||||
-rw-r--r-- | media/omx/1.0/types.hal | 17 |
2 files changed, 17 insertions, 1 deletions
diff --git a/media/1.0/types.hal b/media/1.0/types.hal index 25931f8c..98dfe147 100644 --- a/media/1.0/types.hal +++ b/media/1.0/types.hal | |||
@@ -23,7 +23,6 @@ import android.hardware.graphics.common@1.0::PixelFormat; | |||
23 | */ | 23 | */ |
24 | typedef handle FileDescriptor; // This must have no more than one fd. | 24 | typedef handle FileDescriptor; // This must have no more than one fd. |
25 | typedef FileDescriptor Fence; | 25 | typedef FileDescriptor Fence; |
26 | typedef int32_t Status; // TODO: convert to an enum | ||
27 | typedef vec<uint8_t> Bytes; | 26 | typedef vec<uint8_t> Bytes; |
28 | 27 | ||
29 | /** | 28 | /** |
diff --git a/media/omx/1.0/types.hal b/media/omx/1.0/types.hal index 418deb34..6a73346c 100644 --- a/media/omx/1.0/types.hal +++ b/media/omx/1.0/types.hal | |||
@@ -22,6 +22,23 @@ import android.hardware.media@1.0::types; | |||
22 | typedef uint32_t BufferId; | 22 | typedef uint32_t BufferId; |
23 | 23 | ||
24 | /** | 24 | /** |
25 | * Ref: system/core/include/utils/Errors.h | ||
26 | * Ref: bionic/libc/kernel/uapi/asm-generic/errno-base.h | ||
27 | * Ref: bionic/libc/kernel/uapi/asm-generic/errno.h | ||
28 | * Ref: frameworks/av/include/media/stagefright/MediaError.h | ||
29 | * Ref: frameworks/av/media/libstagefright/omx/OMXUtils.cpp: StatusFromOMXError | ||
30 | */ | ||
31 | enum Status : int32_t { | ||
32 | OK = 0, | ||
33 | NO_ERROR = 0, | ||
34 | |||
35 | NAME_NOT_FOUND = -2, | ||
36 | NO_MEMORY = -12, | ||
37 | ERROR_UNSUPPORTED = -1010, | ||
38 | UNKNOWN_ERROR = -2147483648, | ||
39 | }; | ||
40 | |||
41 | /** | ||
25 | * Ref: frameworks/av/include/media/IOMX.h: omx_message | 42 | * Ref: frameworks/av/include/media/IOMX.h: omx_message |
26 | * | 43 | * |
27 | * Data structure for an OMX message. This is essentially a union of different | 44 | * Data structure for an OMX message. This is essentially a union of different |