打印

TQ6410MC 视频播放源码

[复制链接]
1781|0
手机看帖
扫描二维码
随时随地手机跟帖
跳转到指定楼层
楼主
窝里反|  楼主 | 2012-6-1 10:06 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
本次推出的是其于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);

TQ6410MC code.rar

2.97 MB

相关帖子

发新帖 我要提问
您需要登录后才可以回帖 登录 | 注册

本版积分规则

个人签名:出售嵌入式开发平台,包括samsung,TI,freescale等高端芯片平台及嵌入式平台项目定制

23

主题

71

帖子

1

粉丝