comparison libmpcodecs/vf_vo.c @ 7368:a894e99c1e51

changing return type of put_image void->int
author arpi
date Tue, 10 Sep 2002 22:18:32 +0000
parents e3ecccc7e505
children a9a19a991a70
comparison
equal deleted inserted replaced
7367:5b0baab4c4fd 7368:a894e99c1e51
85 mp_image_t *mpi){ 85 mp_image_t *mpi){
86 if(vo_directrendering && vo_config_count) 86 if(vo_directrendering && vo_config_count)
87 video_out->control(VOCTRL_GET_IMAGE,mpi); 87 video_out->control(VOCTRL_GET_IMAGE,mpi);
88 } 88 }
89 89
90 static void put_image(struct vf_instance_s* vf, 90 static int put_image(struct vf_instance_s* vf,
91 mp_image_t *mpi){ 91 mp_image_t *mpi){
92 if(!vo_config_count) return; // vo not configured? 92 if(!vo_config_count) return 0; // vo not configured?
93 // first check, maybe the vo/vf plugin implements draw_image using mpi: 93 // first check, maybe the vo/vf plugin implements draw_image using mpi:
94 if(video_out->control(VOCTRL_DRAW_IMAGE,mpi)==VO_TRUE) return; // done. 94 if(video_out->control(VOCTRL_DRAW_IMAGE,mpi)==VO_TRUE) return 1; // done.
95 // nope, fallback to old draw_frame/draw_slice: 95 // nope, fallback to old draw_frame/draw_slice:
96 if(!(mpi->flags&(MP_IMGFLAG_DIRECT|MP_IMGFLAG_DRAW_CALLBACK))){ 96 if(!(mpi->flags&(MP_IMGFLAG_DIRECT|MP_IMGFLAG_DRAW_CALLBACK))){
97 // blit frame: 97 // blit frame:
98 if(mpi->flags&MP_IMGFLAG_PLANAR) 98 if(mpi->flags&MP_IMGFLAG_PLANAR)
99 video_out->draw_slice(mpi->planes,mpi->stride,mpi->w,mpi->h,mpi->x,mpi->y); 99 video_out->draw_slice(mpi->planes,mpi->stride,mpi->w,mpi->h,mpi->x,mpi->y);
100 else 100 else
101 video_out->draw_frame(mpi->planes); 101 video_out->draw_frame(mpi->planes);
102 } 102 }
103 return 1;
103 } 104 }
104 105
105 static void draw_slice(struct vf_instance_s* vf, 106 static void draw_slice(struct vf_instance_s* vf,
106 unsigned char** src, int* stride, int w,int h, int x, int y){ 107 unsigned char** src, int* stride, int w,int h, int x, int y){
107 if(!vo_config_count) return; // vo not configured? 108 if(!vo_config_count) return; // vo not configured?