vo_example.c

来自「DawnLightPlayer,一个新的基于ffmpeg的全功能播放器」· C语言 代码 · 共 80 行

C
80
字号
/********************************************** * Dawn Light Player * *   vo_example.c * * Created by kf701 * 14:11:50 02/26/08 CST * * $Id: vo_example.c 168 2008-03-21 02:50:01Z kf701 $ **********************************************/#if ENABLE_VO_NULL#include "avcodec.h"#include "avoutput.h"#include "global.h"static pthread_mutex_t vo_mutex;static void vo_lock_init(){	pthread_mutex_init(&vo_mutex,NULL);}static void vo_lock_free(){	pthread_mutex_destroy(&vo_mutex);}static void vo_lock(){	pthread_mutex_lock(&vo_mutex);}static void vo_unlock(){	pthread_mutex_unlock(&vo_mutex);}static int vo_example_init(void){	/* ... */	vo_lock_init();	return 0;}static int vo_example_uninit(void){	vo_lock();	/* ... */	vo_lock_free();	return 0;}static void vo_example_display(AVPicture *pict){	vo_lock();	/* ... */	vo_unlock();	return;}static void vo_example_event_loop(void){	while (1)		pause();}vo_t vo_null ={	VO_ID_EXAMPLE,	"null",	vo_example_init,	vo_example_uninit,	vo_example_display,	NULL,};#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?