MC_OUT_OF_MEMORY = -20, /**< when memory is not allocated */
} mc_ret_e;
+typedef enum {
+ NONE,
+ L16,
+ ALAW,
+ ULAW,
+ AMR_NB,
+ AMR_WB,
+ G729,
+ AAC_LC,
+ AAC_HE,
+ AAC_HE_PS,
+ MP3,
+ VORBIS,
+ FLAC,
+ WMAV1,
+ WMAV2,
+ WMAPRO,
+ WMALSL,
+ H261,
+ H263,
+ H264,
+ MJPEG,
+ MPEG1,
+ MPEG2,
+ MPEG4,
+ HEVC,
+ VP8,
+ VP9,
+ VC1,
+ CODEC_NR_ITEMS
+} codec_type_e;
+
/*---------------------------------------------------------------------------
| GLOBAL DATA TYPE DEFINITIONS: |
---------------------------------------------------------------------------*/
bool is_hw;
bool is_prepared;
- GList *supported_codecs;
mediacodec_port_type_e port_type;
mediacodec_codec_type_e codec_id;
mc_vendor_e vendor;
mc_codec_map_t encoder_map[MEDIA_CODEC_MAX_CODEC_TYPE];
mc_codec_map_t decoder_map[MEDIA_CODEC_MAX_CODEC_TYPE];
- int num_supported_codecs;
int num_supported_decoder;
int num_supported_encoder;
- mc_ini_t ini;
+ mc_ini_t *ini;
};
/*===========================================================================================
int mc_set_buffer_status_cb(MMHandleType mediacodec, mediacodec_buffer_status_cb callback, void* user_data);
int mc_unset_buffer_status_cb(MMHandleType mediacodec);
int mc_set_supported_codec_cb(MMHandleType mediacodec, mediacodec_supported_codec_cb callback, void* user_data);
-int _mediacodec_foreach_supported_codec(MMHandleType mediacodec, mediacodec_supported_codec_cb callback, void* user_data);
+int _mediacodec_foreach_supported_codec(mediacodec_supported_codec_cb callback, void* user_data);
void _mc_create_codec_map_from_ini(mc_handle_t *mc_handle, mc_codec_spec_t *spec_emul);
+void _mc_create_codec_map_from_ini_static(mc_ini_t *ini, mc_codec_spec_t *spec_emul);
void _mc_create_decoder_map_from_ini(mc_handle_t *mc_handle);
void _mc_create_encoder_map_from_ini(mc_handle_t *mc_handle);
+const int simple_to_codec_type_enumeration(codec_type_e codec_id);
+const int codec_type_to_simple_enumeration(mediacodec_codec_type_e media_codec_id);
+
#ifdef __cplusplus
}
#endif