comparison win64-msvc/include/portaudio.h @ 60:95867ba8caa8

Update PortAudio build for Win64
author Chris Cannam
date Tue, 10 Jan 2017 11:28:20 +0000
parents d530e058a1c1
children
comparison
equal deleted inserted replaced
59:cd4953afea46 60:95867ba8caa8
1 #ifndef PORTAUDIO_H 1 #ifndef PORTAUDIO_H
2 #define PORTAUDIO_H 2 #define PORTAUDIO_H
3 /* 3 /*
4 * $Id: portaudio.h 1859 2012-09-01 00:10:13Z philburk $ 4 * $Id$
5 * PortAudio Portable Real-Time Audio Library 5 * PortAudio Portable Real-Time Audio Library
6 * PortAudio API Header File 6 * PortAudio API Header File
7 * Latest version available at: http://www.portaudio.com/ 7 * Latest version available at: http://www.portaudio.com/
8 * 8 *
9 * Copyright (c) 1999-2002 Ross Bencina and Phil Burk 9 * Copyright (c) 1999-2002 Ross Bencina and Phil Burk
48 #ifdef __cplusplus 48 #ifdef __cplusplus
49 extern "C" 49 extern "C"
50 { 50 {
51 #endif /* __cplusplus */ 51 #endif /* __cplusplus */
52 52
53 53 /** Retrieve the release number of the currently running PortAudio build.
54 /** Retrieve the release number of the currently running PortAudio build, 54 For example, for version "19.5.1" this will return 0x00130501.
55 eg 1900. 55
56 @see paMakeVersionNumber
56 */ 57 */
57 int Pa_GetVersion( void ); 58 int Pa_GetVersion( void );
58 59
59
60 /** Retrieve a textual description of the current PortAudio build, 60 /** Retrieve a textual description of the current PortAudio build,
61 eg "PortAudio V19-devel 13 October 2002". 61 e.g. "PortAudio V19.5.0-devel, revision 1952M".
62 The format of the text may change in the future. Do not try to parse the
63 returned string.
64
65 @deprecated As of 19.5.0, use Pa_GetVersionInfo()->versionText instead.
62 */ 66 */
63 const char* Pa_GetVersionText( void ); 67 const char* Pa_GetVersionText( void );
68
69 /**
70 Generate a packed integer version number in the same format used
71 by Pa_GetVersion(). Use this to compare a specified version number with
72 the currently running version. For example:
73
74 @code
75 if( Pa_GetVersion() < paMakeVersionNumber(19,5,1) ) {}
76 @endcode
77
78 @see Pa_GetVersion, Pa_GetVersionInfo
79 @version Available as of 19.5.0.
80 */
81 #define paMakeVersionNumber(major, minor, subminor) \
82 (((major)&0xFF)<<16 | ((minor)&0xFF)<<8 | ((subminor)&0xFF))
83
84
85 /**
86 A structure containing PortAudio API version information.
87 @see Pa_GetVersionInfo, paMakeVersionNumber
88 @version Available as of 19.5.0.
89 */
90 typedef struct PaVersionInfo {
91 int versionMajor;
92 int versionMinor;
93 int versionSubMinor;
94 /**
95 This is currently the Git revision hash but may change in the future.
96 The versionControlRevision is updated by running a script before compiling the library.
97 If the update does not occur, this value may refer to an earlier revision.
98 */
99 const char *versionControlRevision;
100 /** Version as a string, for example "PortAudio V19.5.0-devel, revision 1952M" */
101 const char *versionText;
102 } PaVersionInfo;
103
104 /** Retrieve version information for the currently running PortAudio build.
105 @return A pointer to an immutable PaVersionInfo structure.
106
107 @note This function can be called at any time. It does not require PortAudio
108 to be initialized. The structure pointed to is statically allocated. Do not
109 attempt to free it or modify it.
110
111 @see PaVersionInfo, paMakeVersionNumber
112 @version Available as of 19.5.0.
113 */
114 const PaVersionInfo* Pa_GetVersionInfo();
64 115
65 116
66 /** Error codes returned by PortAudio functions. 117 /** Error codes returned by PortAudio functions.
67 Note that with the exception of paNoError, all PaErrorCodes are negative. 118 Note that with the exception of paNoError, all PaErrorCodes are negative.
68 */ 119 */
898 clients. They can be registered with a stream using the Pa_SetStreamFinishedCallback 949 clients. They can be registered with a stream using the Pa_SetStreamFinishedCallback
899 function. Once registered they are called when the stream becomes inactive 950 function. Once registered they are called when the stream becomes inactive
900 (ie once a call to Pa_StopStream() will not block). 951 (ie once a call to Pa_StopStream() will not block).
901 A stream will become inactive after the stream callback returns non-zero, 952 A stream will become inactive after the stream callback returns non-zero,
902 or when Pa_StopStream or Pa_AbortStream is called. For a stream providing audio 953 or when Pa_StopStream or Pa_AbortStream is called. For a stream providing audio
903 output, if the stream callback returns paComplete, or Pa_StopStream is called, 954 output, if the stream callback returns paComplete, or Pa_StopStream() is called,
904 the stream finished callback will not be called until all generated sample data 955 the stream finished callback will not be called until all generated sample data
905 has been played. 956 has been played.
906 957
907 @param userData The userData parameter supplied to Pa_OpenStream() 958 @param userData The userData parameter supplied to Pa_OpenStream()
908 959
1096 void *buffer, 1147 void *buffer,
1097 unsigned long frames ); 1148 unsigned long frames );
1098 1149
1099 1150
1100 /** Write samples to an output stream. This function doesn't return until the 1151 /** Write samples to an output stream. This function doesn't return until the
1101 entire buffer has been consumed - this may involve waiting for the operating 1152 entire buffer has been written - this may involve waiting for the operating
1102 system to consume the data. 1153 system to consume the data.
1103 1154
1104 @param stream A pointer to an open stream previously created with Pa_OpenStream. 1155 @param stream A pointer to an open stream previously created with Pa_OpenStream.
1105 1156
1106 @param buffer A pointer to a buffer of sample frames. The buffer contains 1157 @param buffer A pointer to a buffer of sample frames. The buffer contains