# HG changeset patch # User mswitch # Date 1013276433 0 # Node ID 8497da33a0d244c99e9958bea30e159721b30bde # Parent 4edfdec1dc12ff436994ba10bbc209e097345f99 updated :noprebuf to emulate the playback used in mplayer 0.60 (with dxr3 patch), this solves alot of issues for ppl who had problems with the new prebuffering code diff -r 4edfdec1dc12 -r 8497da33a0d2 libvo/vo_dxr3.c --- a/libvo/vo_dxr3.c Sat Feb 09 17:03:53 2002 +0000 +++ b/libvo/vo_dxr3.c Sat Feb 09 17:40:33 2002 +0000 @@ -171,10 +171,12 @@ ioval = EM8300_SUBDEVICE_AUDIO; ioctl(fd_control, EM8300_IOCTL_FLUSH, &ioval); fsync(fd_video); - ioval = 0x900; - ioctl(fd_control, EM8300_IOCTL_SCR_SETSPEED, &ioval); - ioval = 0; - ioctl(fd_control, EM8300_IOCTL_SCR_SET, &ioval); + if (!noprebuf) { + ioval = 0x900; + ioctl(fd_control, EM8300_IOCTL_SCR_SETSPEED, &ioval); + ioval = 0; + ioctl(fd_control, EM8300_IOCTL_SCR_SET, &ioval); + } /* Store some variables statically that we need later in another scope */ img_format = format; @@ -299,12 +301,16 @@ static uint32_t draw_frame(uint8_t * src[]) { - ioctl(fd_video, EM8300_IOCTL_VIDEO_SETPTS, &vo_pts); + if (!noprebuf) { + ioctl(fd_video, EM8300_IOCTL_VIDEO_SETPTS, &vo_pts); + } if (img_format == IMGFMT_MPEGPES) { vo_mpegpes_t *p = (vo_mpegpes_t *) src[0]; if (p->id == 0x20) { - ioctl(fd_spu, EM8300_IOCTL_SPU_SETPTS, &vo_pts); + if (!noprebuf) { + ioctl(fd_spu, EM8300_IOCTL_SPU_SETPTS, &vo_pts); + } write(fd_spu, p->data, p->size); } else { write(fd_video, p->data, p->size); @@ -334,7 +340,9 @@ #ifdef USE_LIBAVCODEC if (img_format == IMGFMT_YV12) { int out_size = avcodec_encode_video(avc_context, avc_outbuf, avc_outbuf_size, &avc_picture); - ioctl(fd_video, EM8300_IOCTL_VIDEO_SETPTS, &vo_pts); + if (!noprebuf) { + ioctl(fd_video, EM8300_IOCTL_VIDEO_SETPTS, &vo_pts); + } write(fd_video, avc_outbuf, out_size); } #endif