Skip to content

Commit

Permalink
Use defines for number of EXSS channel sets.
Browse files Browse the repository at this point in the history
  • Loading branch information
foo86 committed Dec 14, 2015
1 parent 8cf6a42 commit b32e72f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
10 changes: 5 additions & 5 deletions libdcadec/core_decoder.c
Expand Up @@ -1392,9 +1392,9 @@ static int parse_xbr_subframe(struct core_decoder *core, int xbr_base_ch, int xb

static int parse_xbr_frame(struct core_decoder *core)
{
int xbr_frame_size[4];
int xbr_nchannels[4];
int xbr_nsubbands[4 * 8];
int xbr_frame_size[MAX_EXSS_CHSETS];
int xbr_nchannels[MAX_EXSS_CHSETS];
int xbr_nsubbands[MAX_EXSS_CHSETS * MAX_CHANNELS_CHSET];

int header_pos = core->bits.index;

Expand Down Expand Up @@ -1894,8 +1894,8 @@ static int parse_x96_frame(struct core_decoder *core)

static int parse_x96_frame_exss(struct core_decoder *core)
{
int x96_frame_size[4];
int x96_nchannels[4];
int x96_frame_size[MAX_EXSS_CHSETS];
int x96_nchannels[MAX_EXSS_CHSETS];

int header_pos = core->bits.index;

Expand Down
3 changes: 3 additions & 0 deletions libdcadec/core_decoder.h
Expand Up @@ -35,6 +35,9 @@
#define MAX_CHANNELS_CORE 6
#define MAX_CHANNELS_DMIX 4
#define MAX_CHANNELS_XXCH 2
#define MAX_CHANNELS_CHSET 8

#define MAX_EXSS_CHSETS 4

#define core_err(...) dca_log(ERROR, core, __VA_ARGS__)
#define core_warn(...) dca_log(WARNING, core, __VA_ARGS__)
Expand Down

0 comments on commit b32e72f

Please sign in to comment.