Displaying 3 results from an estimated 3 matches for "sndctl_dsp_channel".
Did you mean:
sndctl_dsp_channels
2006 Oct 12
1
Problem with encoding and decoding
...v[0],"-f",2)){
sscanf(argv[1], "%s", (char*)&file);
argc--;
argv++;
};
}
card=open("/dev/dsp", O_RDWR, 0);
if (card<0) {
return false;
}
else{
channels=1;
if (ioctl (card, SNDCTL_DSP_CHANNELS, &channels)==-1) {
return false;
}
format = AFMT_S16_NE;
tmp = ioctl (card, SNDCTL_DSP_SETFMT, &format);
if (tmp==-1) {
return false;
}
// set speed
tmp = 16000;
ioctl(card, SNDCTL_DSP_SPEED, &tmp);
}
/*Create a new encoder state in narro...
2005 Nov 11
7
Fedora Core 4 system lockup with wine 200506.. - 0.9.1
System specs:
Fedora Core 4
2.6.13-1.1532_FC4smp
ATI Radeon 9200 SE
P4 2.4Ghz (hyperthreading)
xorg 6.8.2
Aureal Semiconductor Vortex 2 sound card
Intel 82801EB chipset
wine-20050524 FC3 rpm works just fine on my FC4 system. But any
versions after that lockup my system when running wine. For the 200506
- 200510 versions of wine I have compiled them from scratch so I assumed
it was something
2007 Jul 16
0
configure.ac libswfdec-gtk/Makefile.am libswfdec-gtk/swfdec_playback_oss.c
...quot;Failed to open /dev/dsp\n");
+ return;
+ }
+
+ format = AFMT_S16_LE;
+ ret = ioctl(dsp_fd, SNDCTL_DSP_SETFMT, &format);
+ if (ret == -1) {
+ g_printerr ("Failed to set sound format\n");
+ close(dsp_fd);
+ return;
+ }
+
+ channels = 2;
+ ret = ioctl(dsp_fd, SNDCTL_DSP_CHANNELS, &channels);
+ if (ret == -1) {
+ g_printerr ("Failed to set stereo\n");
+ close(dsp_fd);
+ return;
+ }
+
+ rate = 44100;
+ ret = ioctl(dsp_fd, SNDCTL_DSP_SPEED, &rate);
+ if (ret == -1) {
+ g_printerr ("Failed to set rate\n");
+ close(dsp_fd);
+...