[mythtv] PowerPC
Gregorio Gervasio, Jr.
gtgj at pacbell.net
Sun Dec 12 09:58:11 UTC 2004
>>>>> Brian May writes:
b> What is the current status of PowerPC support?
[...]
b> I have a Pegasos2 PowerPC running Debian testing.
My PPC machine is currently unable to run MythTV properly but
I think all the frontend patches necessary for PPC Linux are in the
repository already, except for one for OSS audio format. Here's a
version from an older CVS snapshot. Should be easy to update it for
the latest tree.
I don't know about running the backend.
Index: libs/libmyth/audiooutputoss.cpp
===================================================================
RCS file: /home/src/cvsroot/mythtv-local/libs/libmyth/audiooutputoss.cpp,v
retrieving revision 1.1.1.18
diff -u -r1.1.1.18 audiooutputoss.cpp
--- libs/libmyth/audiooutputoss.cpp 10 Nov 2004 02:54:00 -0000 1.1.1.18
+++ libs/libmyth/audiooutputoss.cpp 17 Nov 2004 06:39:10 -0000
@@ -36,6 +36,12 @@
bool AudioOutputOSS::OpenDevice()
{
+ int format;
+ if (audio_bits == 8)
+ format = AFMT_S8;
+ else
+ format = AFMT_S16_NE;
+
numbadioctls = 0;
QTime timer;
@@ -80,7 +86,8 @@
{
if (ioctl(audiofd, SNDCTL_DSP_SAMPLESIZE, &audio_bits) < 0 ||
ioctl(audiofd, SNDCTL_DSP_CHANNELS, &audio_channels) < 0 ||
- ioctl(audiofd, SNDCTL_DSP_SPEED, &audio_samplerate) < 0)
+ ioctl(audiofd, SNDCTL_DSP_SPEED, &audio_samplerate) < 0 ||
+ ioctl(audiofd, SNDCTL_DSP_SETFMT, &format) < 0)
err = true;
}
else
@@ -88,15 +95,16 @@
int stereo = audio_channels - 1;
if (ioctl(audiofd, SNDCTL_DSP_SAMPLESIZE, &audio_bits) < 0 ||
ioctl(audiofd, SNDCTL_DSP_STEREO, &stereo) < 0 ||
- ioctl(audiofd, SNDCTL_DSP_SPEED, &audio_samplerate) < 0)
+ ioctl(audiofd, SNDCTL_DSP_SPEED, &audio_samplerate) < 0 ||
+ ioctl(audiofd, SNDCTL_DSP_SETFMT, &format) < 0)
err = true;
}
if (err)
{
Error(QString("Unable to set audio device (%1) to %2 kHz / %3 bits"
- " / %4 channels").arg(audiodevice).arg(audio_samplerate)
- .arg(audio_bits).arg(audio_channels));
+ " / %4 channels / %5 format").arg(audiodevice).arg(audio_samplerate)
+ .arg(audio_bits).arg(audio_channels).arg(format));
close(audiofd);
audiofd = -1;
return false;
--
Gregorio Gervasio, Jr.
More information about the mythtv-dev
mailing list