[Stk] RtAudio and Stk interface
Gary Scavone
gary at ccrma.Stanford.EDU
Thu Sep 25 17:45:36 PDT 2008
Hi Alpana,
I have 10.5.5 and an Intel Mac and I haven't had problems with Stk
4.3.1. What version of g++ are you using? Download the current
version, run "configure" in the root directory of the distribution,
then go to the "projects/examples" directory and type "make
audioprobe". Then run the compiled application to see what devices
and capabilities RtAudio is finding.
Regards,
--gary
On 25-Sep-08, at 8:15 PM, alpana jui wrote:
> Dear Everybody,
>
>
> I can only use at present 4.2.1 stk for my MACOX core audio. The
> recent version is not configuring my device, Mac 10.5.5 yet.
>
>
> I will appreciate this if anybody could please check my attached
> parameters in this setting. The purpose to use Stk in my application
> is to disk wav files and also to be able to record some commands
> for signal analysis. I am using Stk- 4.2.1 and StkX.
>
>
> I have RtAudioStream status is not declared or set error. I presume
> 4.3.1 an 4.2.1 have some difference in the API settings. I just need
> to use this properly for the time being.
>
>
> In main.cpp
>
>
> _rec_status(false),
> _adc(new RtAudio(RtAudio::MACOSX_CORE)),
> _sampleRate(44100),//Hz
> _bufferFrames(1024),//number of samples per cycle
> _DCcoeffs ( *(new wxClientDC (panel_FT) ) ),
> _scale_x (512), _scale_y(512), // dimension of panel_FT
> _x ( new Signal), // needed for callbackfunction - RtAudio
> _calls (0),//callback-counter
> _cost (Entropy),
> _costpar (0.1),
> _fixed_analyze_size (8192),
> _fb_counter (0),
>
>
>
>
> assert(_adc);
> assert(_x);
> assert(_fixed_buffer);
> _x->RtAudioInterface(_fixed_buffer, _fixed_analyze_size);
>
> //_COUT.open("/Users/Desktop/tu/_cout");
>
>
> _adc->getCurrentApi();
> if ( _adc -> getDeviceCount() < 1 ) {
> wxMessageBox ( _("No audio devices found!"));
>
> button_rec -> Enable(false);
>
>
> unsigned deviceId = 3; /
>
> _deviceinfo=_adc->getDeviceInfo(deviceId);/
>
> _parameters.deviceId = deviceId;
> _parameters.nChannels = 1;//_deviceinfo.inputChannels;//should be
> == 16
> _parameters.firstChannel = 0;
>
>
> In RtAudio.cpp:
> int RtAudioInterface( void *outputBuffer,
> void *inputBuffer,
> unsigned int nBufferFrames,
> double streamTime,
> RtAudioStreamStatus status,
> void *callbackdata )
> {
>
>
> But I am contnously having
> RtAudioStreamStatus status is not declared or set error.
>
>
> Is this APi used in STK: 4.3.1? If not , could you let me know which
> API I should use for this ?
>
>
> In Signal.cpp
>
>
> int Signal::RtAudioInterface( real* inputBuffer, C::index
> nBufferFrames)
>
>
> For disk wav files reading and computing as well as writing speech
> samples:
>
> FileWvIn input("test.wav");
> input.tick();
>
> Are all the above parameters are set and used properly when I am using
> STK-42.1 for recording speech command and using disk wav files since
> who some of these API were written earlier following 4.3.1. But I can
> only manage so far 4.2.1 on Mac Xcode and there I would like to use
> 4.2.1.
>
>
> I will appreciate very much your advice and the directions on my
> concerns and problems.
>
>
> Look forward to hearing from you.
>
> With sincere thanks,
> Jui
>
> _______________________________________________
> Stk mailing list
> Stk at ccrma.stanford.edu
> http://ccrma-mail.stanford.edu/mailman/listinfo/stk
More information about the Stk
mailing list