| 
 | 
 
 本帖最后由 非也 于 2013-3-27 17:09 编辑  
 
   本次推出的是其于TQ6410的硬件mfc解码播放器源码,同时集成了mplayer作为后端播放,可播放wmv,avi,mp4,h264,m4v,rcv等格式的视频文件。         
    天嵌科技自行封装MFC编码,解码库,提供API接口供用户调用。 
    TQ6410的硬件编码和解码功能相当强大,天嵌科技会陆续推出完全自主开发的QT4应用程序源码,请大家多多关注! 
   “授人以鱼不如授人以渔”,天嵌科技本着负责任的态度教大家如何使用和开发,助您翱翔于嵌入式的天空! 
- typedef enum
 
 - {
 
 -         _M4V, _H264,_VC1
 
 - } video_type;
 
  
- typedef enum
 
 - {
 
 -         _DATA, _FILE
 
 - } decode_type;
 
 - /*
 
 -  * 函数名:mfc_encoder_init
 
 -  * 功能:编码初始化
 
 -  * 参数:
 
 -  * width[in]://视频宽
 
 -  * height[in]://视频高
 
 -  * frame_rate[in]://帧率
 
 -  * bitrate[in]://帧率
 
 -  * gop_num[in]://帧率
 
 -  * 返回:mfc编码句柄
 
 -  */
 
 - void *mfc_encoder_init(int width, int height, int frame_rate, int bitrate,
 
 -                 int gop_num);
 
 - /*
 
 -  * 函数名:mfc_encoder_exe
 
 -  * 功能:编码
 
 -  * 参数:
 
 -  * handle[in]://编码句柄
 
 -  * dataBuf[in]://要编码的数据
 
 -  * length[in]://数据长度
 
 -  * first_frame[in]://是否第一帧
 
 -  * size[out]://编码后长度
 
 -  * 返回:编码后数据
 
 -  */
 
 - void *mfc_encoder_exe(void *handle, unsigned char *data, int length,
 
 -                 int first_frame, long *size);
 
 - /*
 
 -  * 函数名:mfc_encoder_free
 
 -  * 功能:编码结束
 
 -  * 参数:
 
 -  * handle[in]://编码句柄
 
 -  * 返回:无
 
 -  */
 
 - void mfc_encoder_free(void *handle);
 
 - /*
 
 -  * 函数名:mfc_decoder_init
 
 -  * 功能:解码初始化
 
 -  * 参数:
 
 -  * decode_buf[in]://编码句柄或文件名
 
 -  * decode_size[in]://数据长度
 
 -  * index[out]://当前帧用的长度
 
 -  * type[in]://解码类型,_FILE文件,_DATA数据
 
 -  * width[out]://视频宽度
 
 -  * height[out]://视频高度
 
 -  * 返回:成功:编码句柄;失败:NULL
 
 -  */
 
 - void *mfc_decoder_init(unsigned char *decode_buf, int decode_size, int *index,
 
 -                 decode_type d_type, video_type v_type, int *width, int *height);
 
 - /*
 
 -  * 函数名:mfc_decoder_exe
 
 -  * 功能:解码
 
 -  * 参数:
 
 -  * handle[in]://编码句柄
 
 -  * decode_buf[in]://待解码数据
 
 -  * size[in]://待解码数据的长度
 
 -  * index[out]://当前帧用的长度
 
 -  * 返回:成功:yuv420数据;失败:NULL
 
 -  */
 
 - void * mfc_decoder_exe(void * handle, unsigned char *decode_buf, int size,
 
 -                 int *index);
 
 - /*
 
 -  * 函数名:mfc_decoder_free
 
 -  * 功能:关闭解码句柄
 
 -  * 参数:
 
 -  * handle[in]://编码句柄
 
 -  * 返回:无
 
 -  */
 
 - void mfc_decoder_free(void *handle);
 
  复制代码    为了活跃论坛,以后所发源码均需要支付金币,多劳多得,不劳不得,论坛的发展依赖于每一位会员的共同努力! 
    请大家积极回复其他朋友的问题以获取金币。 
 
 
    我们一直在努力做的更好!请大家回复后下载,感谢您对天嵌科技的支持! 
 
 
 |   
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?注册  
 
×
 
 
 
 
 |