author | harlekin <harlekin> | 2002-12-19 21:41:50 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-12-19 21:41:50 (UTC) |
commit | 5fd6636ba3d94b48dd543887316c47c5388a43c2 (patch) (side-by-side diff) | |
tree | f750583ce4284ac226da90858751875a5404de6b | |
parent | d73c08dacb1abd6e02e0ff803083985bd0ca791b (diff) | |
download | opie-5fd6636ba3d94b48dd543887316c47c5388a43c2.zip opie-5fd6636ba3d94b48dd543887316c47c5388a43c2.tar.gz opie-5fd6636ba3d94b48dd543887316c47c5388a43c2.tar.bz2 |
adapted to todays xine cvs
-rw-r--r-- | noncore/multimedia/opieplayer2/nullvideo.c | 2 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/yuv2rgb.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/noncore/multimedia/opieplayer2/nullvideo.c b/noncore/multimedia/opieplayer2/nullvideo.c index a49f9d3..095f206 100644 --- a/noncore/multimedia/opieplayer2/nullvideo.c +++ b/noncore/multimedia/opieplayer2/nullvideo.c @@ -86,64 +86,66 @@ struct null_driver_s { display_xine_frame_t frameDis; }; typedef struct opie_frame_s opie_frame_t; struct opie_frame_s { vo_frame_t frame; int format; int flags; vo_scale_t sc; uint8_t *chunk[3]; uint8_t *data; /* rgb */ int bytes_per_line; yuv2rgb_t *yuv2rgb; uint8_t *rgb_dst; int yuv_stride; int stripe_height, stripe_inc; null_driver_t *output; }; static uint32_t null_get_capabilities( vo_driver_t *self ){ null_driver_t* this = (null_driver_t*)self; return this->m_capabilities; } static void null_frame_copy (vo_frame_t *vo_img, uint8_t **src) { opie_frame_t *frame = (opie_frame_t *) vo_img ; + + vo_img->copy_called = 1; if (!frame->output->m_show_video) { /* printf("nullvideo: no video\n"); */ return; } if (frame->format == XINE_IMGFMT_YV12) { frame->yuv2rgb->yuv2rgb_fun (frame->yuv2rgb, frame->rgb_dst, src[0], src[1], src[2]); } else { frame->yuv2rgb->yuy22rgb_fun (frame->yuv2rgb, frame->rgb_dst, src[0]); } frame->rgb_dst += frame->stripe_inc; } static void null_frame_field (vo_frame_t *vo_img, int which_field) { opie_frame_t *frame = (opie_frame_t *) vo_img ; switch (which_field) { case VO_TOP_FIELD: frame->rgb_dst = (uint8_t *)frame->data; frame->stripe_inc = 2*frame->stripe_height * frame->bytes_per_line; break; case VO_BOTTOM_FIELD: frame->rgb_dst = (uint8_t *)frame->data + frame->bytes_per_line ; frame->stripe_inc = 2*frame->stripe_height * frame->bytes_per_line; break; case VO_BOTH_FIELDS: diff --git a/noncore/multimedia/opieplayer2/yuv2rgb.c b/noncore/multimedia/opieplayer2/yuv2rgb.c index e8e86e6..8e34052 100644 --- a/noncore/multimedia/opieplayer2/yuv2rgb.c +++ b/noncore/multimedia/opieplayer2/yuv2rgb.c @@ -1178,69 +1178,69 @@ static void scale_line_1_2 (uint8_t *source, uint8_t *dest, */ static void scale_line_1_1 (uint8_t *source, uint8_t *dest, int width, int step) { xine_profiler_start_count(prof_scale_line); xine_fast_memcpy(dest, source, width); xine_profiler_stop_count(prof_scale_line); } static scale_line_func_t find_scale_line_func(int step) { static struct { int src_step; int dest_step; scale_line_func_t func; char *desc; } scale_line[] = { { 15, 16, scale_line_15_16, "dvd 4:3(pal)" }, { 45, 64, scale_line_45_64, "dvd 16:9(pal), fullscreen(1024x768)" }, { 9, 16, scale_line_9_16, "dvd fullscreen(1280x1024)" }, { 45, 53, scale_line_45_53, "dvd 16:9(ntsc)" }, { 11, 12, scale_line_11_12, "vcd 4:3(pal)" }, { 11, 24, scale_line_11_24, "vcd 4:3(pal) 2*zoom" }, { 5, 8, scale_line_5_8, "svcd 4:3(pal)" }, { 3, 4, scale_line_3_4, "svcd 4:3(ntsc)" }, { 1, 2, scale_line_1_2, "2*zoom" }, { 1, 1, scale_line_1_1, "non-scaled" }, }; int i; for (i = 0; i < sizeof(scale_line)/sizeof(scale_line[0]); i++) { if (step == scale_line[i].src_step*32768/scale_line[i].dest_step) { - printf("yuv2rgb: using %s optimized scale_line\n", scale_line[i].desc); + //printf("yuv2rgb: using %s optimized scale_line\n", scale_line[i].desc); return scale_line[i].func; } } - printf("yuv2rgb: using generic scale_line with interpolation\n"); + //printf("yuv2rgb: using generic scale_line with interpolation\n"); return scale_line_gen; } static void scale_line_2 (uint8_t *source, uint8_t *dest, int width, int step) { int p1; int p2; int dx; p1 = *source; source+=2; p2 = *source; source+=2; dx = 0; while (width) { *dest = (p1 * (32768 - dx) + p2 * dx) / 32768; dx += step; while (dx > 32768) { dx -= 32768; p1 = p2; p2 = *source; source+=2; } dest ++; width --; } } |