cwWaveTableNotes.cpp : gen_note() now validates the sample rate.
This commit is contained in:
parent
645e67fee4
commit
44deba7559
@ -49,11 +49,8 @@ cw::rc_t cw::wt_note::gen_note( wt_bank::handle_t wtbH,
|
|||||||
if( mcs->chN < chN )
|
if( mcs->chN < chN )
|
||||||
chN = mcs->chN;
|
chN = mcs->chN;
|
||||||
|
|
||||||
// TODO: VERIFY srate == SAMPLE RATE OF WAVETABLES
|
// allocate,setup and validate the expected srate of the oscillator
|
||||||
// mcs->valid_srate(srate)
|
if((rc = create(&osc,chN,mcs,srate)) != kOkRC )
|
||||||
|
|
||||||
// allocate and setup xthe oscillator
|
|
||||||
if((rc = create(&osc,chN,mcs)) != kOkRC )
|
|
||||||
{
|
{
|
||||||
rc = cwLogError(rc,"multi-ch-wt-seq-osc create failed.");
|
rc = cwLogError(rc,"multi-ch-wt-seq-osc create failed.");
|
||||||
goto errLabel;
|
goto errLabel;
|
||||||
@ -277,8 +274,8 @@ cw::rc_t cw::wt_note::test( const test::test_args_t& args )
|
|||||||
rc_t rc = kOkRC;
|
rc_t rc = kOkRC;
|
||||||
const char* wtb_json_fname = "/home/kevin/temp/temp_5.json";
|
const char* wtb_json_fname = "/home/kevin/temp/temp_5.json";
|
||||||
unsigned instr_idx = 0;
|
unsigned instr_idx = 0;
|
||||||
unsigned min_pitch = 60;
|
unsigned min_pitch = 21;
|
||||||
unsigned max_pitch = 60;
|
unsigned max_pitch = 21;
|
||||||
srate_t srate = 48000;
|
srate_t srate = 48000;
|
||||||
unsigned audioChN = 2;
|
unsigned audioChN = 2;
|
||||||
double note_dur_sec = 9;
|
double note_dur_sec = 9;
|
||||||
|
Loading…
Reference in New Issue
Block a user