Kaynağa Gözat

cmDspPgm.c : Added audio outputs to _cmDspSysPgm_RtRecord().

master
kevin 8 yıl önce
ebeveyn
işleme
28a233f26d
1 değiştirilmiş dosya ile 5 ekleme ve 0 silme
  1. 5
    0
      dsp/cmDspPgm.c

+ 5
- 0
dsp/cmDspPgm.c Dosyayı Görüntüle

633
   cmDspInst_t* ai0   = cmDspSysAllocInst( h, "AudioIn", NULL,  1, 0 );
633
   cmDspInst_t* ai0   = cmDspSysAllocInst( h, "AudioIn", NULL,  1, 0 );
634
   cmDspInst_t* ai1   = cmDspSysAllocInst( h, "AudioIn", NULL,  1, 1 );  
634
   cmDspInst_t* ai1   = cmDspSysAllocInst( h, "AudioIn", NULL,  1, 1 );  
635
   cmDspInst_t* afp   = cmDspSysAllocInst( h, "AudioFileOut", NULL,  2,"/Users/kevin/temp/test.aif",2);
635
   cmDspInst_t* afp   = cmDspSysAllocInst( h, "AudioFileOut", NULL,  2,"/Users/kevin/temp/test.aif",2);
636
+  cmDspInst_t* ao0   = cmDspSysAllocInst( h, "AudioOut", NULL,  1, 2 );
637
+  cmDspInst_t* ao1   = cmDspSysAllocInst( h, "AudioOut", NULL,  1, 3 );  
636
   
638
   
637
   // AudioFileOut needs an open message to create the output file
639
   // AudioFileOut needs an open message to create the output file
638
   cmDspInst_t* btn   = cmDspSysAllocInst( h, "Button",      "open",  2, kButtonDuiId, 1.0 );
640
   cmDspInst_t* btn   = cmDspSysAllocInst( h, "Button",      "open",  2, kButtonDuiId, 1.0 );
643
   cmDspSysConnectAudio(h,ai0, "out", afp, "in0");
645
   cmDspSysConnectAudio(h,ai0, "out", afp, "in0");
644
   cmDspSysConnectAudio(h,ai1, "out", afp, "in1");
646
   cmDspSysConnectAudio(h,ai1, "out", afp, "in1");
645
 
647
 
648
+  cmDspSysConnectAudio(h,ai0, "out", ao0, "in");
649
+  cmDspSysConnectAudio(h,ai1, "out", ao1, "in");
650
+
646
   cmDspSysInstallCb( h, btn, "sym",  pts, "open", NULL );
651
   cmDspSysInstallCb( h, btn, "sym",  pts, "open", NULL );
647
   cmDspSysInstallCb( h, pts, "open", afp, "sel",  NULL );
652
   cmDspSysInstallCb( h, pts, "open", afp, "sel",  NULL );
648
 
653
 

Loading…
İptal
Kaydet