关键函数_数据结构.doc
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
关键函数:
truecast 项目中truecast.c:
plugin_control(void* args); av_render 项|~l: 视频插件:
av render open;
pp->set_output_list = dxa
pp_set_output_list;
pp->set_param pp->num_inputs *pp->inputs =dxa_pp_so t_param; 〃实现视频和音频信号的同步=1;
=dxa_pp_input;
pp->close
pp->qucry
pp->clear_data =av_render_c】ose;
=av_rcndcr_qucry;
二 av_render_c1ear_data;
/// -- 查询一//
// --清楚数据一 //
pp->set_output_iist = av_render_set_output_list; // -- 设置输出列表 -- //
pp->get param
10 12
pp->set_param
pp->num_inputs *pp->inputs
* (pp->inputs+l)
=av render get param:
14 16 18 20
=av_rcndcr_sct_param;
二 num_inputs;
=av_render_vinput;
= av render ainput;
/// -得到参数~//处理声音和口型同步8
/// -设置参数-- // 1 7
// 一编号输入一 //
音频插件:
pp->pclass =PP CLASS DECODER;
pp->opcn =dxa_pp_opcn;
pp->close 二 dxa_pp_close;
pp->query =dxa_pp_query; // 频参数的赋值pp->clear data =dxa pp clear data;
/// 渲染器的设置
数据结构: //ttdefine ALLOW SUB OPTIONS 1
//#include "types・h"
//#include "slrcam^plugin. h"
//#include ^truecast^player・h"
〃说你行就行不行也得行,说你不行就不行行也不行不服不行typcdcf char tc8;
typedef unsigned chtir tcu8;
typedef short tcl6;
typedef unsigned short tcul6;
typedef int tc32;
typedef unsigned int tcu32;
// --------------------------- typedef enum internalTCState (
TCTS_STOP,
TCIS_PLAY,
TC1S_P/WSE,
TCISJT,
TCTS RW
} TCTS;
//
typedef struct TrueCastStateData ( tc8 range_set,
scale_sel;
tc32 sccile;
double start_time,
end time;
} tcstdata_t;
// ----------------------------------
typedef enum {
CLOSE_CB,
OPEN CB,
STOP CB,
PLAY.CB,
PAISE_CB,
F1LCB,
RW CB,
BUEEER1NG_CB,
INFO_CB,
CB REASON SIZE
)CB REASON;
enum eTCRV
TC FILE NOT FOUND = -404,
TC^BUFFER UNDERRUN = -203, TC_BUFFER_EMPTY = -202, TC_BUF1;ER_EULL = - 201,
TC MSG TOO LARGE = -102, TC_TTMEDOUT = -101, TC_WOULDBLOCK = -100,
TC INVALID VERSION = -& TC TNPROGRESS = -7, TC_INVAL T D^STATE_CI I ANGE = -6, TC_NO_PLUGIN = -5, TC_RESOURCE_LOCKED = -4, TC_NO_MEM = -3, TC INVALID PARAMS = -2, TC_ERROR = -1, TC_OK = 0,
TC_DONE = 1
};
typedef enum eTCRV TCRV;
typedef void(*TCRequestCompleteCallback)(void* user_data, CB_REASON reason, TCRV tcrv, tcu32 flags, tc8* info);
// ----------------------------------
typedef int on2_mutcx_t;
// ------------------
// --------------
struct on2_buffer { void* buf^handlo; tc32 num_buffers;
tc8* ref count;
on2_mutex_t* mutexes;
tc8* last_complt;
};
typcdef struct on2_buffer *on2_buffcr_t;
typedef long long tc64;
typcdef enum {
PP INPUT TYPE UPDATE,
PP_INPUT_TYPE_NULLJ1PDATE,
PP INPUT TYPE PAUSED,