51 int main (
int argc,
char *argv[])
61 const float default_frame_shift = 0.01;
65 EST_String(
"[input label file] -o [output file] [options]") +
66 "Summary: generate F0 file from tilt or RFC label file\n" 67 "use \"-\" to make input and output files stdin/out\n" 68 "-h Options help\n\n"+
69 "-noconn Synthesize events only - no connections in output\n" 70 "-o <ofile> Output F0 file\n" 71 "-otype <string> File type for output label file\n" 72 "-event_names <string> List of labels to be classed as events. \n" 73 " Lists are specified as quoted strings with spaces \n" 74 " separating each item, e.g.: \"a b c d\"\n\n" 75 "-s <float> Frame spacing of generated contour in seconds\n",
86 for (e = ev.
head(); e; e = e->
next())
88 e->
set(
"start", prev_end);
89 prev_end = e->
F(
"end");
92 pstring = al.
present(
"-event_names") ? al.
val(
"-event_names"):
97 shift = al.
present(
"-s") ? al.
fval(
"-s") : default_frame_shift;
99 if (ev.
f(
"intonation_style") ==
"tilt")
111 fz.
save(out_file, al.
val(
"-otype"));
A class for storing digital waveforms. The waveform is stored as an array of 16 bit shorts...
int override_val(const EST_String rkey, const EST_String rval)
add to end of list or overwrite. If rval is empty, do nothing
void set_channel_name(const EST_String &name, int channel)
set the name of the channel.
void set(const EST_String &name, ssize_t ival)
float fval(const EST_String &rkey, int m=1) const
void rfc_synthesis(EST_Track &f0, EST_Relation &ev_list, float f_shift, int no_conn)
Generate an F0 contour given a list RFC events.
void convert_to_broad(EST_Relation &seg, EST_StrList &pos_list, EST_String broad_name="", int polarity=1)
float F(const EST_String &name) const
void StringtoStrList(EST_String s, EST_StrList &l, EST_String sep)
Convert a EST_String to a EST_StrList by separating tokens in s delimited by the separator sep...
int init_lib_ops(EST_Option &al, EST_Option &options)
EST_write_status save(const EST_String name, const EST_String EST_filetype="")
void override_lib_ops(EST_Option &a_list, EST_Option &al)
void tilt_synthesis(EST_Track &track, EST_Relation &ev_list, float f_shift, int no_conn)
Generate an F0 contour given a list Tilt events.
const T & first() const
return const reference to first item in list
const V & val(const K &rkey, bool m=0) const
return value according to key (const)
void fill_rfc_types(EST_Relation &ev)
int main(int argc, char *argv[])
int present(const K &rkey) const
Returns true if key is present.
EST_read_status load(const EST_String &filename, const EST_String &type="esps")
void extract_channels(EST_Wave &single, const EST_Wave &multi, EST_IList &ch_list)
int parse_command_line(int argc, char *argv[], const EST_String &usage, EST_StrList &files, EST_Option &al, int make_stdio=1)
Utility EST_String Functions header file.