Home | History | Annotate | Download | only in lib

Lines Matching refs:ctrl

69  *  shortcut     : ctrl
94 register ctrl_subobj_t * ctrl;
101 ctrl = (ctrl_subobj_t *) this->subObj;
102 ctrl->curPU = 0;
103 ctrl->lastItemTypeProduced=0; /*no item produced by default*/
105 for (i = 0; i < ctrl->numProcUnits; i++) {
107 status = ctrl->procUnit[i]->initialize(ctrl->procUnit[i], resetMode);
111 status = picodata_cbReset(ctrl->procCbOut[i]);
140 register ctrl_subobj_t * ctrl = (ctrl_subobj_t *) this->subObj;
148 ctrl->lastItemTypeProduced=0; /*no item produced by default*/
153 status = ctrl->procStatus[ctrl->curPU] = ctrl->procUnit[ctrl->curPU]->step(
154 ctrl->procUnit[ctrl->curPU], mode, &puBytesOutput);
160 btype = picodata_cbGetFrontItemType(ctrl->procUnit[ctrl->curPU]->cbOut);
161 ctrl->lastItemTypeProduced=(picoos_uint8)btype;
164 if (ctrl->curPU < ctrl->numProcUnits-1) {
166 ctrl->procStatus[ctrl->curPU + 1] = PICODATA_PU_BUSY;
181 if ( (ctrl->curPU+1 < ctrl->numProcUnits) && (PICODATA_PU_BUSY
182 == ctrl->procStatus[ctrl->curPU+1])) {
183 ctrl->curPU++;
190 if ( (ctrl->curPU+1 < ctrl->numProcUnits) && (PICODATA_PU_BUSY
191 == ctrl->procStatus[ctrl->curPU+1])) {
193 ctrl->curPU++;
194 } else if (0 == ctrl->curPU) { /* all pu's are idle */
199 ctrl->curPU, ctrl->procStatus[ctrl->curPU]));
200 while ((ctrl->curPU > 0) && (PICODATA_PU_IDLE
201 == ctrl->procStatus[ctrl->curPU])) {
202 ctrl->curPU--;
204 ctrl->procStatus[ctrl->curPU] = PICODATA_PU_BUSY;
207 ctrl->curPU, ctrl->procStatus[ctrl->curPU]));
209 return ctrl->procStatus[ctrl->curPU];
214 if (ctrl->curPU+1 < ctrl->numProcUnits) { /* let pu below empty buffer */
215 ctrl->curPU++;
216 ctrl->procStatus[ctrl->curPU] = PICODATA_PU_BUSY;
220 return ctrl->procStatus[ctrl->curPU];
239 register ctrl_subobj_t * ctrl;
243 ctrl = (ctrl_subobj_t *) this->subObj;
244 for (i = 0; i < ctrl->numProcUnits; i++) {
245 status = ctrl->procUnit[i]->terminate(ctrl->procUnit[i]);
264 register ctrl_subobj_t * ctrl;
270 ctrl = (ctrl_subobj_t *) this->subObj;
273 for (i = ctrl->numProcUnits-1; i >= 0; i--) {
274 picodata_disposeProcessingUnit(this->common->mm,&ctrl->procUnit[i]);
275 picodata_disposeCharBuffer(this->common->mm, &ctrl->procCbOut[i]);
301 register ctrl_subobj_t * ctrl;
307 ctrl = (ctrl_subobj_t *) this->subObj;
308 if (ctrl == NULL) {
311 newPU = ctrl->numProcUnits;
317 cbIn = ctrl->procCbOut[newPU-1];
321 ctrl->procCbOut[newPU] = this->cbOut;
325 ctrl->procCbOut[newPU] = picodata_newCharBuffer(this->common->mm,
329 (picoos_uint32) ctrl->procCbOut[newPU]));
330 if (NULL == ctrl->procCbOut[newPU]) {
334 ctrl->procStatus[newPU] = PICODATA_PU_IDLE;
339 ctrl->procUnit[newPU] = picotok_newTokenizeUnit(this->common->mm,
340 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
344 ctrl->procUnit[newPU] = picopr_newPreprocUnit(this->common->mm,
345 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
349 ctrl->procUnit[newPU] = picowa_newWordAnaUnit(this->common->mm,
350 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
354 ctrl->procUnit[newPU] = picosa_newSentAnaUnit(this->common->mm,
355 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
359 ctrl->procUnit[newPU] = picoacph_newAccPhrUnit(this->common->mm,
360 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
364 ctrl->procUnit[newPU] = picospho_newSentPhoUnit(this->common->mm,
365 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
369 ctrl->procUnit[newPU] = picopam_newPamUnit(this->common->mm,
370 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
374 ctrl->procUnit[newPU] = picocep_newCepUnit(this->common->mm,
375 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
380 ctrl->procUnit[newPU] = picosink_newSinkUnit(this->common->mm,
381 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
386 ctrl->procUnit[newPU] = picosig_newSigUnit(this->common->mm,
387 this->common, cbIn, ctrl->procCbOut[newPU], this->voice);
390 ctrl->procUnit[newPU] = picodata_newProcessingUnit(
392 ctrl->procCbOut[newPU], this->voice);
395 if (NULL == ctrl->procUnit[newPU]) {
396 picodata_disposeCharBuffer(this->common->mm,&ctrl->procCbOut[newPU]);
399 ctrl->numProcUnits++;
424 register ctrl_subobj_t * ctrl;
442 ctrl = (ctrl_subobj_t *) this->subObj;
445 ctrl->procUnit[i] = NULL;
446 ctrl->procStatus[i] = PICODATA_PU_IDLE;
447 ctrl->procCbOut[i] = NULL;
449 ctrl->numProcUnits = 0;
466 ctrl->curPU = 0;
806 ctrl_subobj_t * ctrl;
810 ctrl = (ctrl_subobj_t *) ((*this).control->subObj);
811 return (picodata_step_result_t) ctrl->curPU;
827 ctrl_subobj_t * ctrl;
831 ctrl = (ctrl_subobj_t *) ((*this).control->subObj);
832 return (picodata_step_result_t) ctrl->lastItemTypeProduced;