this is necessary in order to get Furnace to build using CMake 4.0. you should do: git submodule deinit extern/portaudio
		
			
				
	
	
		
			46 lines
		
	
	
		
			1.3 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			46 lines
		
	
	
		
			1.3 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
#include "portaudiocpp/InterfaceCallbackStream.hxx"
 | 
						|
 | 
						|
#include "portaudiocpp/StreamParameters.hxx"
 | 
						|
#include "portaudiocpp/Exception.hxx"
 | 
						|
#include "portaudiocpp/CallbackInterface.hxx"
 | 
						|
 | 
						|
namespace portaudio
 | 
						|
{
 | 
						|
 | 
						|
    // ---------------------------------------------------------------------------------==
 | 
						|
 | 
						|
    InterfaceCallbackStream::InterfaceCallbackStream()
 | 
						|
    {
 | 
						|
    }
 | 
						|
 | 
						|
    InterfaceCallbackStream::InterfaceCallbackStream(const StreamParameters ¶meters, CallbackInterface &instance)
 | 
						|
    {
 | 
						|
        open(parameters, instance);
 | 
						|
    }
 | 
						|
 | 
						|
    InterfaceCallbackStream::~InterfaceCallbackStream()
 | 
						|
    {
 | 
						|
        try
 | 
						|
        {
 | 
						|
            close();
 | 
						|
        }
 | 
						|
        catch (...)
 | 
						|
        {
 | 
						|
            // ignore all errors
 | 
						|
        }
 | 
						|
    }
 | 
						|
 | 
						|
    // ---------------------------------------------------------------------------------==
 | 
						|
 | 
						|
    void InterfaceCallbackStream::open(const StreamParameters ¶meters, CallbackInterface &instance)
 | 
						|
    {
 | 
						|
        PaError err = Pa_OpenStream(&stream_, parameters.inputParameters().paStreamParameters(), parameters.outputParameters().paStreamParameters(),
 | 
						|
            parameters.sampleRate(), parameters.framesPerBuffer(), parameters.flags(), &impl::callbackInterfaceToPaCallbackAdapter, static_cast<void *>(&instance));
 | 
						|
 | 
						|
        if (err != paNoError)
 | 
						|
        {
 | 
						|
            throw PaException(err);
 | 
						|
        }
 | 
						|
    }
 | 
						|
}
 |