Mercurial > mplayer.hg
changeset 16171:fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
return values can be negative (VO_ERROR, VO_NOTAVAIL and VO_NOTIMPL), so it's
changed to int now.
line wrap: on
line diff
--- a/libvo/mga_common.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/mga_common.c Fri Aug 05 01:24:37 2005 +0000 @@ -102,7 +102,7 @@ } -static uint32_t +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { @@ -135,7 +135,7 @@ } -static uint32_t +static int draw_frame(uint8_t *src[]) { printf("!!! mga::draw_frame() called !!!\n"); @@ -195,7 +195,7 @@ return VO_TRUE; } -static uint32_t +static int query_format(uint32_t format) { switch(format){ @@ -229,7 +229,7 @@ printf( "Error in mga_vid_config ioctl (wrong mga_vid.o version?)" ); } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT: @@ -418,7 +418,7 @@ return 0; } -static uint32_t preinit(const char *vo_subdevice) +static int preinit(const char *vo_subdevice) { const char *devname=vo_subdevice?vo_subdevice:"/dev/mga_vid"; sws_rgb2rgb_init(get_sws_cpuflags());
--- a/libvo/video_out.h Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/video_out.h Fri Aug 05 01:24:37 2005 +0000 @@ -105,7 +105,7 @@ * arg - currently it's vo_subdevice * returns: zero on successful initialization, non-zero on error. */ - uint32_t (*preinit)(const char *arg); + int (*preinit)(const char *arg); /* * Initialize (means CONFIGURE) the display driver. * params: @@ -116,21 +116,21 @@ * format: fourcc of pixel format * returns : zero on successful initialization, non-zero on error. */ - uint32_t (*config)(uint32_t width, uint32_t height, uint32_t d_width, + int (*config)(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t fullscreen, char *title, uint32_t format); /* * Control interface */ - uint32_t (*control)(uint32_t request, void *data, ...); + int (*control)(uint32_t request, void *data, ...); /* * Display a new RGB/BGR frame of the video to the screen. * params: * src[0] - pointer to the image */ - uint32_t (*draw_frame)(uint8_t *src[]); + int (*draw_frame)(uint8_t *src[]); /* * Draw a planar YUV slice to the buffer: @@ -140,7 +140,7 @@ * w,h = width*height of area to be copied (in Y pixels) * x,y = position at the destination image (in Y pixels) */ - uint32_t (*draw_slice)(uint8_t *src[], int stride[], int w,int h, int x,int y); + int (*draw_slice)(uint8_t *src[], int stride[], int w,int h, int x,int y); /* * Draws OSD to the screen buffer
--- a/libvo/video_out_internal.h Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/video_out_internal.h Fri Aug 05 01:24:37 2005 +0000 @@ -26,18 +26,18 @@ #include "libmpcodecs/mp_image.h" #include "geometry.h" -static uint32_t control(uint32_t request, void *data, ...); -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int control(uint32_t request, void *data, ...); +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t fullscreen, char *title, uint32_t format); -static uint32_t draw_frame(uint8_t *src[]); -static uint32_t draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y); +static int draw_frame(uint8_t *src[]); +static int draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y); static void draw_osd(void); static void flip_page(void); static void check_events(void); static void uninit(void); -static uint32_t query_format(uint32_t format); -static uint32_t preinit(const char *); +static int query_format(uint32_t format); +static int preinit(const char *); #define LIBVO_EXTERN(x) vo_functions_t video_out_##x =\ {\
--- a/libvo/vo_3dfx.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_3dfx.c Fri Aug 05 01:24:37 2005 +0000 @@ -304,7 +304,7 @@ targetoffset = vidpage0offset + (dispy*screenwidth + dispx)*screendepth; } -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t fullscreen, char *title, uint32_t format) { int fd; @@ -414,7 +414,7 @@ return 0; } -static uint32_t +static int draw_frame(uint8_t *src[]) { LOG("video_out_3dfx: starting display_frame\n"); @@ -427,7 +427,7 @@ return 0; } -static uint32_t +static int //draw_slice(uint8_t *src[], uint32_t slice_num) draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { @@ -452,7 +452,7 @@ screen_to_screen_stretch_blt(targetoffset, vidpage2offset, dispwidth, dispheight); } -static uint32_t +static int query_format(uint32_t format) { /* does this supports scaling? up & down? */ @@ -476,7 +476,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { @@ -486,7 +486,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_aa.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_aa.c Fri Aug 05 01:24:37 2005 +0000 @@ -227,7 +227,7 @@ osdpercent(1,1,0,255,vo_osd_progbar_value, __sub_osd_names[vo_osd_progbar_type], ""); } } -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -314,7 +314,7 @@ return 0; } -static uint32_t +static int query_format(uint32_t format) { /* * ...are we able to... ? @@ -343,7 +343,7 @@ return 0; } -static uint32_t +static int draw_frame(uint8_t *src[]) { int stride[3] = { 0 , 0 , 0 }; @@ -372,7 +372,7 @@ return 0; } -static uint32_t +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { @@ -679,7 +679,7 @@ return retval; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { char * hidis = NULL; struct stat sbuf; @@ -744,7 +744,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_bl.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_bl.c Fri Aug 05 01:24:37 2005 +0000 @@ -213,7 +213,7 @@ &bml_init, &bml_write_frame, &bml_close, &udp_init, &udp_send, &udp_close } }; -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { void * ptr; @@ -293,11 +293,11 @@ return; } -static uint32_t draw_frame(uint8_t * src[]) { +static int draw_frame(uint8_t * src[]) { return 0; } -static uint32_t query_format(uint32_t format) { +static int query_format(uint32_t format) { if (format == bl->img_format) return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW; return 0; @@ -320,7 +320,7 @@ static void check_events(void) { } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], +static int draw_slice(uint8_t *srcimg[], int stride[], int wf, int hf, int xf, int yf) { int i, j, w, h, x, y; uint8_t *dst; @@ -339,7 +339,7 @@ return 0; } -static uint32_t preinit(const char *arg) { +static int preinit(const char *arg) { char *p, *q; int end = 0, i; char txt[256]; @@ -465,7 +465,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) { +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data));
--- a/libvo/vo_caca.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_caca.c Fri Aug 05 01:24:37 2005 +0000 @@ -136,7 +136,7 @@ return 0; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { image_height = height; @@ -149,13 +149,13 @@ return resize (); } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { caca_draw_bitmap(0, 0, screen_w, screen_h, cbitmap, src[0]); return 0; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { return 0; } @@ -284,7 +284,7 @@ #endif } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if (arg) { @@ -307,7 +307,7 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (format == IMGFMT_BGR24) return @@ -319,7 +319,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch(request) {
--- a/libvo/vo_cvidix.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_cvidix.c Fri Aug 05 01:24:37 2005 +0000 @@ -75,7 +75,7 @@ return 0; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width,uint32_t d_height, uint32_t flags, char *title, uint32_t format){ +static int config(uint32_t width, uint32_t height, uint32_t d_width,uint32_t d_height, uint32_t flags, char *title, uint32_t format){ vo_fs = flags & VOFLAG_FULLSCREEN; if(!vo_config_count){ if(vo_screenwidth && vo_screenheight){ @@ -116,7 +116,7 @@ return; } -static uint32_t draw_slice(uint8_t *src[], int stride[],int w, int h, int x, int y){ +static int draw_slice(uint8_t *src[], int stride[],int w, int h, int x, int y){ UNUSED(src); UNUSED(stride); UNUSED(w); @@ -127,13 +127,13 @@ return -1; } -static uint32_t draw_frame(uint8_t *src[]){ +static int draw_frame(uint8_t *src[]){ UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, "vo_cvidix: error: didn't use vidix draw_frame!\n"); return -1; } -static uint32_t query_format(uint32_t format){ +static int query_format(uint32_t format){ return(vidix_query_fourcc(format)); } @@ -146,7 +146,7 @@ } } -static uint32_t preinit(const char *arg){ +static int preinit(const char *arg){ if(arg)vidix_name = strdup(arg); else { mp_msg(MSGT_VO, MSGL_INFO, "vo_cvidix: No vidix driver name provided, probing available ones (-v option for details)!\n"); @@ -156,7 +156,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...){ +static int control(uint32_t request, void *data, ...){ switch (request) { case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data));
--- a/libvo/vo_dfbmga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_dfbmga.c Fri Aug 05 01:24:37 2005 +0000 @@ -226,7 +226,7 @@ static void uninit( void ); -static uint32_t +static int preinit( const char *arg ) { DFBResult res; @@ -544,7 +544,7 @@ bufs[2] = NULL; } -static uint32_t +static int config( uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, @@ -856,7 +856,7 @@ return 0; } -static uint32_t +static int query_format( uint32_t format ) { switch (format) { @@ -996,13 +996,13 @@ subframe->Unlock( subframe ); } -static uint32_t +static int draw_frame( uint8_t * src[] ) { return -1; } -static uint32_t +static int draw_slice( uint8_t * src[], int stride[], int w, int h, int x, int y ) { void *dst; @@ -1343,7 +1343,7 @@ return VO_TRUE; } -static uint32_t +static int control( uint32_t request, void *data, ... ) { switch (request) {
--- a/libvo/vo_dga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_dga.c Fri Aug 05 01:24:37 2005 +0000 @@ -283,7 +283,7 @@ //--------------------------------------------------------- -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { int vp_skip = vo_dga_vp_skip; @@ -352,7 +352,7 @@ //--------------------------------------------------------- -static uint32_t draw_slice(uint8_t * src[], int stride[], +static int draw_slice(uint8_t * src[], int stride[], int w, int h, int x, int y) { return 0; @@ -360,7 +360,7 @@ //--------------------------------------------------------- -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if ((format & IMGFMT_BGR_MASK) == IMGFMT_BGR && @@ -516,7 +516,7 @@ } } -static uint32_t config(uint32_t width, uint32_t height, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -863,7 +863,7 @@ static int dga_depths_init = 0; -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if (arg) { @@ -974,7 +974,7 @@ return (VO_FALSE); } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_directfb2.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_directfb2.c Fri Aug 05 01:24:37 2005 +0000 @@ -169,7 +169,7 @@ return get_mode(arg) != 0; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { DFBResult ret; strarg_t mode_str = {0, NULL}; @@ -408,7 +408,7 @@ return DFENUM_OK; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { int ret = VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW|VFCAP_OSD; // osd should be removed in future -> will be handled outside... enum1_t params; @@ -484,7 +484,7 @@ #define CONFIG_ERROR -1 -static uint32_t config(uint32_t s_width, uint32_t s_height, uint32_t d_width, +static int config(uint32_t s_width, uint32_t s_height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -1206,7 +1206,7 @@ return VO_FALSE; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { int i; unsigned int pitch; @@ -1416,7 +1416,7 @@ -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT: @@ -1453,7 +1453,7 @@ // unused function -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { return -1; }
--- a/libvo/vo_directx.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_directx.c Fri Aug 05 01:24:37 2005 +0000 @@ -185,7 +185,7 @@ vo_draw_text(image_width,image_height,draw_alpha); } -static uint32_t +static int query_format(uint32_t format) { uint32_t i=0; @@ -1004,7 +1004,7 @@ } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { HINSTANCE hInstance = GetModuleHandle(NULL); char exedir[MAX_PATH]; @@ -1070,7 +1070,7 @@ return 0; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y ) +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y ) { uint8_t *s; uint8_t *d; @@ -1142,7 +1142,7 @@ image = ddsdsf.lpSurface; } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { memcpy( image, *src, dstride * image_height ); return 0; @@ -1244,7 +1244,7 @@ return VO_TRUE; } -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t options, char *title, uint32_t format) { RECT rd; @@ -1444,7 +1444,7 @@ return r; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_dxr2.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_dxr2.c Fri Aug 05 01:24:37 2005 +0000 @@ -647,7 +647,7 @@ } -static uint32_t config(uint32_t s_width, uint32_t s_height, uint32_t width, uint32_t height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t s_width, uint32_t s_height, uint32_t width, uint32_t height, uint32_t flags, char *title, uint32_t format) { int arg; dxr2_threeArg_t arg3; @@ -879,7 +879,7 @@ } } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { vo_mpegpes_t *p=(vo_mpegpes_t *)src[0]; if(p->id == 0x1E0) {// Video @@ -895,13 +895,13 @@ sub_vo->flip_page(); } -static uint32_t draw_slice( uint8_t *srcimg[], int stride[], int w, int h, int x0, int y0 ) +static int draw_slice( uint8_t *srcimg[], int stride[], int w, int h, int x0, int y0 ) { return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (format==IMGFMT_MPEGPES) return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW|VFCAP_TIMER|VFCAP_SPU; @@ -951,7 +951,7 @@ #endif } -static uint32_t preinit(const char *arg) { +static int preinit(const char *arg) { int uCodeFD = -1; int uCodeSize; dxr2_uCode_t* uCode; @@ -1052,7 +1052,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_dxr3.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_dxr3.c Fri Aug 05 01:24:37 2005 +0000 @@ -270,7 +270,7 @@ /* Functions for working with the em8300's internal clock */ /* End of internal clock functions */ -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_GUISUPPORT: @@ -418,7 +418,7 @@ } } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int tmp1, tmp2, size; em8300_register_t reg; @@ -751,7 +751,7 @@ } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { vo_mpegpes_t *p = (vo_mpegpes_t *) src[0]; @@ -812,7 +812,7 @@ } } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], int w, int h, int x0, int y0) +static int draw_slice(uint8_t *srcimg[], int stride[], int w, int h, int x0, int y0) { return -1; } @@ -864,7 +864,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { char devname[MAX_STR_SIZE]; int fdflags = O_WRONLY;
--- a/libvo/vo_fbdev.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_fbdev.c Fri Aug 05 01:24:37 2005 +0000 @@ -792,7 +792,7 @@ } } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -1030,7 +1030,7 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (!fb_preinit(0)) return 0; @@ -1057,9 +1057,9 @@ (*draw_alpha_p)(w, h, src, srca, stride, dst, fb_line_len); } -static uint32_t draw_frame(uint8_t *src[]) { return 1; } +static int draw_frame(uint8_t *src[]) { return 1; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, int x, +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { uint8_t *d; @@ -1120,7 +1120,7 @@ fb_preinit(1); } -static uint32_t preinit(const char *vo_subdevice) +static int preinit(const char *vo_subdevice) { pre_init_err = 0; @@ -1161,7 +1161,7 @@ return(VO_TRUE); } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_GET_IMAGE:
--- a/libvo/vo_fbdev2.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_fbdev2.c Fri Aug 05 01:24:37 2005 +0000 @@ -193,7 +193,7 @@ return -1; } -static uint32_t preinit(const char *subdevice) +static int preinit(const char *subdevice) { if (subdevice) { @@ -203,7 +203,7 @@ return fb_preinit(0); } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -293,7 +293,7 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { // open the device, etc. if (fb_preinit(0)) return 0; @@ -337,9 +337,9 @@ } // all csp support stride -static uint32_t draw_frame(uint8_t *src[]) { return 1; } +static int draw_frame(uint8_t *src[]) { return 1; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { uint8_t *in = src[0]; #ifdef USE_CONVERT2FB @@ -396,7 +396,7 @@ fb_preinit(1); // so that later calls to preinit don't fail } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_ggi.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_ggi.c Fri Aug 05 01:24:37 2005 +0000 @@ -131,7 +131,7 @@ return; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { ggi_mode mode = { @@ -320,7 +320,7 @@ } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { ggiPutBox(ggi_conf.vis, 0, 0, ggi_conf.dstwidth, ggi_conf.dstheight, src[0]); @@ -346,7 +346,7 @@ ggi_conf.flushregion.y1 = ggi_conf.flushregion.y2 = -1; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { ggiPutBox(ggi_conf.vis, x, y, w, h, src[0]); @@ -363,7 +363,7 @@ return(1); } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { ggi_mode mode; uint32_t vfcap; @@ -399,7 +399,7 @@ return(0); } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if (ggiInit() != 0) { @@ -471,7 +471,7 @@ ggiExit(); } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch(request) {
--- a/libvo/vo_gif89a.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_gif89a.c Fri Aug 05 01:24:37 2005 +0000 @@ -106,7 +106,7 @@ // the default output filename #define DEFAULT_FILE "out.gif" -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { float fps; if (verbose) printf("GIF89a: Preinit entered\n"); @@ -164,7 +164,7 @@ return 0; } -static uint32_t config(uint32_t s_width, uint32_t s_height, uint32_t d_width, +static int config(uint32_t s_width, uint32_t s_height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -322,12 +322,12 @@ EGifPutLine(new_gif, reduce_data, img_width * img_height); } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { return 1; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { uint8_t *dst, *frm; int i; @@ -341,14 +341,14 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (format == IMGFMT_RGB24) return VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW | VFCAP_TIMER | VFCAP_ACCEPT_STRIDE; return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { if (request == VOCTRL_QUERY_FORMAT) { return query_format(*((uint32_t*)data));
--- a/libvo/vo_gl.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_gl.c Fri Aug 05 01:24:37 2005 +0000 @@ -159,7 +159,7 @@ /* connect to server, create and map window, * allocate colors and (shared) memory */ -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int tmp; @@ -453,7 +453,7 @@ } //static inline uint32_t draw_slice_x11(uint8_t *src[], uint32_t slice_num) -static uint32_t draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { return 0; } @@ -508,13 +508,13 @@ return VO_TRUE; } -static uint32_t +static int draw_frame(uint8_t *src[]) { return VO_ERROR; } -static uint32_t +static int query_format(uint32_t format) { int caps = VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW | @@ -552,7 +552,7 @@ {NULL} }; -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { // set defaults many_fmts = 1; @@ -596,7 +596,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_PAUSE: return (int_pause=1);
--- a/libvo/vo_gl2.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_gl2.c Fri Aug 05 01:24:37 2005 +0000 @@ -824,7 +824,7 @@ /* connect to server, create and map window, * allocate colors and (shared) memory */ -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { const unsigned char * glVersion; @@ -993,7 +993,7 @@ } //static inline uint32_t draw_slice_x11(uint8_t *src[], uint32_t slice_num) -static uint32_t draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { return 0; } @@ -1021,7 +1021,7 @@ } -static uint32_t +static int draw_frame(uint8_t *src[]) { uint32_t res = 0; @@ -1034,7 +1034,7 @@ return res; } -static uint32_t +static int query_format(uint32_t format) { switch(format){ @@ -1068,7 +1068,7 @@ #endif } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { @@ -1079,7 +1079,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_PAUSE: return (int_pause=1);
--- a/libvo/vo_jpeg.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_jpeg.c Fri Aug 05 01:24:37 2005 +0000 @@ -143,7 +143,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -217,7 +217,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { static int framecounter = 0, subdircounter = 0; char buf[BUFLENGTH]; @@ -264,7 +264,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { return 0; @@ -272,7 +272,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (format == IMGFMT_RGB24) { return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW; @@ -313,7 +313,7 @@ return 0; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { opt_t subopts[] = { {"progressive", OPT_ARG_BOOL, &jpeg_progressive_mode, NULL, 0}, @@ -377,7 +377,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_macosx.m Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_macosx.m Fri Aug 05 01:24:37 2005 +0000 @@ -84,7 +84,7 @@ } } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int i; @@ -154,14 +154,14 @@ [mpGLView render]; } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { [mpGLView setCurrentTexture]; return 0; } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { switch (image_format) { @@ -178,7 +178,7 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { image_format = format; @@ -204,7 +204,7 @@ [autoreleasepool release]; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int parse_err = 0; @@ -260,7 +260,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_md5sum.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_md5sum.c Fri Aug 05 01:24:37 2005 +0000 @@ -101,7 +101,7 @@ * \return 0 All went well. */ -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { opt_t subopts[] = { {"outfile", OPT_ARG_MSTRZ, &md5sum_outfile, NULL, 0}, @@ -135,7 +135,7 @@ * \return 0 All went well. */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -180,7 +180,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { mp_msg(MSGT_VO, MSGL_V, "%s: draw_frame() is called!\n", info.short_name); return -1; @@ -238,7 +238,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { return 0; @@ -246,7 +246,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { switch (format) { case IMGFMT_RGB24: @@ -259,7 +259,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_mga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_mga.c Fri Aug 05 01:24:37 2005 +0000 @@ -34,7 +34,7 @@ #define FBDEV "/dev/fb0" -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { // if (f >= 0) mga_uninit();
--- a/libvo/vo_mpegpes.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_mpegpes.c Fri Aug 05 01:24:37 2005 +0000 @@ -80,7 +80,7 @@ LIBVO_EXTERN (mpegpes) -static uint32_t +static int config(uint32_t s_width, uint32_t s_height, uint32_t width, uint32_t height, uint32_t flags, char *title, uint32_t format) { #ifdef HAVE_DVB @@ -98,7 +98,7 @@ return 0; } -static uint32_t preinit(const char *arg){ +static int preinit(const char *arg){ #ifdef HAVE_DVB int card = 0; char vo_file[30], ao_file[30], *tmp; @@ -348,7 +348,7 @@ } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { vo_mpegpes_t *p=(vo_mpegpes_t *)src[0]; send_pes_packet(p->data,p->size,p->id,(p->timestamp>0)?p->timestamp:vo_pts); // video data @@ -359,13 +359,13 @@ { } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x0,int y0) +static int draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x0,int y0) { return 0; } -static uint32_t +static int query_format(uint32_t format) { if(format==IMGFMT_MPEGPES) return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW|VFCAP_TIMER; @@ -385,7 +385,7 @@ { } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_null.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_null.c Fri Aug 05 01:24:37 2005 +0000 @@ -42,7 +42,7 @@ static uint32_t image_width, image_height; //static uint32_t -static uint32_t draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) //draw_slice(uint8_t *src[], uint32_t slice_num) { return 0; @@ -57,19 +57,19 @@ { } -static uint32_t +static int draw_frame(uint8_t *src[]) { return 0; } -static uint32_t +static int query_format(uint32_t format) { return VFCAP_CSP_SUPPORTED; } -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { image_width = width; @@ -87,7 +87,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { @@ -97,7 +97,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_png.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_png.c Fri Aug 05 01:24:37 2005 +0000 @@ -40,7 +40,7 @@ enum {OK,ERROR} status; }; -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -174,17 +174,17 @@ static void flip_page (void){} -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { return -1; } -static uint32_t draw_slice( uint8_t *src[],int stride[],int w,int h,int x,int y ) +static int draw_slice( uint8_t *src[],int stride[],int w,int h,int x,int y ) { return -1; } -static uint32_t +static int query_format(uint32_t format) { switch(format){ @@ -211,7 +211,7 @@ {NULL} }; -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { z_compression = 0; if (subopt_parse(arg, subopts) != 0) { @@ -220,7 +220,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_DRAW_IMAGE:
--- a/libvo/vo_pnm.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_pnm.c Fri Aug 05 01:24:37 2005 +0000 @@ -116,7 +116,7 @@ * \return 0 All went well. */ -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int ppm_type = 0, pgm_type = 0, pgmyuv_type = 0, raw_mode = 0, ascii_mode = 0; @@ -256,7 +256,7 @@ * \return 0 All went well. */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -507,7 +507,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { mp_msg(MSGT_VO, MSGL_V, "%s: draw_frame() is called!\n", info.short_name); return -1; @@ -515,7 +515,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t draw_slice(uint8_t *src[], int stride[], int w, int h, +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { return 0; @@ -523,7 +523,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { /* Ensure that for PPM we get Packed RGB and for PGM(YUV) we get * Planar YUV */ @@ -542,7 +542,7 @@ /* ------------------------------------------------------------------------- */ -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_quartz.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_quartz.c Fri Aug 05 01:24:37 2005 +0000 @@ -600,7 +600,7 @@ InstallWindowEventHandler (theWindow, NewEventHandlerUPP (WindowEventHandler), GetEventTypeCount(win_events), win_events, theWindow, NULL); } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { WindowAttributes windowAttrs; OSErr qterr; @@ -1003,7 +1003,7 @@ } } -static uint32_t draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { switch (image_format) { @@ -1027,7 +1027,7 @@ return -1; } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { switch (image_format) { @@ -1043,7 +1043,7 @@ return -1; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { image_format = format; image_qtcodec = 0; @@ -1103,7 +1103,7 @@ ShowMenuBar(); } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int parse_err = 0; @@ -1219,7 +1219,7 @@ return VO_FALSE; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_sdl.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_sdl.c Fri Aug 05 01:24:37 2005 +0000 @@ -780,7 +780,7 @@ * returns : non-zero on success, zero on error. **/ -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) //static int sdl_setup (int width, int height) { @@ -1034,7 +1034,7 @@ **/ //static int sdl_draw_frame (frame_t *frame) -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { struct sdl_priv_s *priv = &sdl_priv; uint8_t *dst; @@ -1110,7 +1110,7 @@ **/ //static uint32_t draw_slice(uint8_t *src[], uint32_t slice_num) -static uint32_t draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) { struct sdl_priv_s *priv = &sdl_priv; uint8_t *dst; @@ -1538,7 +1538,7 @@ } } -static uint32_t +static int query_format(uint32_t format) { switch(format){ @@ -1585,7 +1585,7 @@ } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { struct sdl_priv_s *priv = &sdl_priv; char * sdl_driver = NULL; @@ -1699,7 +1699,7 @@ return VO_FALSE; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { struct sdl_priv_s *priv = &sdl_priv; switch (request) {
--- a/libvo/vo_svga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_svga.c Fri Aug 05 01:24:37 2005 +0000 @@ -119,7 +119,7 @@ return -1; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int i; char s[64]; @@ -351,7 +351,7 @@ return bestmode; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT: @@ -398,7 +398,7 @@ // // This function is called to init the video driver for specific mode // -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int32_t req_w = width;// (d_width > 0 ? d_width : width); @@ -578,7 +578,7 @@ return (0); } -static uint32_t draw_slice(uint8_t *image[],int stride[], +static int draw_slice(uint8_t *image[],int stride[], int w, int h, int x, int y) { assert(0); UNUSED(image);UNUSED(stride); @@ -588,7 +588,7 @@ return VO_ERROR;//this is yv12 only -> vf_scale should do all transforms } -static uint32_t draw_frame(uint8_t *src[]) { +static int draw_frame(uint8_t *src[]) { assert(0); UNUSED(src); return VO_ERROR;//this one should not be called @@ -648,7 +648,7 @@ } /* --------------------------------------------------------------------- */ -static uint32_t query_format(uint32_t format) { +static int query_format(uint32_t format) { int32_t req_bpp,flags; int i,lastmode; vga_modeinfo * vminfo;
--- a/libvo/vo_syncfb.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_syncfb.c Fri Aug 05 01:24:37 2005 +0000 @@ -249,7 +249,7 @@ } //static uint32_t draw_slice(uint8_t *src[], uint32_t slice_num) -static uint32_t +static int draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) { @@ -320,7 +320,7 @@ } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { printf("DRAW FRAME!!!\n"); if ( conf_palette == VIDEO_PALETTE_YUV422 ) { @@ -335,7 +335,7 @@ return 0; } -static uint32_t +static int query_format(uint32_t format) { switch(format){ @@ -347,7 +347,7 @@ return 0; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { uint_32 frame_size; @@ -443,7 +443,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { @@ -453,7 +453,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_tdfx_vid.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_tdfx_vid.c Fri Aug 05 01:24:37 2005 +0000 @@ -95,7 +95,7 @@ } -static uint32_t draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) { uint8_t* ptr[3]; @@ -201,14 +201,14 @@ printf("tdfx_vid: Blit failed\n"); } -static uint32_t +static int draw_frame(uint8_t *src[]) { int stride[] = { src_stride, 0, 0}; return draw_slice(src,stride,src_width, src_height,0,0); } -static uint32_t +static int query_format(uint32_t format) { switch(format) { @@ -231,7 +231,7 @@ return 0; } -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -383,7 +383,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { tdfx_fd = open(arg ? arg : "/dev/tdfx_vid", O_RDWR); @@ -645,7 +645,7 @@ return VO_TRUE; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_tdfxfb.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_tdfxfb.c Fri Aug 05 01:24:37 2005 +0000 @@ -81,7 +81,7 @@ static struct YUV_plane *YUV; static void (*alpha_func)(), (*alpha_func_double)(); -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { char *name; @@ -210,7 +210,7 @@ clear_screen(); } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { screenwidth = fb_vinfo.xres; @@ -412,13 +412,13 @@ reg_IO->vidDesktopStartAddr = vidpageoffset; } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { mem2agpcpy(inpage, src[0], in_width * in_depth * in_height); return 0; } -static uint32_t draw_slice(uint8_t *i[], int s[], int w, int h, int x, int y) +static int draw_slice(uint8_t *i[], int s[], int w, int h, int x, int y) { /* We want to render to the YUV to the input page + the location * of the stripes we're doing */ @@ -477,7 +477,7 @@ return VO_TRUE; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch(request) { case VOCTRL_GET_IMAGE:
--- a/libvo/vo_tga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_tga.c Fri Aug 05 01:24:37 2005 +0000 @@ -178,7 +178,7 @@ return VO_TRUE; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { /* buffer for alpha */ if(line_buff){ free(line_buff); line_buff=NULL; } @@ -197,17 +197,17 @@ return; } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x,int y) { return -1; } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { return -1; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { switch(format){ case IMGFMT_BGR|15: @@ -227,7 +227,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { printf("vo_tga: Unknown subdevice: %s\n",arg); @@ -236,7 +236,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_DRAW_IMAGE:
--- a/libvo/vo_vesa.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_vesa.c Fri Aug 05 01:24:37 2005 +0000 @@ -275,7 +275,7 @@ } /* is called for yuv only */ -static uint32_t draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *image[], int stride[], int w,int h,int x,int y) { int dstride=HAS_DGA()?video_mode_info.XResolution:dstW; uint8_t *dst[3]= {dga_buffer, NULL, NULL}; @@ -410,7 +410,7 @@ } /* is called for rgb only */ -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { if(verbose > 2) printf("vo_vesa: draw_frame was called\n"); @@ -461,7 +461,7 @@ return flags; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if(verbose > 2) printf("vo_vesa: query_format was called: %x (%s)\n",format,vo_format_name(format)); @@ -614,7 +614,7 @@ * bit 3 (0x08) enables flipping (-flip) (NK: and for what?) */ -static uint32_t +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { struct VbeInfoBlock vib; @@ -1056,7 +1056,7 @@ /* Nothing to do */ } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int pre_init_err = 0; int fd; @@ -1085,7 +1085,7 @@ return pre_init_err; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_winvidix.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_winvidix.c Fri Aug 05 01:24:37 2005 +0000 @@ -181,7 +181,7 @@ } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width,uint32_t d_height, uint32_t flags, char *title, uint32_t format){ +static int config(uint32_t width, uint32_t height, uint32_t d_width,uint32_t d_height, uint32_t flags, char *title, uint32_t format){ title = "MPlayer VIDIX WIN32 Overlay"; panscan_init(); @@ -281,7 +281,7 @@ return; } -static uint32_t draw_slice(uint8_t *src[], int stride[],int w, int h, int x, int y){ +static int draw_slice(uint8_t *src[], int stride[],int w, int h, int x, int y){ UNUSED(src); UNUSED(stride); UNUSED(w); @@ -292,13 +292,13 @@ return(-1); } -static uint32_t draw_frame(uint8_t *src[]){ +static int draw_frame(uint8_t *src[]){ UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, "[winvidix] error: didn't use vidix draw_frame!\n"); return(-1); } -static uint32_t query_format(uint32_t format){ +static int query_format(uint32_t format){ return(vidix_query_fourcc(format)); } @@ -315,7 +315,7 @@ // } -static uint32_t preinit(const char *arg){ +static int preinit(const char *arg){ if (arg) vidix_name = strdup(arg); else @@ -330,7 +330,7 @@ return(0); } -static uint32_t control(uint32_t request, void *data, ...){ +static int control(uint32_t request, void *data, ...){ switch (request) { case VOCTRL_FULLSCREEN: if(!vo_fs){vo_fs=1;ShowWindow(hWndFS,SW_SHOW);SetForegroundWindow(hWndFS);}
--- a/libvo/vo_x11.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_x11.c Fri Aug 05 01:24:37 2005 +0000 @@ -254,7 +254,7 @@ myximage = NULL; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -577,7 +577,7 @@ XSync(mDisplay, False); } -static uint32_t draw_slice(uint8_t * src[], int stride[], int w, int h, +static int draw_slice(uint8_t * src[], int stride[], int w, int h, int x, int y) { uint8_t *dst[3]; @@ -634,7 +634,7 @@ return 0; } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { #if 0 int stride[3] = { 0, 0, 0 }; @@ -685,7 +685,7 @@ return (VO_TRUE); } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { mp_msg(MSGT_VO, MSGL_DBG2, "vo_x11: query_format was called: %x (%s)\n", format, @@ -737,7 +737,7 @@ sws_freeContext(swsContext); } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if (arg) { @@ -750,7 +750,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_xmga.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_xmga.c Fri Aug 05 01:24:37 2005 +0000 @@ -113,7 +113,7 @@ vo_mga_flip_page(); } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) {
--- a/libvo/vo_xover.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_xover.c Fri Aug 05 01:24:37 2005 +0000 @@ -204,7 +204,7 @@ /* connect to server, create and map window, * allocate colors and (shared) memory */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { XVisualInfo vinfo; @@ -377,7 +377,7 @@ mp_msg(MSGT_VO, MSGL_FATAL, "xover error: didn't used sub vo flip_page!\n"); } -static uint32_t draw_slice(uint8_t *src[], int stride[], +static int draw_slice(uint8_t *src[], int stride[], int w, int h, int x, int y) { UNUSED(src); @@ -390,7 +390,7 @@ return 1; } -static uint32_t draw_frame(uint8_t *src[]) +static int draw_frame(uint8_t *src[]) { UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, "xover error: didn't used sub vo draw_frame!\n"); @@ -410,7 +410,7 @@ video_out_xover.draw_osd = draw_osd; } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int i; @@ -447,7 +447,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { if(!sub_vo) return VO_ERROR; switch (request) {
--- a/libvo/vo_xv.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_xv.c Fri Aug 05 01:24:37 2005 +0000 @@ -143,7 +143,7 @@ * connect to server, create and map window, * allocate colors and (shared) memory */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -624,7 +624,7 @@ return; } -static uint32_t draw_slice(uint8_t * image[], int stride[], int w, int h, +static int draw_slice(uint8_t * image[], int stride[], int w, int h, int x, int y) { uint8_t *dst; @@ -660,7 +660,7 @@ return 0; } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { printf("draw_frame() called!!!!!!"); return -1; @@ -763,7 +763,7 @@ return VO_FALSE; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { uint32_t i; int flag = VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW | VFCAP_HWSCALE_UP | VFCAP_HWSCALE_DOWN | VFCAP_OSD | VFCAP_ACCEPT_STRIDE; // FIXME! check for DOWN @@ -798,7 +798,7 @@ vo_x11_uninit(); } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { XvPortID xv_p; int busy_ports = 0; @@ -924,7 +924,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_xvidix.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_xvidix.c Fri Aug 05 01:24:37 2005 +0000 @@ -226,7 +226,7 @@ /* connect to server, create and map window, * allocate colors and (shared) memory */ -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -448,7 +448,7 @@ return; } -static uint32_t draw_slice(uint8_t * src[], int stride[], +static int draw_slice(uint8_t * src[], int stride[], int w, int h, int x, int y) { UNUSED(src); @@ -462,7 +462,7 @@ return (-1); } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, @@ -470,7 +470,7 @@ return (-1); } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { return (vidix_query_fourcc(format)); } @@ -490,7 +490,7 @@ vo_x11_uninit(); } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if (arg) @@ -511,7 +511,7 @@ return (0); } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) {
--- a/libvo/vo_xvmc.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_xvmc.c Fri Aug 05 01:24:37 2005 +0000 @@ -345,7 +345,7 @@ return VO_TRUE; } -static uint32_t preinit(const char *arg){ +static int preinit(const char *arg){ int xv_version,xv_release,xv_request_base,xv_event_base,xv_error_base; int mc_eventBase,mc_errorBase; int mc_ver,mc_rev; @@ -409,7 +409,7 @@ return 0; } -static uint32_t config(uint32_t width, uint32_t height, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format){ int i,mode_id,rez; @@ -756,7 +756,7 @@ return 0; } -static uint32_t draw_frame(uint8_t *srcp[]){ +static int draw_frame(uint8_t *srcp[]){ UNUSED(srcp); assert(0); } @@ -1173,7 +1173,7 @@ vo_x11_uninit(); } -static uint32_t query_format(uint32_t format){ +static int query_format(uint32_t format){ uint32_t flags; XvMCSurfaceInfo qsurface_info; int mode_id; @@ -1197,7 +1197,7 @@ } -static uint32_t draw_slice(uint8_t *image[], int stride[], +static int draw_slice(uint8_t *image[], int stride[], int w, int h, int x, int y){ xvmc_render_state_t * rndr; int rez; @@ -1358,7 +1358,7 @@ return VO_TRUE; } -static uint32_t control(uint32_t request, void *data, ... ) +static int control(uint32_t request, void *data, ... ) { switch (request){ case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_yuv4mpeg.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_yuv4mpeg.c Fri Aug 05 01:24:37 2005 +0000 @@ -78,7 +78,7 @@ static int config_interlace = Y4M_ILACE_NONE; #define Y4M_IS_INTERLACED (config_interlace != Y4M_ILACE_NONE) -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { @@ -362,7 +362,7 @@ vo_y4m_write(image, write_bytes); } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x,int y) +static int draw_slice(uint8_t *srcimg[], int stride[], int w,int h,int x,int y) { int i; uint8_t *dst, *src = srcimg[0]; @@ -412,7 +412,7 @@ return 0; } -static uint32_t draw_frame(uint8_t * src[]) +static int draw_frame(uint8_t * src[]) { switch(using_format) { @@ -428,7 +428,7 @@ return 0; } -static uint32_t query_format(uint32_t format) +static int query_format(uint32_t format) { if (Y4M_IS_INTERLACED) @@ -493,7 +493,7 @@ { } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { int il, il_bf; opt_t subopts[] = { @@ -536,7 +536,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_zr.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_zr.c Fri Aug 05 01:24:37 2005 +0000 @@ -300,7 +300,7 @@ } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int i, tmp, stretchx, stretchy; @@ -536,7 +536,7 @@ return; } -static uint32_t draw_frame(uint8_t * src[]) { +static int draw_frame(uint8_t * src[]) { int i, j; char *source, *dest; //printf("draw frame called\n"); @@ -554,7 +554,7 @@ return 0; } -static uint32_t query_format(uint32_t format) { +static int query_format(uint32_t format) { if(format==IMGFMT_YV12 || format==IMGFMT_YUY2) return VFCAP_CSP_SUPPORTED|VFCAP_CSP_SUPPORTED_BY_HW; return 0; @@ -573,7 +573,7 @@ } -static uint32_t draw_slice(uint8_t *srcimg[], int stride[], +static int draw_slice(uint8_t *srcimg[], int stride[], int wf, int hf, int xf, int yf) { int i, j, w, h, x, y; /* Apply 'geometry', crop unwanted parts */ @@ -806,7 +806,7 @@ } -static uint32_t preinit(const char *arg) +static int preinit(const char *arg) { if(arg) { @@ -816,7 +816,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT:
--- a/libvo/vo_zr2.c Mon Aug 01 23:43:40 2005 +0000 +++ b/libvo/vo_zr2.c Fri Aug 05 01:24:37 2005 +0000 @@ -122,7 +122,7 @@ return NULL; } -static uint32_t query_format(uint32_t format) { +static int query_format(uint32_t format) { if (format==IMGFMT_ZRMJPEGNI || format==IMGFMT_ZRMJPEGIT || format==IMGFMT_ZRMJPEGIB) @@ -190,7 +190,7 @@ return 1; } -static uint32_t preinit(const char *arg) { +static int preinit(const char *arg) { vo_zr2_priv_t *p = &priv; const char *dev = NULL; char *dev_arg = NULL, *norm_arg = NULL; @@ -313,7 +313,7 @@ return 0; } -static uint32_t config(uint32_t width, uint32_t height, uint32_t d_width, +static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) { int fields = 1, top_first = 1, err = 0; int stretchx = 1, stretchy = 1; @@ -435,7 +435,7 @@ return 0; } -static uint32_t control(uint32_t request, void *data, ...) { +static int control(uint32_t request, void *data, ...) { switch (request) { case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data)); @@ -445,11 +445,11 @@ return VO_NOTIMPL; } -static uint32_t draw_frame(uint8_t *src[]) { +static int draw_frame(uint8_t *src[]) { return 0; } -static uint32_t draw_slice(uint8_t *image[], int stride[], +static int draw_slice(uint8_t *image[], int stride[], int w, int h, int x, int y) { return 0; }