Skip to content
Snippets Groups Projects
Commit 560dde16 authored by Thomas Guillem's avatar Thomas Guillem Committed by Jean-Baptiste Kempf
Browse files

mediacodec_ndk: use NdkMediaCodec.h

For defines, enums and types, but we still have to declare our own
function prototypes since we use fonctin via dlsym.
parent 9bccd7b7
No related branches found
No related tags found
1 merge request!3056mediacodec_ndk: use NdkMediaCodec.h
Pipeline #300765 passed with warnings with stage
in 15 minutes
......@@ -32,6 +32,7 @@
#include <vlc_common.h>
#include <media/NdkMediaCodec.h>
#include <OMX_Core.h>
#include <OMX_Component.h>
#include "omxil_utils.h"
......@@ -54,33 +55,6 @@ char* MediaCodec_GetName(vlc_object_t *p_obj, const char *psz_mime,
* buffers and not via "csd-*" buffers from AMediaFormat */
#define AMEDIACODEC_FLAG_CODEC_CONFIG 2
/*****************************************************************************
* NdkMediaError.h
*****************************************************************************/
typedef enum {
AMEDIA_OK = 0,
AMEDIA_ERROR_BASE = -10000,
AMEDIA_ERROR_UNKNOWN = AMEDIA_ERROR_BASE,
AMEDIA_ERROR_MALFORMED = AMEDIA_ERROR_BASE - 1,
AMEDIA_ERROR_UNSUPPORTED = AMEDIA_ERROR_BASE - 2,
AMEDIA_ERROR_INVALID_OBJECT = AMEDIA_ERROR_BASE - 3,
AMEDIA_ERROR_INVALID_PARAMETER = AMEDIA_ERROR_BASE - 4,
AMEDIA_DRM_ERROR_BASE = -20000,
AMEDIA_DRM_NOT_PROVISIONED = AMEDIA_DRM_ERROR_BASE - 1,
AMEDIA_DRM_RESOURCE_BUSY = AMEDIA_DRM_ERROR_BASE - 2,
AMEDIA_DRM_DEVICE_REVOKED = AMEDIA_DRM_ERROR_BASE - 3,
AMEDIA_DRM_SHORT_BUFFER = AMEDIA_DRM_ERROR_BASE - 4,
AMEDIA_DRM_SESSION_NOT_OPENED = AMEDIA_DRM_ERROR_BASE - 5,
AMEDIA_DRM_TAMPER_DETECTED = AMEDIA_DRM_ERROR_BASE - 6,
AMEDIA_DRM_VERIFY_FAILED = AMEDIA_DRM_ERROR_BASE - 7,
AMEDIA_DRM_NEED_KEY = AMEDIA_DRM_ERROR_BASE - 8,
AMEDIA_DRM_LICENSE_EXPIRED = AMEDIA_DRM_ERROR_BASE - 9,
} media_status_t;
/*****************************************************************************
* NdkMediaCodec.h
*****************************************************************************/
......@@ -92,31 +66,6 @@ typedef enum {
#define off_t_compat off_t
#endif
struct AMediaCodec;
typedef struct AMediaCodec AMediaCodec;
struct AMediaCodecBufferInfo {
int32_t offset;
int32_t size;
int64_t presentationTimeUs;
uint32_t flags;
};
typedef struct AMediaCodecBufferInfo AMediaCodecBufferInfo;
enum {
AMEDIACODEC_BUFFER_FLAG_END_OF_STREAM = 4,
AMEDIACODEC_CONFIGURE_FLAG_ENCODE = 1,
AMEDIACODEC_INFO_OUTPUT_BUFFERS_CHANGED = -3,
AMEDIACODEC_INFO_OUTPUT_FORMAT_CHANGED = -2,
AMEDIACODEC_INFO_TRY_AGAIN_LATER = -1
};
struct AMediaFormat;
typedef struct AMediaFormat AMediaFormat;
struct AMediaCrypto;
typedef struct AMediaCrypto AMediaCrypto;
/*****************************************************************************
* Ndk symbols
*****************************************************************************/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment