diff --git a/doc/html/RtAudio_8h-source.html b/doc/html/RtAudio_8h-source.html index 52b8224..4d853be 100644 --- a/doc/html/RtAudio_8h-source.html +++ b/doc/html/RtAudio_8h-source.html @@ -11,7 +11,7 @@
00001 /************************************************************************/ 00038 /************************************************************************/ 00039 -00040 // RtAudio: Version 3.0.2 (14 October 2005) +00040 // RtAudio: Version 3.0.3 (18 November 2005) 00041 00042 #ifndef __RTAUDIO_H 00043 #define __RTAUDIO_H @@ -352,264 +352,265 @@ 00552 private: 00553 00554 void initialize(void); -00555 void probeDeviceInfo( RtApiDevice *info ); -00556 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00557 int sampleRate, RtAudioFormat format, -00558 int *bufferSize, int numberOfBuffers ); -00559 }; -00560 -00561 #endif -00562 -00563 #if defined(__LINUX_JACK__) -00564 -00565 class RtApiJack: public RtApi -00566 { -00567 public: -00568 -00569 RtApiJack(); -00570 ~RtApiJack(); -00571 void tickStream(); -00572 void closeStream(); -00573 void startStream(); -00574 void stopStream(); -00575 void abortStream(); -00576 void setStreamCallback( RtAudioCallback callback, void *userData ); -00577 void cancelStreamCallback(); -00578 // This function is intended for internal use only. It must be -00579 // public because it is called by the internal callback handler, -00580 // which is not a member of RtAudio. External use of this function -00581 // will most likely produce highly undesireable results! -00582 void callbackEvent( unsigned long nframes ); -00583 -00584 private: -00585 -00586 void initialize(void); -00587 void probeDeviceInfo( RtApiDevice *info ); -00588 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00589 int sampleRate, RtAudioFormat format, -00590 int *bufferSize, int numberOfBuffers ); -00591 }; -00592 -00593 #endif -00594 -00595 #if defined(__LINUX_OSS__) -00596 -00597 class RtApiOss: public RtApi -00598 { -00599 public: -00600 -00601 RtApiOss(); -00602 ~RtApiOss(); -00603 void tickStream(); -00604 void closeStream(); -00605 void startStream(); -00606 void stopStream(); -00607 void abortStream(); -00608 int streamWillBlock(); -00609 void setStreamCallback( RtAudioCallback callback, void *userData ); -00610 void cancelStreamCallback(); -00611 -00612 private: -00613 -00614 void initialize(void); -00615 void probeDeviceInfo( RtApiDevice *info ); -00616 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00617 int sampleRate, RtAudioFormat format, -00618 int *bufferSize, int numberOfBuffers ); -00619 }; -00620 -00621 #endif -00622 -00623 #if defined(__MACOSX_CORE__) -00624 -00625 #include <CoreAudio/AudioHardware.h> -00626 -00627 class RtApiCore: public RtApi -00628 { -00629 public: -00630 -00631 RtApiCore(); -00632 ~RtApiCore(); -00633 int getDefaultOutputDevice(void); -00634 int getDefaultInputDevice(void); -00635 void tickStream(); -00636 void closeStream(); -00637 void startStream(); -00638 void stopStream(); -00639 void abortStream(); -00640 void setStreamCallback( RtAudioCallback callback, void *userData ); -00641 void cancelStreamCallback(); -00642 -00643 // This function is intended for internal use only. It must be -00644 // public because it is called by the internal callback handler, -00645 // which is not a member of RtAudio. External use of this function -00646 // will most likely produce highly undesireable results! -00647 void callbackEvent( AudioDeviceID deviceId, void *inData, void *outData ); -00648 -00649 private: -00650 -00651 void initialize(void); -00652 void probeDeviceInfo( RtApiDevice *info ); -00653 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00654 int sampleRate, RtAudioFormat format, -00655 int *bufferSize, int numberOfBuffers ); -00656 }; -00657 -00658 #endif -00659 -00660 #if defined(__WINDOWS_DS__) -00661 -00662 class RtApiDs: public RtApi -00663 { -00664 public: -00665 -00666 RtApiDs(); -00667 ~RtApiDs(); -00668 int getDefaultOutputDevice(void); -00669 int getDefaultInputDevice(void); -00670 void tickStream(); -00671 void closeStream(); -00672 void startStream(); -00673 void stopStream(); -00674 void abortStream(); -00675 int streamWillBlock(); -00676 void setStreamCallback( RtAudioCallback callback, void *userData ); -00677 void cancelStreamCallback(); -00678 -00679 public: -00680 // \brief Internal structure that provide debug information on the state of a running DSound device. -00681 struct RtDsStatistics { -00682 // \brief Sample Rate. -00683 long sampleRate; -00684 // \brief The size of one sample * number of channels on the input device. -00685 int inputFrameSize; -00686 // \brief The size of one sample * number of channels on the output device. -00687 int outputFrameSize; -00688 /* \brief The number of times the read pointer had to be adjusted to avoid reading from an unsafe buffer position. -00689 * -00690 * This field is only used when running in DUPLEX mode. INPUT mode devices just wait until the data is -00691 * available. -00692 */ -00693 int numberOfReadOverruns; -00694 // \brief The number of times the write pointer had to be adjusted to avoid writing in an unsafe buffer position. -00695 int numberOfWriteUnderruns; -00696 // \brief Number of bytes by attribute to buffer configuration by which writing must lead the current write pointer. -00697 int writeDeviceBufferLeadBytes; -00698 // \brief Number of bytes by attributable to the device driver by which writing must lead the current write pointer on this output device. -00699 unsigned long writeDeviceSafeLeadBytes; -00700 // \brief Number of bytes by which reading must trail the current read pointer on this input device. -00701 unsigned long readDeviceSafeLeadBytes; -00702 /* \brief Estimated latency in seconds. -00703 * -00704 * For INPUT mode devices, based the latency of the device's safe read pointer, plus one buffer's -00705 * worth of additional latency. -00706 * -00707 * For OUTPUT mode devices, the latency of the device's safe write pointer, plus N buffers of -00708 * additional buffer latency. -00709 * -00710 * For DUPLEX devices, the sum of latencies for both input and output devices. DUPLEX devices -00711 * also back off the read pointers an additional amount in order to maintain synchronization -00712 * between out-of-phase read and write pointers. This time is also included. -00713 * -00714 * Note that most software packages report latency between the safe write pointer -00715 * and the software lead pointer, excluding the hardware device's safe write pointer -00716 * latency. Figures of 1 or 2ms of latency on Windows audio devices are invariably of this type. -00717 * The reality is that hardware devices often have latencies of 30ms or more (often much -00718 * higher for duplex operation). -00719 */ -00720 -00721 double latency; -00722 }; -00723 // \brief Report on the current state of a running DSound device. -00724 static RtDsStatistics getDsStatistics(); -00725 -00726 private: -00727 -00728 void initialize(void); -00729 void probeDeviceInfo( RtApiDevice *info ); -00730 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00731 int sampleRate, RtAudioFormat format, -00732 int *bufferSize, int numberOfBuffers ); -00733 -00734 bool coInitialized; -00735 bool buffersRolling; -00736 long duplexPrerollBytes; -00737 static RtDsStatistics statistics; -00738 -00739 }; -00740 -00741 #endif -00742 -00743 #if defined(__WINDOWS_ASIO__) -00744 -00745 class RtApiAsio: public RtApi -00746 { -00747 public: -00748 -00749 RtApiAsio(); -00750 ~RtApiAsio(); -00751 void tickStream(); -00752 void closeStream(); -00753 void startStream(); -00754 void stopStream(); -00755 void abortStream(); -00756 void setStreamCallback( RtAudioCallback callback, void *userData ); -00757 void cancelStreamCallback(); -00758 -00759 // This function is intended for internal use only. It must be -00760 // public because it is called by the internal callback handler, -00761 // which is not a member of RtAudio. External use of this function -00762 // will most likely produce highly undesireable results! -00763 void callbackEvent( long bufferIndex ); -00764 -00765 private: -00766 -00767 void initialize(void); -00768 void probeDeviceInfo( RtApiDevice *info ); -00769 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00770 int sampleRate, RtAudioFormat format, -00771 int *bufferSize, int numberOfBuffers ); -00772 -00773 bool coInitialized; -00774 -00775 }; -00776 -00777 #endif -00778 -00779 #if defined(__IRIX_AL__) -00780 -00781 class RtApiAl: public RtApi -00782 { -00783 public: -00784 -00785 RtApiAl(); -00786 ~RtApiAl(); -00787 int getDefaultOutputDevice(void); -00788 int getDefaultInputDevice(void); -00789 void tickStream(); -00790 void closeStream(); -00791 void startStream(); -00792 void stopStream(); -00793 void abortStream(); -00794 int streamWillBlock(); -00795 void setStreamCallback( RtAudioCallback callback, void *userData ); -00796 void cancelStreamCallback(); -00797 -00798 private: -00799 -00800 void initialize(void); -00801 void probeDeviceInfo( RtApiDevice *info ); -00802 bool probeDeviceOpen( int device, StreamMode mode, int channels, -00803 int sampleRate, RtAudioFormat format, -00804 int *bufferSize, int numberOfBuffers ); -00805 }; -00806 -00807 #endif -00808 -00809 // Define the following flag to have extra information spewed to stderr. -00810 //#define __RTAUDIO_DEBUG__ -00811 -00812 #endif +00555 bool primeOutputBuffer(); +00556 void probeDeviceInfo( RtApiDevice *info ); +00557 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00558 int sampleRate, RtAudioFormat format, +00559 int *bufferSize, int numberOfBuffers ); +00560 }; +00561 +00562 #endif +00563 +00564 #if defined(__LINUX_JACK__) +00565 +00566 class RtApiJack: public RtApi +00567 { +00568 public: +00569 +00570 RtApiJack(); +00571 ~RtApiJack(); +00572 void tickStream(); +00573 void closeStream(); +00574 void startStream(); +00575 void stopStream(); +00576 void abortStream(); +00577 void setStreamCallback( RtAudioCallback callback, void *userData ); +00578 void cancelStreamCallback(); +00579 // This function is intended for internal use only. It must be +00580 // public because it is called by the internal callback handler, +00581 // which is not a member of RtAudio. External use of this function +00582 // will most likely produce highly undesireable results! +00583 void callbackEvent( unsigned long nframes ); +00584 +00585 private: +00586 +00587 void initialize(void); +00588 void probeDeviceInfo( RtApiDevice *info ); +00589 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00590 int sampleRate, RtAudioFormat format, +00591 int *bufferSize, int numberOfBuffers ); +00592 }; +00593 +00594 #endif +00595 +00596 #if defined(__LINUX_OSS__) +00597 +00598 class RtApiOss: public RtApi +00599 { +00600 public: +00601 +00602 RtApiOss(); +00603 ~RtApiOss(); +00604 void tickStream(); +00605 void closeStream(); +00606 void startStream(); +00607 void stopStream(); +00608 void abortStream(); +00609 int streamWillBlock(); +00610 void setStreamCallback( RtAudioCallback callback, void *userData ); +00611 void cancelStreamCallback(); +00612 +00613 private: +00614 +00615 void initialize(void); +00616 void probeDeviceInfo( RtApiDevice *info ); +00617 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00618 int sampleRate, RtAudioFormat format, +00619 int *bufferSize, int numberOfBuffers ); +00620 }; +00621 +00622 #endif +00623 +00624 #if defined(__MACOSX_CORE__) +00625 +00626 #include <CoreAudio/AudioHardware.h> +00627 +00628 class RtApiCore: public RtApi +00629 { +00630 public: +00631 +00632 RtApiCore(); +00633 ~RtApiCore(); +00634 int getDefaultOutputDevice(void); +00635 int getDefaultInputDevice(void); +00636 void tickStream(); +00637 void closeStream(); +00638 void startStream(); +00639 void stopStream(); +00640 void abortStream(); +00641 void setStreamCallback( RtAudioCallback callback, void *userData ); +00642 void cancelStreamCallback(); +00643 +00644 // This function is intended for internal use only. It must be +00645 // public because it is called by the internal callback handler, +00646 // which is not a member of RtAudio. External use of this function +00647 // will most likely produce highly undesireable results! +00648 void callbackEvent( AudioDeviceID deviceId, void *inData, void *outData ); +00649 +00650 private: +00651 +00652 void initialize(void); +00653 void probeDeviceInfo( RtApiDevice *info ); +00654 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00655 int sampleRate, RtAudioFormat format, +00656 int *bufferSize, int numberOfBuffers ); +00657 }; +00658 +00659 #endif +00660 +00661 #if defined(__WINDOWS_DS__) +00662 +00663 class RtApiDs: public RtApi +00664 { +00665 public: +00666 +00667 RtApiDs(); +00668 ~RtApiDs(); +00669 int getDefaultOutputDevice(void); +00670 int getDefaultInputDevice(void); +00671 void tickStream(); +00672 void closeStream(); +00673 void startStream(); +00674 void stopStream(); +00675 void abortStream(); +00676 int streamWillBlock(); +00677 void setStreamCallback( RtAudioCallback callback, void *userData ); +00678 void cancelStreamCallback(); +00679 +00680 public: +00681 // \brief Internal structure that provide debug information on the state of a running DSound device. +00682 struct RtDsStatistics { +00683 // \brief Sample Rate. +00684 long sampleRate; +00685 // \brief The size of one sample * number of channels on the input device. +00686 int inputFrameSize; +00687 // \brief The size of one sample * number of channels on the output device. +00688 int outputFrameSize; +00689 /* \brief The number of times the read pointer had to be adjusted to avoid reading from an unsafe buffer position. +00690 * +00691 * This field is only used when running in DUPLEX mode. INPUT mode devices just wait until the data is +00692 * available. +00693 */ +00694 int numberOfReadOverruns; +00695 // \brief The number of times the write pointer had to be adjusted to avoid writing in an unsafe buffer position. +00696 int numberOfWriteUnderruns; +00697 // \brief Number of bytes by attribute to buffer configuration by which writing must lead the current write pointer. +00698 int writeDeviceBufferLeadBytes; +00699 // \brief Number of bytes by attributable to the device driver by which writing must lead the current write pointer on this output device. +00700 unsigned long writeDeviceSafeLeadBytes; +00701 // \brief Number of bytes by which reading must trail the current read pointer on this input device. +00702 unsigned long readDeviceSafeLeadBytes; +00703 /* \brief Estimated latency in seconds. +00704 * +00705 * For INPUT mode devices, based the latency of the device's safe read pointer, plus one buffer's +00706 * worth of additional latency. +00707 * +00708 * For OUTPUT mode devices, the latency of the device's safe write pointer, plus N buffers of +00709 * additional buffer latency. +00710 * +00711 * For DUPLEX devices, the sum of latencies for both input and output devices. DUPLEX devices +00712 * also back off the read pointers an additional amount in order to maintain synchronization +00713 * between out-of-phase read and write pointers. This time is also included. +00714 * +00715 * Note that most software packages report latency between the safe write pointer +00716 * and the software lead pointer, excluding the hardware device's safe write pointer +00717 * latency. Figures of 1 or 2ms of latency on Windows audio devices are invariably of this type. +00718 * The reality is that hardware devices often have latencies of 30ms or more (often much +00719 * higher for duplex operation). +00720 */ +00721 +00722 double latency; +00723 }; +00724 // \brief Report on the current state of a running DSound device. +00725 static RtDsStatistics getDsStatistics(); +00726 +00727 private: +00728 +00729 void initialize(void); +00730 void probeDeviceInfo( RtApiDevice *info ); +00731 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00732 int sampleRate, RtAudioFormat format, +00733 int *bufferSize, int numberOfBuffers ); +00734 +00735 bool coInitialized; +00736 bool buffersRolling; +00737 long duplexPrerollBytes; +00738 static RtDsStatistics statistics; +00739 +00740 }; +00741 +00742 #endif +00743 +00744 #if defined(__WINDOWS_ASIO__) +00745 +00746 class RtApiAsio: public RtApi +00747 { +00748 public: +00749 +00750 RtApiAsio(); +00751 ~RtApiAsio(); +00752 void tickStream(); +00753 void closeStream(); +00754 void startStream(); +00755 void stopStream(); +00756 void abortStream(); +00757 void setStreamCallback( RtAudioCallback callback, void *userData ); +00758 void cancelStreamCallback(); +00759 +00760 // This function is intended for internal use only. It must be +00761 // public because it is called by the internal callback handler, +00762 // which is not a member of RtAudio. External use of this function +00763 // will most likely produce highly undesireable results! +00764 void callbackEvent( long bufferIndex ); +00765 +00766 private: +00767 +00768 void initialize(void); +00769 void probeDeviceInfo( RtApiDevice *info ); +00770 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00771 int sampleRate, RtAudioFormat format, +00772 int *bufferSize, int numberOfBuffers ); +00773 +00774 bool coInitialized; +00775 +00776 }; +00777 +00778 #endif +00779 +00780 #if defined(__IRIX_AL__) +00781 +00782 class RtApiAl: public RtApi +00783 { +00784 public: +00785 +00786 RtApiAl(); +00787 ~RtApiAl(); +00788 int getDefaultOutputDevice(void); +00789 int getDefaultInputDevice(void); +00790 void tickStream(); +00791 void closeStream(); +00792 void startStream(); +00793 void stopStream(); +00794 void abortStream(); +00795 int streamWillBlock(); +00796 void setStreamCallback( RtAudioCallback callback, void *userData ); +00797 void cancelStreamCallback(); +00798 +00799 private: +00800 +00801 void initialize(void); +00802 void probeDeviceInfo( RtApiDevice *info ); +00803 bool probeDeviceOpen( int device, StreamMode mode, int channels, +00804 int sampleRate, RtAudioFormat format, +00805 int *bufferSize, int numberOfBuffers ); +00806 }; +00807 +00808 #endif +00809 +00810 // Define the following flag to have extra information spewed to stderr. +00811 //#define __RTAUDIO_DEBUG__ +00812 +00813 #endif
![]() |
diff --git a/doc/html/index.html b/doc/html/index.html
index 4774192..8cc5c27 100644
--- a/doc/html/index.html
+++ b/doc/html/index.html
@@ -43,7 +43,7 @@ Several API changes have been made in version 3.0 of RtAudio::getDeviceInfo() function was modified to return a globally defined RtAudioDeviceInfo structure. This structure is a simplified version of the previous RTAUDIO_DEVICE structure. In addition, the RTAUDIO_FORMAT structure was renamed RtAudioFormat and defined globally within RtAudio.h. These changes were made for clarity and to better conform with standard C++ programming practices.