Lines Matching refs:hAacEnc
312 AAC_ENC *hAacEnc = NULL; in FDKaacEnc_Open() local
320 hAacEnc = GetRam_aacEnc_AacEncoder(); in FDKaacEnc_Open()
321 if (hAacEnc == NULL) { in FDKaacEnc_Open()
325 FDKmemclear(hAacEnc, sizeof(AAC_ENC)); in FDKaacEnc_Open()
327 hAacEnc->dynamic_RAM = GetAACdynamic_RAM(); in FDKaacEnc_Open()
328 dynamicRAM = (UCHAR*)hAacEnc->dynamic_RAM; in FDKaacEnc_Open()
331 ErrorStatus = FDKaacEnc_PsyNew(&hAacEnc->psyKernel, in FDKaacEnc_Open()
339 ErrorStatus = FDKaacEnc_PsyOutNew(hAacEnc->psyOut, in FDKaacEnc_Open()
349 ErrorStatus = FDKaacEnc_QCOutNew(hAacEnc->qcOut, in FDKaacEnc_Open()
359 ErrorStatus = FDKaacEnc_QCNew(&hAacEnc->qcKernel, in FDKaacEnc_Open()
366 hAacEnc->maxChannels = nChannels; in FDKaacEnc_Open()
367 hAacEnc->maxElements = nElements; in FDKaacEnc_Open()
368 hAacEnc->maxFrames = nSubFrames; in FDKaacEnc_Open()
371 *phAacEnc = hAacEnc; in FDKaacEnc_Open()
376 AAC_ENCODER_ERROR FDKaacEnc_Initialize(HANDLE_AAC_ENC hAacEnc, in FDKaacEnc_Initialize() argument
477 &hAacEnc->ancillaryBitsPerFrame, in FDKaacEnc_Initialize()
484 …config->ancDataBitRate += ( (hAacEnc->ancillaryBitsPerFrame * config->sampleRate) / config->framel… in FDKaacEnc_Initialize()
499 hAacEnc->config = config; in FDKaacEnc_Initialize()
502 hAacEnc->bitrateMode = (AACENC_BITRATE_MODE)config->bitrateMode; in FDKaacEnc_Initialize()
504 hAacEnc->encoderMode = config->channelMode; in FDKaacEnc_Initialize()
506 …ErrorStatus = FDKaacEnc_InitChannelMapping(hAacEnc->encoderMode, config->channelOrder, &hAacEnc->c… in FDKaacEnc_Initialize()
510 cm = &hAacEnc->channelMapping; in FDKaacEnc_Initialize()
512 ErrorStatus = FDKaacEnc_DetermineBandWidth(&hAacEnc->config->bandWidth, in FDKaacEnc_Initialize()
515 hAacEnc->bitrateMode, in FDKaacEnc_Initialize()
519 hAacEnc->encoderMode); in FDKaacEnc_Initialize()
523 hAacEnc->bandwidth90dB = (INT)hAacEnc->config->bandWidth; in FDKaacEnc_Initialize()
528 ErrorStatus = FDKaacEnc_psyInit(hAacEnc->psyKernel, in FDKaacEnc_Initialize()
529 hAacEnc->psyOut, in FDKaacEnc_Initialize()
530 hAacEnc->maxFrames, in FDKaacEnc_Initialize()
531 hAacEnc->maxChannels, in FDKaacEnc_Initialize()
537 ErrorStatus = FDKaacEnc_psyMainInit(hAacEnc->psyKernel, in FDKaacEnc_Initialize()
544 hAacEnc->bandwidth90dB, in FDKaacEnc_Initialize()
552 ErrorStatus = FDKaacEnc_QCOutInit(hAacEnc->qcOut, hAacEnc->maxFrames, cm); in FDKaacEnc_Initialize()
558 qcInit.channelMapping = &hAacEnc->channelMapping; in FDKaacEnc_Initialize()
587 bw_ratio = fDivNorm((FIXP_DBL)hAacEnc->bandwidth90dB, (FIXP_DBL)(config->sampleRate>>1), &qbw); in FDKaacEnc_Initialize()
648 ErrorStatus = FDKaacEnc_QCInit(hAacEnc->qcKernel, &qcInit); in FDKaacEnc_Initialize()
653 switch (hAacEnc->config->audioObjectType) { in FDKaacEnc_Initialize()
656 hAacEnc->aot = AOT_AAC_LC; in FDKaacEnc_Initialize()
660 hAacEnc->aot = AOT_SBR; in FDKaacEnc_Initialize()
664 hAacEnc->aot = AOT_PS; in FDKaacEnc_Initialize()
667 hAacEnc->aot = hAacEnc->config->audioObjectType; in FDKaacEnc_Initialize()
687 AAC_ENCODER_ERROR FDKaacEnc_EncodeFrame( HANDLE_AAC_ENC hAacEnc, /* encoder handle */ in FDKaacEnc_EncodeFrame() argument
698 CHANNEL_MAPPING *cm = &hAacEnc->channelMapping; in FDKaacEnc_EncodeFrame()
702 PSY_OUT *psyOut = hAacEnc->psyOut[c]; in FDKaacEnc_EncodeFrame()
703 QC_OUT *qcOut = hAacEnc->qcOut[c]; in FDKaacEnc_EncodeFrame()
736 hAacEnc->psyKernel->psyElement[el], in FDKaacEnc_EncodeFrame()
737 hAacEnc->psyKernel->psyDynamic, in FDKaacEnc_EncodeFrame()
738 hAacEnc->psyKernel->psyConf, in FDKaacEnc_EncodeFrame()
748 hAacEnc->qcKernel->hAdjThr->adjThrStateElem[el], in FDKaacEnc_EncodeFrame()
751 hAacEnc->aot, in FDKaacEnc_EncodeFrame()
752 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
753 hAacEnc->config->epConfig); in FDKaacEnc_EncodeFrame()
781 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
782 hAacEnc->aot, in FDKaacEnc_EncodeFrame()
783 hAacEnc->config->epConfig ); in FDKaacEnc_EncodeFrame()
813 if (hAacEnc->ancillaryBitsPerFrame) { in FDKaacEnc_EncodeFrame()
815 payloadBits = hAacEnc->ancillaryBitsPerFrame; in FDKaacEnc_EncodeFrame()
819 if ((extPayload[n].dataSize>>3) <= hAacEnc->config->maxAncBytesPerAU) { in FDKaacEnc_EncodeFrame()
839 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
840 hAacEnc->aot, in FDKaacEnc_EncodeFrame()
841 hAacEnc->config->epConfig ); in FDKaacEnc_EncodeFrame()
851 if (!(hAacEnc->config->syntaxFlags & (AC_SCALABLE|AC_ER))) { in FDKaacEnc_EncodeFrame()
865 FDKaacEnc_AdjustBitrate(hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
868 hAacEnc->config->bitRate, in FDKaacEnc_EncodeFrame()
869 hAacEnc->config->sampleRate, in FDKaacEnc_EncodeFrame()
870 hAacEnc->config->framelength); in FDKaacEnc_EncodeFrame()
873 avgTotalBits *= hAacEnc->config->nSubFrames; in FDKaacEnc_EncodeFrame()
878 …hAacEnc->qcKernel->globHdrBits = transportEnc_GetStaticBits(hTpEnc, avgTotalBits + hAacEnc->qcKern… in FDKaacEnc_EncodeFrame()
885 ErrorStatus = FDKaacEnc_QCMain(hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
886 hAacEnc->psyOut, in FDKaacEnc_EncodeFrame()
887 hAacEnc->qcOut, in FDKaacEnc_EncodeFrame()
890 ,hAacEnc->aot, in FDKaacEnc_EncodeFrame()
891 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
892 hAacEnc->config->epConfig); in FDKaacEnc_EncodeFrame()
900 hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
901 hAacEnc->qcKernel->elementBits, in FDKaacEnc_EncodeFrame()
902 hAacEnc->qcOut); in FDKaacEnc_EncodeFrame()
908 hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
912 hAacEnc->aot, in FDKaacEnc_EncodeFrame()
913 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
914 hAacEnc->config->epConfig); in FDKaacEnc_EncodeFrame()
923 hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
924 hAacEnc->qcOut); in FDKaacEnc_EncodeFrame()
933 … FDKaacEnc_EncBitresToTpBitres(hAacEnc->bitrateMode, hAacEnc->qcKernel->bitResTot), in FDKaacEnc_EncodeFrame()
942 hAacEnc->qcKernel, in FDKaacEnc_EncodeFrame()
943 hAacEnc->aot, in FDKaacEnc_EncodeFrame()
944 hAacEnc->config->syntaxFlags, in FDKaacEnc_EncodeFrame()
945 hAacEnc->config->epConfig); in FDKaacEnc_EncodeFrame()
973 AAC_ENC *hAacEnc = (AAC_ENC*)*phAacEnc; in FDKaacEnc_Close() local
975 if (hAacEnc->dynamic_RAM != NULL) in FDKaacEnc_Close()
976 FreeAACdynamic_RAM(&hAacEnc->dynamic_RAM); in FDKaacEnc_Close()
978 FDKaacEnc_PsyClose(&hAacEnc->psyKernel,hAacEnc->psyOut); in FDKaacEnc_Close()
980 FDKaacEnc_QCClose(&hAacEnc->qcKernel, hAacEnc->qcOut); in FDKaacEnc_Close()