main.cpp,cfg/main.cfg : Pass arguments from main.cfg to ui::test() and io::test().
This commit is contained in:
parent
804c015b25
commit
44df01eb92
@ -42,12 +42,83 @@
|
|||||||
socketSrvUdp: {},
|
socketSrvUdp: {},
|
||||||
socketSrvTcp: {},
|
socketSrvTcp: {},
|
||||||
sockMgrTest: {},
|
sockMgrTest: {},
|
||||||
uiTest: {},
|
uiTest: {
|
||||||
|
ui: {
|
||||||
|
physRootDir: "/home/kevin/src/cwtest/src/libcw/html/uiTest",
|
||||||
|
dfltPageFn: "index.html",
|
||||||
|
port: 5687,
|
||||||
|
rcvBufByteN: 2048,
|
||||||
|
xmtBufByteN: 2048,
|
||||||
|
fmtBufByteN: 4096,
|
||||||
|
websockTimeOutMs: 50, // max time out while blocking for a websock event
|
||||||
|
uiCfgFn: "ui.cfg" // default UI resource description
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
socketMdns: {},
|
socketMdns: {},
|
||||||
dnssd: {},
|
dnssd: {},
|
||||||
eucon: {},
|
eucon: {},
|
||||||
dirEntry: {},
|
dirEntry: {},
|
||||||
io: {},
|
io: {
|
||||||
|
ui: {
|
||||||
|
physRootDir: "/home/kevin/src/cwtest/src/libcw/html/ioTest",
|
||||||
|
dfltPageFn: "index.html",
|
||||||
|
port: 5687,
|
||||||
|
rcvBufByteN: 2048,
|
||||||
|
xmtBufByteN: 2048,
|
||||||
|
fmtBufByteN: 4096,
|
||||||
|
websockTimeOutMs: 50, // max time out while blocking for a websock event
|
||||||
|
uiCfgFn: "ui.cfg" // default UI resource description
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
serial: [
|
||||||
|
{
|
||||||
|
name: "port1",
|
||||||
|
device: "/dev/ttyACM0",
|
||||||
|
baud: 38400,
|
||||||
|
bits: 8,
|
||||||
|
stop: 1,
|
||||||
|
parity: no,
|
||||||
|
pollPeriodMs: 50
|
||||||
|
}
|
||||||
|
],
|
||||||
|
|
||||||
|
|
||||||
|
midi: {
|
||||||
|
parserBufByteN: 1024,
|
||||||
|
},
|
||||||
|
|
||||||
|
audio: {
|
||||||
|
meterMs: 50, // audio meter filter length and meter callback period
|
||||||
|
threadTimeOutMs: 50, // audio thread cond var time out
|
||||||
|
|
||||||
|
groupL: [
|
||||||
|
{
|
||||||
|
enableFl: true,
|
||||||
|
label: "main", // user label
|
||||||
|
id: 0,
|
||||||
|
srate: 48000,
|
||||||
|
dspFrameCnt: 64
|
||||||
|
}
|
||||||
|
],
|
||||||
|
|
||||||
|
deviceL: [
|
||||||
|
{
|
||||||
|
enableFl: true,
|
||||||
|
label: "main", // User label
|
||||||
|
device: "Scarlett 18i20 USB USB Audio",
|
||||||
|
//device: "USB Audio CODEC USB Audio",
|
||||||
|
// device: "HDA Intel PCH CS4208 Analog",
|
||||||
|
framesPerCycle: 512, // Samples per audio device cycle
|
||||||
|
cycleCnt: 3, //
|
||||||
|
inGroupId: 0, // All devices in a group must be ready to source
|
||||||
|
outGroupId: 0 // or sink data before an audio callback is made for that group
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
audioDevRpt: {},
|
audioDevRpt: {},
|
||||||
|
|
||||||
@ -96,18 +167,18 @@
|
|||||||
|
|
||||||
|
|
||||||
dataset_wtr: {
|
dataset_wtr: {
|
||||||
outFn: "~/temp/temp.ds"
|
outFn: "~/temp/temp.ds"
|
||||||
},
|
},
|
||||||
|
|
||||||
dataset_rdr: {
|
dataset_rdr: {
|
||||||
inFn: "~/temp/temp.ds",
|
inFn: "~/temp/temp.ds",
|
||||||
cacheByteN: 146,
|
cacheByteN: 146,
|
||||||
},
|
},
|
||||||
|
|
||||||
dataset_adapter: {
|
dataset_adapter: {
|
||||||
inFn: "~/temp/temp.ds",
|
inFn: "~/temp/temp.ds",
|
||||||
cacheByteN: 154,
|
cacheByteN: 154,
|
||||||
batchN: 3,
|
batchN: 3,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
@ -273,7 +344,7 @@
|
|||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "a.wav", src: "~/temp/kc_record/xform_only/wet/a.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "a.wav", src: "~/temp/kc_record/xform_only/wet/a.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "b.wav", src: "~/temp/kc_record/xform_only/wet/b.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "b.wav", src: "~/temp/kc_record/xform_only/wet/b.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "c.wav", src: "~/temp/kc_record/xform_only/wet/c.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "c.wav", src: "~/temp/kc_record/xform_only/wet/c.aiff" },
|
||||||
|
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "d.wav", src: "~/temp/kc_record/xform_only/wet/d.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "d.wav", src: "~/temp/kc_record/xform_only/wet/d.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "f1.wav", src: "~/temp/kc_record/xform_only/wet/f1.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "f1.wav", src: "~/temp/kc_record/xform_only/wet/f1.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "f2.wav", src: "~/temp/kc_record/xform_only/wet/f2.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "f2.wav", src: "~/temp/kc_record/xform_only/wet/f2.aiff" },
|
||||||
@ -281,78 +352,78 @@
|
|||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "f3.wav", src: "~/temp/kc_record/xform_only/wet/f3.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "f3.wav", src: "~/temp/kc_record/xform_only/wet/f3.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "f4.wav", src: "~/temp/kc_record/xform_only/wet/f4.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "f4.wav", src: "~/temp/kc_record/xform_only/wet/f4.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "g.wav", src: "~/temp/kc_record/xform_only/wet/g.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "g.wav", src: "~/temp/kc_record/xform_only/wet/g.aiff" },
|
||||||
|
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "ga.wav", src: "~/temp/kc_record/xform_only/wet/ga.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "ga.wav", src: "~/temp/kc_record/xform_only/wet/ga.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "g1a.wav", src: "~/temp/kc_record/xform_only/wet/g1a.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "g1a.wav", src: "~/temp/kc_record/xform_only/wet/g1a.aiff" },
|
||||||
{ begSec: 1743.3, endSec: 1816.44, dst: "g1d.wav", src: "~/temp/kc_record/xform_only/wet/g1d.aiff" },
|
{ begSec: 1743.3, endSec: 1816.44, dst: "g1d.wav", src: "~/temp/kc_record/xform_only/wet/g1d.aiff" },
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// Extract a section of source audio, apply fade in/out ramps, and mix it into a destination file.
|
// Extract a section of source audio, apply fade in/out ramps, and mix it into a destination file.
|
||||||
cut_and_mix:
|
cut_and_mix:
|
||||||
{
|
{
|
||||||
dstFn: "~/temp/test_xfade.wav",
|
dstFn: "~/temp/test_xfade.wav",
|
||||||
dstBits: 24,
|
dstBits: 24,
|
||||||
|
|
||||||
srcDir: "~/temp",
|
srcDir: "~/temp",
|
||||||
crossFadeSec: 0.5,
|
crossFadeSec: 0.5,
|
||||||
|
|
||||||
argL: [
|
argL: [
|
||||||
{ srcBegSec: 1.0, srcEndSec: 2.0, srcFn: "temp_sine_100_hz.wav", dstBegSec:0.0, gain:1.0 },
|
{ srcBegSec: 1.0, srcEndSec: 2.0, srcFn: "temp_sine_100_hz.wav", dstBegSec:0.0, gain:1.0 },
|
||||||
{ srcBegSec: 3.0, srcEndSec: 4.0, srcFn: "temp_sine_1000_hz.wav", dstBegSec:0.5, gain:1.0 }
|
{ srcBegSec: 3.0, srcEndSec: 4.0, srcFn: "temp_sine_1000_hz.wav", dstBegSec:0.5, gain:1.0 }
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
// Given a set of overlapping source files of identical length solo a given source during a specified time interval.
|
// Given a set of overlapping source files of identical length solo a given source during a specified time interval.
|
||||||
parallel_mix:
|
parallel_mix:
|
||||||
{
|
{
|
||||||
dstFn: "~/temp/test_pmix.wav",
|
dstFn: "~/temp/test_pmix.wav",
|
||||||
dstBits: 24,
|
dstBits: 24,
|
||||||
|
|
||||||
srcDir: "~/temp/kc_record/xform_only/cut",
|
srcDir: "~/temp/kc_record/xform_only/cut",
|
||||||
|
|
||||||
argL: [
|
argL: [
|
||||||
{ srcBegSec: 0.0, srcEndSec: 4.2, srcFn: "dry_mix.wav", fadeOutSec:0.5, gain:1.0 },
|
{ srcBegSec: 0.0, srcEndSec: 4.2, srcFn: "dry_mix.wav", fadeOutSec:0.5, gain:1.0 },
|
||||||
{ srcBegSec: 4.2, srcEndSec: 8.6, srcFn: "d_mix.wav", fadeOutSec:0.5, gain:1.0 }
|
{ srcBegSec: 4.2, srcEndSec: 8.6, srcFn: "d_mix.wav", fadeOutSec:0.5, gain:1.0 }
|
||||||
{ srcBegSec: 8.6, srcEndSec: 15.67, srcFn: "ga_mix.wav", fadeOutSec:0.5, gain:1.0 }
|
{ srcBegSec: 8.6, srcEndSec: 15.67, srcFn: "ga_mix.wav", fadeOutSec:0.5, gain:1.0 }
|
||||||
{ srcBegSec: 15.67, srcEndSec: 17.98, srcFn: "dry_mix.wav", fadeOutSec:0.0, gain:1.0 }
|
{ srcBegSec: 15.67, srcEndSec: 17.98, srcFn: "dry_mix.wav", fadeOutSec:0.0, gain:1.0 }
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
convolve_file:
|
convolve_file:
|
||||||
{
|
{
|
||||||
dstFn: "~/temp/test_convolve.wav",
|
dstFn: "~/temp/test_convolve.wav",
|
||||||
dstBits: 32,
|
dstBits: 32,
|
||||||
srcFn: "~/temp/select_to_file/preset_f1.wav",
|
srcFn: "~/temp/select_to_file/preset_f1.wav",
|
||||||
irFn: "~/sdk/freeverb3/samples/IR/IR_theater.wav",
|
irFn: "~/sdk/freeverb3/samples/IR/IR_theater.wav",
|
||||||
irScale: 1.0,
|
irScale: 1.0,
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
transform_app:
|
transform_app:
|
||||||
{
|
{
|
||||||
srcDir: "~/temp/kc_record/xform_only/cut", // location of 'wet' source files
|
srcDir: "~/temp/kc_record/xform_only/cut", // location of 'wet' source files
|
||||||
dryFn: "~/temp/kc_record/xform_only/cut/concert.wav", // dry source file
|
dryFn: "~/temp/kc_record/xform_only/cut/concert.wav", // dry source file
|
||||||
|
|
||||||
dstPreFn: "~/temp/test_xform_app.wav", // the output file prior to reverb
|
dstPreFn: "~/temp/test_xform_app.wav", // the output file prior to reverb
|
||||||
dstRevFn: "~/temp/test_xform_app_rev.wav", // the output file with reverb
|
dstRevFn: "~/temp/test_xform_app_rev.wav", // the output file with reverb
|
||||||
|
|
||||||
dstBits: 32,
|
dstBits: 32,
|
||||||
|
|
||||||
irEnableFl: false,
|
irEnableFl: false,
|
||||||
irScale: 0.25,
|
irScale: 0.25,
|
||||||
irFn: null, //"~/media/audio/IR/freeverb3/101-cup.wav"
|
irFn: null, //"~/media/audio/IR/freeverb3/101-cup.wav"
|
||||||
|
|
||||||
|
|
||||||
argL: [
|
argL: [
|
||||||
{ srcBegSec: 0.0, srcEndSec: 4.2, srcFn: "a.wav", fadeOutSec:0.5, wetGain:0.3 },
|
{ srcBegSec: 0.0, srcEndSec: 4.2, srcFn: "a.wav", fadeOutSec:0.5, wetGain:0.3 },
|
||||||
{ srcBegSec: 4.2, srcEndSec: 8.6, srcFn: "b.wav", fadeOutSec:0.5, wetGain:0.3 },
|
{ srcBegSec: 4.2, srcEndSec: 8.6, srcFn: "b.wav", fadeOutSec:0.5, wetGain:0.3 },
|
||||||
{ srcBegSec: 8.6, srcEndSec: 15.67, srcFn: "c.wav", fadeOutSec:0.5, wetGain:0.3 },
|
{ srcBegSec: 8.6, srcEndSec: 15.67, srcFn: "c.wav", fadeOutSec:0.5, wetGain:0.3 },
|
||||||
{ srcBegSec: 15.67, srcEndSec: 17.98, srcFn: "d.wav", fadeOutSec:0.0, wetGain:0.3 },
|
{ srcBegSec: 15.67, srcEndSec: 17.98, srcFn: "d.wav", fadeOutSec:0.0, wetGain:0.3 },
|
||||||
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
fft: {},
|
fft: {},
|
||||||
|
@ -361,9 +361,9 @@ cw::rc_t euConTest( const cw::object_t* cfg, const cw::object_t* args
|
|||||||
|
|
||||||
#if defined(cwWEBSOCK)
|
#if defined(cwWEBSOCK)
|
||||||
cw::rc_t websockSrvTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::websockSrvTest(cfg); }
|
cw::rc_t websockSrvTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::websockSrvTest(cfg); }
|
||||||
cw::rc_t uiTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::ui::test(); }
|
cw::rc_t uiTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::ui::test(args); }
|
||||||
#if defined(cwALSA)
|
#if defined(cwALSA)
|
||||||
cw::rc_t ioTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::io::test(); }
|
cw::rc_t ioTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return cw::io::test(args); }
|
||||||
#else
|
#else
|
||||||
cw::rc_t _no_alsa_websock() { return cwLogError(cw::kResourceNotAvailableRC,"Websock or ALSA functionality not included in this build."); }
|
cw::rc_t _no_alsa_websock() { return cwLogError(cw::kResourceNotAvailableRC,"Websock or ALSA functionality not included in this build."); }
|
||||||
cw::rc_t ioTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return _no_alsa_websock(); }
|
cw::rc_t ioTest( const cw::object_t* cfg, const cw::object_t* args, int argc, const char* argv[] ) { return _no_alsa_websock(); }
|
||||||
|
Loading…
Reference in New Issue
Block a user