#include <julius/julius.h>
#include <signal.h>
Go to the source code of this file.
Defines | |
#define | GLOBAL_VARIABLE_DEFINE |
Actually make global vars in global.h. | |
Functions | |
SentenceAlign * | result_align_new () |
allocate storage of recognition alignment results. | |
void | result_align_free (SentenceAlign *a) |
free storage of recognition alignment results. | |
void | result_sentence_malloc (RecogProcess *r, int num) |
Allocate storage of recognition results. | |
void | result_sentence_free (RecogProcess *r) |
Free storage of recognition results. | |
void | clear_result (RecogProcess *r) |
Clear all result storages for next input. | |
int | adin_cut_callback_store_buffer (SP16 *now, int len, Recog *recog) |
adin_go() callback to score triggered inputs to buffer. | |
static int | callback_check_in_adin (Recog *recog) |
callback function periodically called while input. | |
int | j_open_stream (Recog *recog, char *file_or_dev_name) |
Open input stream. | |
int | j_close_stream (Recog *recog) |
Close input stream. | |
static void | result_error (Recog *recog, int status) |
Recognition error handling. | |
static int | j_recognize_stream_core (Recog *recog) |
Execute recognition. | |
int | j_recognize_stream (Recog *recog) |
Recognize an input stream. |
Definition in file recogmain.c.
SentenceAlign* result_align_new | ( | ) |
allocate storage of recognition alignment results.
Definition at line 210 of file recogmain.c.
Referenced by do_alignment_all().
Here is the caller graph for this function:
void result_align_free | ( | SentenceAlign * | a | ) |
free storage of recognition alignment results.
a | [i/o] alignment data to be released |
Definition at line 242 of file recogmain.c.
Referenced by result_sentence_free().
Here is the caller graph for this function:
void result_sentence_malloc | ( | RecogProcess * | r, | |
int | num | |||
) |
Allocate storage of recognition results.
r | [out] recognition process instance | |
num | [in] number of sentences to be output |
Definition at line 270 of file recogmain.c.
Referenced by j_recognize_stream_core().
Here is the caller graph for this function:
void result_sentence_free | ( | RecogProcess * | r | ) |
Free storage of recognition results.
r | [i/o] recognition process instance |
Definition at line 292 of file recogmain.c.
Referenced by clear_result().
Here is the caller graph for this function:
void clear_result | ( | RecogProcess * | r | ) |
Clear all result storages for next input.
r | [in] recognition process instance. |
Definition at line 324 of file recogmain.c.
Referenced by j_recognize_stream_core().
Here is the caller graph for this function:
adin_go() callback to score triggered inputs to buffer.
This function records the incomping speech segments detected in adin_go() to recog->speech. This function will be used when recognition runs in buffered mode (= non-realtime mode).
now | [in] input speech samples. | |
len | [in] length of now in samples | |
recog | [i/o] engine instance |
Definition at line 385 of file recogmain.c.
Referenced by j_recognize_stream_core(), and RealTimePipeLine().
static int callback_check_in_adin | ( | Recog * | recog | ) | [static] |
callback function periodically called while input.
This function will be called periodically from adin_go() while waiting input or processing recognition. It will call user-defined callback registered in CALLBACK_POLL, check for the process status and issue recognition termination request.
recog | [in] engine instance |
Definition at line 443 of file recogmain.c.
Referenced by j_recognize_stream_core().
static void result_error | ( | Recog * | recog, | |
int | status | |||
) | [static] |
Recognition error handling.
recog | [in] engine instance | |
status | [in] error status to be set |
Definition at line 614 of file recogmain.c.
Referenced by j_recognize_stream_core().
static int j_recognize_stream_core | ( | Recog * | recog | ) | [static] |
Execute recognition.
This function repeats recognition sequences until the input stream reached its end. It detects speech segment (if needed), recognize the detected segment, output result, and go back to the first.
This function will be stopped and exited if reached end of stream (mostly in case of file input), some error has been occured, or termination requested from application by calling j_request_pause() and j_request_terminate().
recog | [i/o] engine instance |
Definition at line 674 of file recogmain.c.
Referenced by j_recognize_stream().