Hi.
Looks like mplayer incorrectly handles seeking when doing AC3 audio
bypass via OSS device. When device initially opened mplayer sets sample
rate (SNDCTL_DSP_SPEED), but on seeking it doesn't. It turns sound into
a garbage after any seeking/pausing.
I have made trivial patch to diagnose the problem. It is test only and
surely not perfect, but it works fine for me and other people on FreeBSD
8.0 with snd_hda driver.
--
Alexander Motin
--- ao_oss.c.prev 2007-10-07 22:49:27.000000000 +0300
+++ ao_oss.c 2008-11-29 21:51:21.000000000 +0200
@@ -433,6 +433,7 @@ static void reset(void){
fcntl(audio_fd, F_SETFD, FD_CLOEXEC);
#endif
+ ioctl (audio_fd, SNDCTL_DSP_SPEED, &ao_data.samplerate);
oss_format = format2oss(ao_data.format);
ioctl (audio_fd, SNDCTL_DSP_SETFMT, &oss_format);
if(ao_data.format != AF_FORMAT_AC3) {
@@ -442,7 +443,6 @@ static void reset(void){
int c = ao_data.channels-1;
ioctl (audio_fd, SNDCTL_DSP_STEREO, &c);
}
- ioctl (audio_fd, SNDCTL_DSP_SPEED, &ao_data.samplerate);
}
}
_______________________________________________
MPlayer-users mailing list
MPlayer-users@xxxxxxxxxxxx
https://lists.mplayerhq.hu/mailman/listinfo/mplayer-users