Lines Matching refs:halEvent
48 void soundModelCallback_(struct sound_trigger_model_event* halEvent, void* cookie) { in soundModelCallback_() argument
49 if (halEvent == NULL) { in soundModelCallback_()
60 if (halEvent->model != client->getHalHandle()) { in soundModelCallback_()
62 (int)halEvent->model, (int)client->getHalHandle()); in soundModelCallback_()
66 client->soundModelCallback(halEvent); in soundModelCallback_()
70 void recognitionCallback_(struct sound_trigger_recognition_event* halEvent, void* cookie) { in recognitionCallback_() argument
71 if (halEvent == NULL) { in recognitionCallback_()
83 client->recognitionCallback(halEvent); in recognitionCallback_()
458 const struct sound_trigger_model_event* halEvent) { in convertSoundModelEventFromHal() argument
459 event->status = (V2_0::ISoundTriggerHwCallback::SoundModelStatus)halEvent->status; in convertSoundModelEventFromHal()
462 const_cast<uint8_t*>(reinterpret_cast<const uint8_t*>(halEvent)) + halEvent->data_offset, in convertSoundModelEventFromHal()
463 halEvent->data_size); in convertSoundModelEventFromHal()
469 const struct sound_trigger_phrase_recognition_event* halEvent) { in convertPhaseRecognitionEventFromHal() argument
470 event->phraseExtras.resize(halEvent->num_phrases); in convertPhaseRecognitionEventFromHal()
471 for (unsigned int i = 0; i < halEvent->num_phrases; i++) { in convertPhaseRecognitionEventFromHal()
472 convertPhraseRecognitionExtraFromHal(&event->phraseExtras[i], &halEvent->phrase_extras[i]); in convertPhaseRecognitionEventFromHal()
474 convertRecognitionEventFromHal(&event->common, &halEvent->common); in convertPhaseRecognitionEventFromHal()
480 const struct sound_trigger_recognition_event* halEvent) { in convertRecognitionEventFromHal() argument
481 event->status = static_cast<V2_0::ISoundTriggerHwCallback::RecognitionStatus>(halEvent->status); in convertRecognitionEventFromHal()
482 event->type = static_cast<V2_0::SoundModelType>(halEvent->type); in convertRecognitionEventFromHal()
484 event->captureAvailable = halEvent->capture_available; in convertRecognitionEventFromHal()
485 event->captureSession = halEvent->capture_session; in convertRecognitionEventFromHal()
486 event->captureDelayMs = halEvent->capture_delay_ms; in convertRecognitionEventFromHal()
487 event->capturePreambleMs = halEvent->capture_preamble_ms; in convertRecognitionEventFromHal()
488 event->triggerInData = halEvent->trigger_in_data; in convertRecognitionEventFromHal()
489 event->audioConfig.sampleRateHz = halEvent->audio_config.sample_rate; in convertRecognitionEventFromHal()
491 (audio::common::V2_0::AudioChannelMask)halEvent->audio_config.channel_mask; in convertRecognitionEventFromHal()
492 event->audioConfig.format = (audio::common::V2_0::AudioFormat)halEvent->audio_config.format; in convertRecognitionEventFromHal()
494 const_cast<uint8_t*>(reinterpret_cast<const uint8_t*>(halEvent)) + halEvent->data_offset, in convertRecognitionEventFromHal()
495 halEvent->data_size); in convertRecognitionEventFromHal()
514 struct sound_trigger_recognition_event* halEvent) { in recognitionCallback() argument
515 if (halEvent->type == SOUND_MODEL_TYPE_KEYPHRASE) { in recognitionCallback()
518 &event, reinterpret_cast<sound_trigger_phrase_recognition_event*>(halEvent)); in recognitionCallback()
523 convertRecognitionEventFromHal(&event, halEvent); in recognitionCallback()
530 struct sound_trigger_model_event* halEvent) { in soundModelCallback() argument
532 convertSoundModelEventFromHal(&event, halEvent); in soundModelCallback()
654 struct sound_trigger_recognition_event* halEvent) { in recognitionCallback() argument
655 if (halEvent->type == SOUND_MODEL_TYPE_KEYPHRASE) { in recognitionCallback()
658 &event_2_0, reinterpret_cast<sound_trigger_phrase_recognition_event*>(halEvent)); in recognitionCallback()
671 convertRecognitionEventFromHal(&event.header, halEvent); in recognitionCallback()
681 struct sound_trigger_model_event* halEvent) { in soundModelCallback() argument
683 convertSoundModelEventFromHal(&event.header, halEvent); in soundModelCallback()