Line 12089: 07-26 14:30:22.666: V/MediaCodecList(729): matching 'OMX.google.amrnb.encoder' Line 12095: 07-2614:30:22.671: V/OMXNodeInstance(702): debug level for OMX.google.amrnb.encoder is 0 Line 12096: 07-2614:30:22.671: I/OMXMaster(702): makeComponentInstance(OMX.google.amrnb.encoder) in mediacodec process Line 12097: 07-26 14:30:22.671: V/SoftOMXPlugin(702): makeComponentInstance 'OMX.google.amrnb.encoder' Line 12099: 07-2614:30:22.675: V/ACodec(729): [OMX.google.amrnb.encoder] Now Loaded Line 12111: 07-2614:30:22.675: E/OMXNodeInstance(702): setConfig(2be0030:google.amrnb.encoder, ConfigPriority(0x6f800002)) ERROR: Undefined(0x80001001) Line 12123: 07-2614:30:22.680: E/OMXNodeInstance(702): setConfig(2be0030:google.amrnb.encoder, ConfigPriority(0x6f800002)) ERROR: Undefined(0x80001001) Line 12131: 07-2614:30:22.683: V/MediaCodec(729): [OMX.google.amrnb.encoder] configured as input format: AMessage(what = 0x00000000) = {
/* Encode WMF or IF2 frames */ if ((output_format == AMR_TX_WMF) | (output_format == AMR_TX_IF2)) { /* Encode one speech frame (20 ms) */
#ifndef CONSOLE_ENCODER_REF
/* Use PV version of sp_enc.c */ GSMEncodeFrame(pEncState, mode, pEncInput, ets_output_bfr, &usedMode);
#else /* Use ETS version of sp_enc.c */ Speech_Encode_Frame(pEncState, mode, pEncInput, ets_output_bfr, &usedMode);
#endif
/* Determine transmit frame type */ sid_sync(pSidSyncState, usedMode, &tx_frame_type);
if (tx_frame_type != TX_NO_DATA) { /* There is data to transmit */ *p3gpp_frame_type = (enum Frame_Type_3GPP) usedMode;
/* Add SID type and mode info for SID frames */ if (*p3gpp_frame_type == AMR_SID) { /* Add SID type to encoder output buffer */ if (tx_frame_type == TX_SID_FIRST) { ets_output_bfr[AMRSID_TXTYPE_BIT_OFFSET] &= 0x0000; } elseif (tx_frame_type == TX_SID_UPDATE) { ets_output_bfr[AMRSID_TXTYPE_BIT_OFFSET] |= 0x0001; }
/* Add mode information bits */ for (i = 0; i < NUM_AMRSID_TXMODE_BITS; i++) { ets_output_bfr[AMRSID_TXMODE_BIT_OFFSET+i] = (mode >> i) & 0x0001; } } } else { /* This is no data to transmit */ *p3gpp_frame_type = (enum Frame_Type_3GPP)AMR_NO_DATA; }
/* At this point, output format is ETS */ /* Determine the output format to use */ if (output_format == AMR_TX_WMF) { /* Change output data format to WMF */ ets_to_wmf(*p3gpp_frame_type, ets_output_bfr, pEncOutput);
/* Set up the number of encoded WMF bytes */ num_enc_bytes = WmfEncBytesPerFrame[(Word16) *p3gpp_frame_type];
} elseif (output_format == AMR_TX_IF2) { /* Change output data format to IF2 */ ets_to_if2(*p3gpp_frame_type, ets_output_bfr, pEncOutput);
/* Set up the number of encoded IF2 bytes */ num_enc_bytes = If2EncBytesPerFrame[(Word16) *p3gpp_frame_type];
/* Use PV version of sp_enc.c */ GSMEncodeFrame(pEncState, mode, pEncInput, &ets_output_bfr[1], &usedMode);
#else /* Use ETS version of sp_enc.c */ Speech_Encode_Frame(pEncState, mode, pEncInput, &ets_output_bfr[1], &usedMode);
#endif
/* Save used mode */ *p3gpp_frame_type = (enum Frame_Type_3GPP) usedMode;
/* Determine transmit frame type */ sid_sync(pSidSyncState, usedMode, &tx_frame_type);
/* Put TX frame type in output buffer */ ets_output_bfr[0] = tx_frame_type;
/* Put mode information after the encoded speech parameters */ if (tx_frame_type != TX_NO_DATA) { ets_output_bfr[1+MAX_SERIAL_SIZE] = (Word16) mode; } else { ets_output_bfr[1+MAX_SERIAL_SIZE] = -1; }
/* Copy output of encoder to pEncOutput buffer */ ets_output_ptr = (UWord8 *) & ets_output_bfr[0];
/* Copy 16-bit data in 8-bit chunks */ /* using Little Endian configuration */ for (i = 0; i < 2*(MAX_SERIAL_SIZE + 2); i++) { *(pEncOutput + i) = *ets_output_ptr; ets_output_ptr += 1; }
/* Set up the number of encoded bytes */ num_enc_bytes = 2 * (MAX_SERIAL_SIZE + 2);
}
/* Invalid frame format */ else { /* Invalid output format, set up error code */ num_enc_bytes = -1; }
/* Type cast state_data to Speech_Decode_FrameState rather than passing * that structure type to this function so the structure make up can't * be viewed from higher level functions than this. */ Speech_Decode_FrameState *decoder_state = (Speech_Decode_FrameState *) state_data;
/* Determine type of de-formatting */ /* WMF or IF2 frames */ if ((input_format == MIME_IETF) | (input_format == IF2)) { if (input_format == MIME_IETF) { /* Convert incoming packetized raw WMF data to ETS format */ wmf_to_ets(frame_type, speech_bits_ptr, dec_ets_input_bfr);
/* Address offset of the start of next frame */ byte_offset = WmfDecBytesPerFrame[frame_type]; } else/* else has to be input_format IF2 */ { /* Convert incoming packetized raw IF2 data to ETS format */ if2_to_ets(frame_type, speech_bits_ptr, dec_ets_input_bfr);
/* Address offset of the start of next frame */ byte_offset = If2DecBytesPerFrame[frame_type]; }
/* At this point, input data is in ETS format */ /* Determine AMR codec mode and AMR RX frame type */ if (frame_type <= AMR_122) { mode = (enum Mode) frame_type; rx_type = RX_SPEECH_GOOD; } elseif (frame_type == AMR_SID) { /* Clear mode store prior to reading mode info from input buffer */ modeStore = 0;
for (i = 0; i < NUM_AMRSID_RXMODE_BITS; i++) { tempInt = dec_ets_input_bfr[AMRSID_RXMODE_BIT_OFFSET+i] << i; modeStore |= tempInt; } mode = (enum Mode) modeStore;
/* * RX_NO_DATA, generate exponential decay from latest valid frame for the first 6 frames * after that, create silent frames */ rx_type = RX_NO_DATA;
}
}
/* ETS frames */ elseif (input_format == ETS) { /* Change type of pointer to incoming raw ETS data */ ets_word_ptr = (Word16 *) speech_bits_ptr;
/* Get RX frame type */ rx_type = (enum RXFrameType) * ets_word_ptr; ets_word_ptr++;
/* Copy incoming raw ETS data to dec_ets_input_bfr */ for (i = 0; i < MAX_SERIAL_SIZE; i++) { dec_ets_input_bfr[i] = *ets_word_ptr; ets_word_ptr++; }
/* Get codec mode */ if (rx_type != RX_NO_DATA) { /* Get mode from input bitstream */ mode = (enum Mode) * ets_word_ptr; } else { /* Use previous mode if no received data */ mode = decoder_state->prev_mode; }
/* Set up byte_offset */ byte_offset = 2 * (MAX_SERIAL_SIZE + 2); } else { /* Invalid input format, return error code */ byte_offset = -1; }
/* Proceed with decoding frame, if there are no errors */ if (byte_offset != -1) { /* Decode a 20 ms frame */
#ifndef CONSOLE_DECODER_REF /* Use PV version of sp_dec.c */ GSMFrameDecode(decoder_state, mode, dec_ets_input_bfr, rx_type, raw_pcm_buffer);
#else /* Use ETS version of sp_dec.c */ Speech_Decode_Frame(decoder_state, mode, dec_ets_input_bfr, rx_type, raw_pcm_buffer);
#endif
/* Save mode for next frame */ decoder_state->prev_mode = mode; }