Skip to content

Commit

Permalink
Expose jack_client_t* (HACK)
Browse files Browse the repository at this point in the history
  • Loading branch information
gvnnz committed Feb 1, 2022
1 parent f9fd872 commit 885b71d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
7 changes: 7 additions & 0 deletions RtAudio.cpp
Expand Up @@ -2087,6 +2087,13 @@ struct JackHandle {
:client(0), drainCounter(0), internalDrain(false) { ports[0] = 0; ports[1] = 0; xrun[0] = false; xrun[1] = false; }
};

#if defined(__UNIX_JACK__)
void* RtAudio :: HACK__getJackClient()
{
return static_cast<JackHandle*>(rtapi_->stream_.apiHandle)->client;
}
#endif

#if !defined(__RTAUDIO_DEBUG__)
static void jackSilentError( const char * ) {};
#endif
Expand Down
6 changes: 6 additions & 0 deletions RtAudio.h
Expand Up @@ -580,6 +580,10 @@ class RTAUDIO_DLL_PUBLIC RtAudio
*/
void showWarnings( bool value = true );

#if defined(__UNIX_JACK__)
void* HACK__getJackClient();
#endif

protected:

void openRtApi( RtAudio::Api api );
Expand Down Expand Up @@ -684,6 +688,8 @@ class S24 {

class RTAUDIO_DLL_PUBLIC RtApi
{
friend RtAudio; // HACK

public:

RtApi();
Expand Down

0 comments on commit 885b71d

Please sign in to comment.