From 7f295afdc7e98a9f06a17d99a79c5c70c883fbc5 Mon Sep 17 00:00:00 2001 From: rossb Date: Wed, 17 Apr 2002 06:29:07 +0000 Subject: [PATCH] added implementation of PaHost_IsInitialized() migrated PaHost_GetStreamRepresentation() from pa_win_wmme.c --- pa_common/pa_lib.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) 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 ) { -- 2.43.0