|
From: Patrick <hum...@gm...> - 2012-12-04 00:44:16
|
When two input files and one output file is required for an effect such as the splice effect, how should the sox_open_read() method be called?
A typical libsox routine would look something like:
in=sox_open_read(file_path_in, NULL, NULL, NULL);
out=sox_open_write(file_path_out, &in->signal, NULL, NULL, NULL, NULL);
chain = sox_create_effects_chain(&in->encoding, &out->encoding);
e = sox_create_effect(sox_find_effect("input"));
args[0] = (char *)in, assert(sox_effect_options(e, 1, args) == SOX_SUCCESS);
assert(sox_add_effect(chain, e, &in->signal, &in->signal) == SOX_SUCCESS);
e = sox_create_effect(sox_find_effect("speed"));
args[0] = 5,
assert(sox_effect_options(e, 1, args) == SOX_SUCCESS);
assert(sox_add_effect(chain, e, &in->signal, &in->signal) == SOX_SUCCESS);
I want to use the "splice" effect which requires 2 input files to combine into one output.
Any help would be appreciated.
Pat |