From: rossb Date: Wed, 17 Apr 2002 06:29:07 +0000 (+0000) Subject: added implementation of PaHost_IsInitialized() X-Git-Tag: V18~18 X-Git-Url: https://andrewgundersen.net/repos?a=commitdiff_plain;h=7f295afdc7e98a9f06a17d99a79c5c70c883fbc5;p=portaudio added implementation of PaHost_IsInitialized() migrated PaHost_GetStreamRepresentation() from pa_win_wmme.c --- diff --git a/pa_common/pa_lib.c b/pa_common/pa_lib.c index 2c7c41c..1c6e82f 100644 --- a/pa_common/pa_lib.c +++ b/pa_common/pa_lib.c @@ -478,6 +478,17 @@ double Pa_GetCPULoad( PortAudioStream* stream) return past->past_Usage; } +/*************************************************************************/ +internalPortAudioStream* PaHost_GetStreamRepresentation( PortAudioStream *stream ) +{ + internalPortAudioStream* result = (internalPortAudioStream*) stream; + + if( result == NULL || result->past_Magic != PA_MAGIC ) + return NULL; + else + return result; +} + /************************************************************* ** Calculate 2 LSB dither signal with a triangular distribution. ** Ranged properly for adding to a 32 bit integer prior to >>15. @@ -754,6 +765,11 @@ PaError Pa_Terminate( void ) return result; } +int PaHost_IsInitialized() +{ + return gInitCount; +} + /*************************************************************************/ PaError Pa_GetSampleSize( PaSampleFormat format ) {