mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 21:25:19 -05:00
Get rid of unused return values, except the one from decode_chunk() which will be used in the dual core split.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19236 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
ffc6766a4d
commit
5b0d74a7d3
7 changed files with 38 additions and 41 deletions
|
|
@ -82,7 +82,6 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
|
|||
int32_t* decoded0, int32_t* decoded1,
|
||||
int count)
|
||||
{
|
||||
int res;
|
||||
int32_t left, right;
|
||||
#ifdef ROCKBOX
|
||||
int scale = (APE_OUTPUT_DEPTH - ape_ctx->bps);
|
||||
|
|
@ -93,11 +92,11 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
|
|||
|
||||
if ((ape_ctx->channels==1) || (ape_ctx->frameflags & APE_FRAMECODE_PSEUDO_STEREO)) {
|
||||
if (ape_ctx->frameflags & APE_FRAMECODE_STEREO_SILENCE) {
|
||||
res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
|
||||
entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
|
||||
/* We are pure silence, so we're done. */
|
||||
return 0;
|
||||
} else {
|
||||
res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, NULL, count);
|
||||
entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, NULL, count);
|
||||
}
|
||||
|
||||
switch (ape_ctx->compressiontype)
|
||||
|
|
@ -143,7 +142,7 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
|
|||
return 0;
|
||||
}
|
||||
|
||||
res = entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
|
||||
entropy_decode(ape_ctx, inbuffer, firstbyte, bytesconsumed, decoded0, decoded1, count);
|
||||
|
||||
/* Apply filters - compression type 1000 doesn't have any */
|
||||
switch (ape_ctx->compressiontype)
|
||||
|
|
@ -184,6 +183,5 @@ int ICODE_ATTR_DEMAC decode_chunk(struct ape_ctx_t* ape_ctx,
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
return res;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -419,11 +419,11 @@ void init_entropy_decoder(struct ape_ctx_t* ape_ctx,
|
|||
*firstbyte = bytebufferoffset;
|
||||
}
|
||||
|
||||
int ICODE_ATTR_DEMAC entropy_decode(struct ape_ctx_t* ape_ctx,
|
||||
unsigned char* inbuffer, int* firstbyte,
|
||||
int* bytesconsumed,
|
||||
int32_t* decoded0, int32_t* decoded1,
|
||||
int blockstodecode)
|
||||
void ICODE_ATTR_DEMAC entropy_decode(struct ape_ctx_t* ape_ctx,
|
||||
unsigned char* inbuffer, int* firstbyte,
|
||||
int* bytesconsumed,
|
||||
int32_t* decoded0, int32_t* decoded1,
|
||||
int blockstodecode)
|
||||
{
|
||||
bytebuffer = inbuffer;
|
||||
bytebufferoffset = *firstbyte;
|
||||
|
|
@ -458,6 +458,4 @@ int ICODE_ATTR_DEMAC entropy_decode(struct ape_ctx_t* ape_ctx,
|
|||
/* Return the new state of the buffer */
|
||||
*bytesconsumed = bytebuffer - inbuffer;
|
||||
*firstbyte = bytebufferoffset;
|
||||
|
||||
return(0);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
libdemac - A Monkey's Audio decoder
|
||||
|
||||
$Id:$
|
||||
$Id$
|
||||
|
||||
Copyright (C) Dave Chapman 2007
|
||||
|
||||
|
|
@ -31,10 +31,10 @@ void init_entropy_decoder(struct ape_ctx_t* ape_ctx,
|
|||
unsigned char* inbuffer, int* firstbyte,
|
||||
int* bytesconsumed);
|
||||
|
||||
int entropy_decode(struct ape_ctx_t* ape_ctx,
|
||||
unsigned char* inbuffer, int* firstbyte,
|
||||
int* bytesconsumed,
|
||||
int32_t* decoded0, int32_t* decoded1,
|
||||
int blockstodecode);
|
||||
void entropy_decode(struct ape_ctx_t* ape_ctx,
|
||||
unsigned char* inbuffer, int* firstbyte,
|
||||
int* bytesconsumed,
|
||||
int32_t* decoded0, int32_t* decoded1,
|
||||
int blockstodecode);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -237,8 +237,8 @@ void INIT_FILTER(filter_int* buf)
|
|||
do_init_filter(&filter1, buf + ORDER*3 + FILTER_HISTORY_SIZE);
|
||||
}
|
||||
|
||||
int ICODE_ATTR_DEMAC APPLY_FILTER(int fileversion, int32_t* data0,
|
||||
int32_t* data1, int count)
|
||||
void ICODE_ATTR_DEMAC APPLY_FILTER(int fileversion, int32_t* data0,
|
||||
int32_t* data1, int count)
|
||||
{
|
||||
if (fileversion >= 3980) {
|
||||
do_apply_filter_3980(&filter0, data0, count);
|
||||
|
|
@ -249,6 +249,4 @@ int ICODE_ATTR_DEMAC APPLY_FILTER(int fileversion, int32_t* data0,
|
|||
if (data1 != NULL)
|
||||
do_apply_filter_3970(&filter1, data1, count);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,18 +28,23 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
|
|||
#include "demac_config.h"
|
||||
|
||||
void init_filter_16_11(filter_int* buf);
|
||||
int apply_filter_16_11(int fileversion, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
void apply_filter_16_11(int fileversion, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
|
||||
void init_filter_64_11(filter_int* buf);
|
||||
int apply_filter_64_11(int fileversion, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
void apply_filter_64_11(int fileversion, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
|
||||
void init_filter_32_10(filter_int* buf);
|
||||
int apply_filter_32_10(int fileversion, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
void apply_filter_32_10(int fileversion, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
|
||||
void init_filter_256_13(filter_int* buf);
|
||||
int apply_filter_256_13(int fileversion, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
void apply_filter_256_13(int fileversion, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
|
||||
void init_filter_1280_15(filter_int* buf);
|
||||
int apply_filter_1280_15(int fileversion, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
void apply_filter_1280_15(int fileversion, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -68,10 +68,10 @@ void init_predictor_decoder(struct predictor_t* p)
|
|||
}
|
||||
|
||||
#if !defined(CPU_ARM) && !defined(CPU_COLDFIRE)
|
||||
int ICODE_ATTR_DEMAC predictor_decode_stereo(struct predictor_t* p,
|
||||
int32_t* decoded0,
|
||||
int32_t* decoded1,
|
||||
int count)
|
||||
void ICODE_ATTR_DEMAC predictor_decode_stereo(struct predictor_t* p,
|
||||
int32_t* decoded0,
|
||||
int32_t* decoded1,
|
||||
int count)
|
||||
{
|
||||
int32_t predictionA, predictionB;
|
||||
|
||||
|
|
@ -208,14 +208,12 @@ int ICODE_ATTR_DEMAC predictor_decode_stereo(struct predictor_t* p,
|
|||
p->buf = p->historybuffer;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
int ICODE_ATTR_DEMAC predictor_decode_mono(struct predictor_t* p,
|
||||
int32_t* decoded0,
|
||||
int count)
|
||||
void ICODE_ATTR_DEMAC predictor_decode_mono(struct predictor_t* p,
|
||||
int32_t* decoded0,
|
||||
int count)
|
||||
{
|
||||
int32_t predictionA, currentA, A;
|
||||
|
||||
|
|
@ -270,6 +268,4 @@ int ICODE_ATTR_DEMAC predictor_decode_mono(struct predictor_t* p,
|
|||
}
|
||||
|
||||
p->YlastA = currentA;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,7 +30,9 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA
|
|||
#include "filter.h"
|
||||
|
||||
void init_predictor_decoder(struct predictor_t* p);
|
||||
int predictor_decode_stereo(struct predictor_t* p, int32_t* decoded0, int32_t* decoded1, int count);
|
||||
int predictor_decode_mono(struct predictor_t* p, int32_t* decoded0, int count);
|
||||
void predictor_decode_stereo(struct predictor_t* p, int32_t* decoded0,
|
||||
int32_t* decoded1, int count);
|
||||
void predictor_decode_mono(struct predictor_t* p, int32_t* decoded0,
|
||||
int count);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue