Update of /cvsroot/audacity/lib-src/portaudio-v19/include
In directory
sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv27584/portaudio-v19/include
Modified Files:
pa_asio.h pa_linux_alsa.h pa_mac_core.h pa_unix_oss.h
pa_win_ds.h pa_win_wmme.h portaudio.h
Log Message:
Update portaudio to 2007-jun-01 snapshot
Index: portaudio.h
===================================================================
RCS file: /cvsroot/audacity/lib-src/portaudio-v19/include/portaudio.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- portaudio.h 2 Oct 2006 00:29:03 -0000 1.3
+++ portaudio.h 3 Jun 2007 08:30:23 -0000 1.4
@@ -112,7 +112,8 @@
/** Library initialization function - call this before using PortAudio.
This function initialises internal data structures and prepares underlying
- host APIs for use. This function MUST be called before using any other
+ host APIs for use. With the exception of Pa_GetVersion(),
Pa_GetVersionText(),
+ and Pa_GetErrorText(), this function MUST be called before using any other
PortAudio API functions.
If Pa_Initialize() is called multiple times, each successful
@@ -152,10 +153,10 @@
/** The type used to refer to audio devices. Values of this type usually
- range from 0 to (Pa_DeviceCount-1), and may also take on the PaNoDevice
+ range from 0 to (Pa_GetDeviceCount()-1), and may also take on the PaNoDevice
and paUseHostApiSpecificDeviceSpecification values.
- @see Pa_DeviceCount, paNoDevice, paUseHostApiSpecificDeviceSpecification
+ @see Pa_GetDeviceCount, paNoDevice, paUseHostApiSpecificDeviceSpecification
*/
typedef int PaDeviceIndex;
Index: pa_unix_oss.h
===================================================================
RCS file: /cvsroot/audacity/lib-src/portaudio-v19/include/pa_unix_oss.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- pa_unix_oss.h 2 Oct 2006 00:29:02 -0000 1.1
+++ pa_unix_oss.h 3 Jun 2007 08:30:23 -0000 1.2
@@ -41,9 +41,61 @@
extern "C" {
#endif
-const char *PaOSS_GetInputDevice( PaStream *s );
+const char *PaOSS_GetStreamInputDevice( PaStream *s );
-const char *PaOSS_GetOutputDevice( PaStream *s );
+const char *PaOSS_GetStreamOutputDevice( PaStream *s );
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
+#ifndef PA_UNIX_OSS_H
+#define PA_UNIX_OSS_H
+
+/*
+ * $Id$
+ * PortAudio Portable Real-Time Audio Library
+ * OSS-specific extensions
+ *
+ * Copyright (c) 1999-2000 Ross Bencina and Phil Burk
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files
+ * (the "Software"), to deal in the Software without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Software,
+ * and to permit persons to whom the Software is furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * Any person wishing to distribute modifications to the Software is
+ * requested to send the modifications to the original developer so that
+ * they can be incorporated into the canonical version.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ */
+
+/** @file
+ * OSS-specific PortAudio API extension header file.
+ */
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+const char *PaOSS_GetStreamInputDevice( PaStream *s );
+
+const char *PaOSS_GetStreamOutputDevice( PaStream *s );
#ifdef __cplusplus
}
Index: pa_win_ds.h
===================================================================
RCS file: /cvsroot/audacity/lib-src/portaudio-v19/include/pa_win_ds.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- pa_win_ds.h 2 Oct 2006 00:29:02 -0000 1.1
+++ pa_win_ds.h 3 Jun 2007 08:30:23 -0000 1.2
@@ -67,3 +67,72 @@
#endif /* __cplusplus */
#endif /* PA_WIN_DS_H */
+#ifndef PA_WIN_DS_H
+#define PA_WIN_DS_H
+/*
+ * $Id$
+ * PortAudio Portable Real-Time Audio Library
+ * DirectSound specific extensions
+ *
+ * Copyright (c) 1999-2000 Ross Bencina and Phil Burk
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files
+ * (the "Software"), to deal in the Software without restriction,
+ * including without limitation the rights to use, copy, modify, merge,
+ * publish, distribute, sublicense, and/or sell copies of the Software,
+ * and to permit persons to whom the Software is furnished to do so,
+ * subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * Any person wishing to distribute modifications to the Software is
+ * requested to send the modifications to the original developer so that
+ * they can be incorporated into the canonical version.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+ * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ */
+
+/** @file
+ @brief DirectSound-specific PortAudio API extension header file.
+*/
+
+
+#include "portaudio.h"
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif /* __cplusplus */
+
+
+/** Retrieve the GUID of the input device.
+
+ @param stream The stream to query.
+
+ @return A pointer to the GUID, or NULL if none.
+*/
+LPGUID PaWinDS_GetStreamInputGUID( PaStream* s );
+
+
+/** Retrieve the GUID of the output device.
+
+ @param stream The stream to query.
+
+ @return A pointer to the GUID, or NULL if none.
+*/
+LPGUID PaWinDS_GetStreamOutputGUID( PaStream* s );
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+#endif /* PA_WIN_DS_H */
Index: pa_mac_core.h
===================================================================
RCS file: /cvsroot/audacity/lib-src/portaudio-v19/include/pa_mac_core.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- pa_mac_core.h 2 Oct 2006 00:29:02 -0000 1.3
+++ pa_mac_core.h 3 Jun 2007 08:30:23 -0000 1.4
@@ -1,3 +1,5 @@
+#ifndef PA_MAC_CORE_H
+#define PA_MAC_CORE_H
/*
* PortAudio Portable Real-Time Audio Library
* Macintosh Core Audio specific extensions
@@ -36,6 +38,9 @@
* license above.
*/
+#include <AudioUnit/AudioUnit.h>
+//#include <AudioToolbox/AudioToolbox.h>
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -45,79 +50,122 @@
* A pointer to a paMacCoreStreamInfo may be passed as
* the hostApiSpecificStreamInfo in the PaStreamParameters struct
* when opening a stream or querying the format. Use NULL, for the
- * defaults. Note that for duplex streams, both infos should be the
- * same or behaviour is undefined.
+ * defaults. Note that for duplex streams, flags for input and output
+ * should be the same or behaviour is undefined.
*/
-typedef struct paMacCoreStreamInfo
+typedef struct
{
- unsigned long size; /**size of whole structure including this
header */
- PaHostApiTypeId hostApiType;/**host API for which this data is intended */
- unsigned long version; /**structure version */
- unsigned long flags; /* flags to modify behaviour */
-} paMacCoreStreamInfo;
+ unsigned long size; /**size of whole structure including this
header */
+ PaHostApiTypeId hostApiType; /**host API for which this data is intended
*/
+ unsigned long version; /**structure version */
+ unsigned long flags; /* flags to modify behaviour */
+ SInt32 const * channelMap; /* Channel map for HAL channel mapping , if
not needed, use NULL;*/
+ unsigned long channelMapSize; /* Channel map size for HAL channel mapping
, if not needed, use 0;*/
+} PaMacCoreStreamInfo;
+
+/*
+ * Functions
+ */
+
/* Use this function to initialize a paMacCoreStreamInfo struct
- using the requested flags. */
-void paSetupMacCoreStreamInfo( paMacCoreStreamInfo *data, unsigned long flags
);
+ * using the requested flags. Note that channel mapping is turned
+ * off after a call to this function.
+ * @param data The datastructure to initialize
+ * @param flags The flags to initialize the datastructure with.
+*/
+void PaMacCore_SetupStreamInfo( PaMacCoreStreamInfo *data, unsigned long flags
);
+
+/* call this after pa_SetupMacCoreStreamInfo to use channel mapping as
described in notes.txt.
+ * @param data The stream info structure to assign a channel mapping to
+ * @param channelMap The channel map array, as described in notes.txt. This
array pointer will be used directly (ie the underlying data will not be
copied), so the caller should not free the array until after the stream has
been opened.
+ * @param channelMapSize The size of the channel map array.
+ */
+void PaMacCore_SetupChannelMap( PaMacCoreStreamInfo *data, const SInt32 *
const channelMap, unsigned long channelMapSize );
+
+/*
+ * Retrieve the AudioDeviceID of the input device assigned to an open stream
+ *
+ * @param s The stream to query.
+ *
+ * @return A valid AudioDeviceID, or NULL if an error occurred.
+ */
+AudioDeviceID PaMacCore_GetStreamInputDevice( PaStream* s );
+
+/*
+ * Retrieve the AudioDeviceID of the output device assigned to an open stream
+ *
+ * @param s The stream to query.
+ *
+ * @return A valid AudioDeviceID, or NULL if an error occurred.
+ */
+AudioDeviceID PaMacCore_GetStreamOutputDevice( PaStream* s );
+
+/*
+ * Returns a statically allocated string with the device's name
+ * for the given channel. NULL will be returned on failure.
+ *
+ * This function's implemenation is not complete!
+ *
+ * @param device The PortAudio device index.
+ * @param channel The channel number who's name is requested.
+ * @return a statically allocated string with the name of the device.
+ * Because this string is statically allocated, it must be
+ * coppied if it is to be saved and used by the user after
+ * another call to this function.
+ *
+ */
+const char *PaMacCore_GetChannelName( int device, int channelIndex, bool input
);
+
+/*
+ * Flags
+ */
/*
* The following flags alter the behaviour of PA on the mac platform.
* they can be ORed together. These should work both for opening and
* checking a device.
*/
+
/* Allows PortAudio to change things like the device's frame size,
* which allows for much lower latency, but might disrupt the device
* if other programs are using it, even when you are just Querying
* the device. */
-#define paMacCore_ChangeDeviceParameters (0x01)
+#define paMacCoreChangeDeviceParameters (0x01)
/* In combination with the above flag,
* causes the stream opening to fail, unless the exact sample rates
* are supported by the device. */
-#define paMacCore_FailIfConversionRequired (0x02)
+#define paMacCoreFailIfConversionRequired (0x02)
/* These flags set the SR conversion quality, if required. The wierd ordering
* allows Maximum Quality to be the default.*/
-#define paMacCore_ConversionQualityMin (0x0100)
-#define paMacCore_ConversionQualityMedium (0x0200)
-#define paMacCore_ConversionQualityLow (0x0300)
-#define paMacCore_ConversionQualityHigh (0x0400)
-#define paMacCore_ConversionQualityMax (0x0000)
+#define paMacCoreConversionQualityMin (0x0100)
+#define paMacCoreConversionQualityMedium (0x0200)
+#define paMacCoreConversionQualityLow (0x0300)
+#define paMacCoreConversionQualityHigh (0x0400)
+#define paMacCoreConversionQualityMax (0x0000)
/*
* Here are some "preset" combinations of flags (above) to get to some
* common configurations. THIS IS OVERKILL, but if more flags are added
* it won't be.
*/
+
/*This is the default setting: do as much sample rate conversion as possible
* and as little mucking with the device as possible. */
-#define paMacCorePlayNice (0x00)
+#define paMacCorePlayNice (0x00)
/*This setting is tuned for pro audio apps. It allows SR conversion on input
and output, but it tries to set the appropriate SR on the device.*/
-#define paMacCorePro (0x01)
+#define paMacCorePro (0x01)
/*This is a setting to minimize CPU usage and still play nice.*/
-#define paMacCoreMinimizeCPUButPlayNice (0x0100)
+#define paMacCoreMinimizeCPUButPlayNice (0x0100)
/*This is a setting to minimize CPU usage, even if that means interrupting the
device. */
-#define paMacCoreMinimizeCPU (0x0101)
-
-/*
- * Retrieve the AudioDeviceID of the input device assigned to an open stream
- *
- * @param s The stream to query.
- *
- * @return A valid AudioDeviceID, or NULL if an error occurred.
- */
-AudioDeviceID PaMacCore_GetStreamInputDevice( PaStream* s );
+#define paMacCoreMinimizeCPU (0x0101)
-/*
- * Retrieve the AudioDeviceID of the output device assigned to an open stream
- *
- * @param s The stream to query.
- *
- * @return A valid AudioDeviceID, or NULL if an error occurred.
- */
-AudioDeviceID PaMacCore_GetStreamOutputDevice( PaStream* s );
#ifdef __cplusplus
}
-#endif /* __cplusplus */
\ No newline at end of file
+#endif /* __cplusplus */
+
+#endif /* PA_MAC_CORE_H */
Index: pa_linux_alsa.h
===================================================================
RCS file: /cvsroot/audacity/lib-src/portaudio-v19/include/pa_linux_alsa.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- pa_linux_alsa.h 2 Oct 2006 00:29:02 -0000 1.3
+++ pa_linux_alsa.h 3 Jun 2007 08:30:23 -0000 1.4
@@ -42,6 +42,7 @@
/** @file
* ALSA-specific PortAudio API extension header file.
*/
+#include "portaudio.h"
#ifdef __cplusplus
extern "C" {
@@ -61,11 +62,13 @@
void PaAlsa_EnableRealtimeScheduling( PaStream *s, int enable );
+#if 0
void PaAlsa_EnableWatchdog( PaStream *s, int enable );
+#endif
-int PaAlsa_GetInputCard( PaStream *s );
+int PaAlsa_GetStreamInputCard( PaStream *s, int *card );
-int PaAlsa_GetOutputCard( PaStream *s );
+int PaAlsa_GetStreamOutputCard( PaStream *s, int *card );
#ifdef __cplusplus
}
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Audacity-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/audacity-cvs