Skip to content

Commit

Permalink
helix-aac: add MACRO for PNS feature to disable MPEG4 support
Browse files Browse the repository at this point in the history
Signed-off-by: ligd <[email protected]>
  • Loading branch information
GUIDINGLI committed Jan 14, 2025
1 parent 5c67787 commit fdd6b5a
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
4 changes: 4 additions & 0 deletions aaccommon.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@
#include "Arduino.h"
//#include <pgmspace.h>

#ifdef CONFIG_LIB_HELIX_AAC_PNS
#define AAC_ENABLE_PNS 1
#endif

#ifdef CONFIG_LIB_HELIX_AAC_SBR
#define AAC_ENABLE_SBR 1
#endif
Expand Down
14 changes: 14 additions & 0 deletions pns.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
#include "coder.h"
#include "assembly.h"

#ifdef AAC_ENABLE_PNS

/**************************************************************************************
* Function: Get32BitVal
*
Expand Down Expand Up @@ -363,3 +365,15 @@ int PNS(AACDecInfo *aacDecInfo, int ch)

return 0;
}

#else

int PNS(AACDecInfo *aacDecInfo, int ch)
{
if (aacDecInfo->pnsUsed)
return ERR_AAC_PNS;
else
return ERR_AAC_NONE;
}

#endif

0 comments on commit fdd6b5a

Please sign in to comment.