SPRAAK
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Functions
ssp_part1.c File Reference

signal processing master routines More...

Functions

SprSspDescspr_ssp_free (SprSspDesc *ssp_des)
 Free all memory allocated by the signal processing routines. More...
 
void spr_ssp_print_fi (SprStream *fd, SprSspDesc *ssp_des)
 
void spr_ssp_print (SprStream *fd, SprSspDesc *ssp_des)
 
int spr_ssp_reset (SprSspDesc *ssp_des, SprStream *fd, SprKeySet *keys)
 
SprSspDescspr_ssp_setup (const char *script_name, char **line_array)
 
int spr_ssp_modstatus_do (SprSspDesc *ssp_des, SprSspStatus *action, SprMsgId *routine)
 
int spr_ssp_modstatus_load (SprSspDesc *ssp_des, const char *fname)
 
int spr_ssp_modstatus_save (SprSspDesc *ssp_des, const char *fname)
 
int spr_ssp_aux_stream (SprSspDesc *ssp_des, char *name, const SprDT *type, int vlen, void *dest, char *optional_used)
 
int spr_ssp_setup_END (SprSspInfo *Info, const char **descript, void *aux_info)
 
int spr_ssp_process_END (SprSspInfo *Info, const void *frame_in, void *frame_out)
 
int spr_ssp_process (SprSspDesc *ssp_des, void *frame_in)
 
int spr_ssp_flist (SprSspDesc *ssp_des, void ***res_mat, int start)
 
int spr_ssp_fseek (SprSspDesc *ssp_des, int new_pos, int nfr_proc, int mode, int *skip_fseek, int *skip_proc, int modify, SprStream *fd, int reset_pos)
 
void spr_ssp_help (SprStream *fd, int level)
 Print the syntax of all possible commands and routines. More...
 
int spr_ssp_paste (SprMsgId *Routine, SprSspInfo *info, int action, const char *buffer,...)
 
int spr_ssp_new_file (SprSspDesc *ssp_des, const char *obsdir, const char *dfname, const char *suffix)
 
int spr_ssp_process_stream (SprSspDesc *ssp_des, SprStream *fdi, SprStream *fdo, int nfr)
 

Detailed Description

signal processing master routines


[Global_commands]
.fshift <expr>
[matches expressions]
Set the frame shift (only for a sample file). The frame shift can only be set before the first processing routine is called. If not specified, a 10 ms frame shift is used.
.truncate [yes/no](no)
Flag that affects the behaviour of the preprocessing when only a part of the file is processed (e.g. 'sigp -f 1:2'). The default behaviour (without '.truncate' flag) corresponds to preprocessing the whole file followed by a selection of the desired frames. If the flag is set, the preprocessing behaves as if the file was first truncated and then preprocessed.
.trail [mirror/ignore/zero](ignore)
If the last frame of a sample files is incomplete (file length is not an exact multiple of the frame shift), then pad the frame with zeros (or a mirrored version of the last samples), process the frame but do not write the frame out. This creates one more frame which contain some relevant data and which may result in somewhat beter output for modules which also take into account the right context of a frame such as time derivatives.
.history <expr>
[matches expressions]
Force a certain history length.
.var <var> ...
Define variables.
.set <var=expr> ...
Set a variable to a given value / evaluate an expression.
.push keyset
Copy the current key-set in a new one, save the old one for later use.
.pop keyset
Recall a key-set that have been saved earlier (LIFO-stack).
.get_key <var> = <key>
Set a 'string' variable to the content of a given key.
.get_keyvalue <var> = <key>
Set a variable to the numerical value of a given key.
.set_key <key> [value:str/var] ...
Set a key in the key-set. The value may be a variable or a plain string (no surrounding \"\\" allowed).
.unset_key <key> ...
Remove one or more keys from the key-set.
.if <expr> goto <label>
[matches expressions]
A conditional jump. An unconditional jump is created when <expr> equals 'true'. Only forward jumps are allowed. The expression may not contain white-space characters, and must be surrounded by brackets.
.label <label_name>
Indicates a possible jump location.
.msg <error/warning/info> <txt> ...
Give an error message. If the <error> mode is selected, the master setup (in fact, the first reset) will return with an error code, causing the main program to stop.
.convert to <new_type:str/var>
Convert the data to a given type. The type may be a variable or a plain string (no surrounding \"\\" allowed).
.mix <start:step:repeat> ...
[matches expressions]
Select parameters and/or rearrange the order of the parameters in the process buffer.
.read <mc_begin/mc_end/begin/end> <file_name>
Read a frame from a file. A '@' in the file name is replaced with the input file base name. The data can be inserted at the beginning or at the end of the frame in the process buffer, or can be intermixed (Multi Channel prefix) with the process buffer.
.write <copy/move> <file_name> [start:step:repeat] ...
Write a part of the frame in the process buffer to a given file. A '@' in the file name is replaced with the input file base name. If the <move> operation is chosen, the selected data is removed from the process buffer.
.recall <begin/end> <copy/move> <buffer_name>
Recall a previously stored frame from a named buffer. The data can be inserted at the beginning or at the end of the frame in the process buffer. If the <copy> operation is selected, the data is not removed from the named buffer, so it can be recalled again later on. The last recall operation must (re)<move> the data from the named buffer.
.store <copy/move> <buffer_name> [start:step:repeat] ...
Store a part of the process buffer to a named buffer for later use. If the <move> operation is selected, the selected data is also removed from the process buffer.
.debug <debug_level> [parameter_selection] ...
Echo the selected parameters to the debug system at the given level.


[Select_commands]
COPY <begin/end> [start:step:repeat] ...
Select a set of parameters that must be copied unmodified to the output frame for the current module. By default, no parameters are copied.
PROCESS [start:step:repeat] ...
Select the set of parameters that must be processed by the current module. Two COPYs may occur, one at the beginning and one at the end of the result frame. By default, all parameters are processed.

Date
10/10/94
Author
Kris Demuynck