Whitespace cleanup

Signed-off-by: Alexander Golubev <fatzer2@gmail.com>
master
Alexander Golubev 3 weeks ago
parent 6e0631b21a
commit baa4672751

@ -13,12 +13,12 @@ MPC_INT64 StreamInfo::GetLenthSamples()
} else { } else {
samples -= MPC_decoder::SynthDelay; samples -= MPC_decoder::SynthDelay;
} }
return samples; return samples;
} }
double StreamInfo::GetLength() double StreamInfo::GetLength()
{ {
return (double)GetLenthSamples() / (double)simple.SampleFreq; return (double)GetLenthSamples() / (double)simple.SampleFreq;
} }

@ -41,103 +41,103 @@ MPC_decoder::RESET_Globals ( void )
unsigned int unsigned int
MPC_decoder::decode_internal ( MPC_SAMPLE_FORMAT *buffer ) MPC_decoder::decode_internal ( MPC_SAMPLE_FORMAT *buffer )
{ {
unsigned int output_frame_length = FrameLength; unsigned int output_frame_length = FrameLength;
unsigned int FrameBitCnt = 0; unsigned int FrameBitCnt = 0;
if ( DecodedFrames >= OverallFrames ) if ( DecodedFrames >= OverallFrames )
return (unsigned int)(-1); // end of file -> abort decoding return (unsigned int)(-1); // end of file -> abort decoding
// read jump-info for validity check of frame // read jump-info for validity check of frame
FwdJumpInfo = Bitstream_read (20); FwdJumpInfo = Bitstream_read (20);
SeekTable [DecodedFrames] = 20 + FwdJumpInfo; // ... SeekTable [DecodedFrames] = 20 + FwdJumpInfo; // ...
ActDecodePos = (Zaehler << 5) + pos; ActDecodePos = (Zaehler << 5) + pos;
// decode data and check for validity of frame // decode data and check for validity of frame
FrameBitCnt = BitsRead (); FrameBitCnt = BitsRead ();
switch ( StreamVersion ) { switch ( StreamVersion ) {
case 0x04: case 0x04:
case 0x05: case 0x05:
case 0x06: case 0x06:
Lese_Bitstrom_SV6 (); Lese_Bitstrom_SV6 ();
break; break;
case 0x07: case 0x07:
case 0x17: case 0x17:
Lese_Bitstrom_SV7 (); Lese_Bitstrom_SV7 ();
break; break;
default: default:
return (unsigned int)(-1); return (unsigned int)(-1);
} }
FrameWasValid = BitsRead() - FrameBitCnt == FwdJumpInfo; FrameWasValid = BitsRead() - FrameBitCnt == FwdJumpInfo;
// synthesize signal // synthesize signal
Requantisierung ( Max_Band ); Requantisierung ( Max_Band );
//if ( EQ_activated && PluginSettings.EQbyMPC ) //if ( EQ_activated && PluginSettings.EQbyMPC )
// perform_EQ (); // perform_EQ ();
Synthese_Filter_float ( buffer ); Synthese_Filter_float ( buffer );
DecodedFrames++; DecodedFrames++;
// cut off first SynthDelay zero-samples // cut off first SynthDelay zero-samples
if ( DecodedFrames == OverallFrames && StreamVersion >= 6 ) if ( DecodedFrames == OverallFrames && StreamVersion >= 6 )
{ // reconstruct exact filelength { // reconstruct exact filelength
int mod_block = Bitstream_read (11); int mod_block = Bitstream_read (11);
int FilterDecay; int FilterDecay;
if (mod_block == 0) mod_block = 1152; // Encoder bugfix if (mod_block == 0) mod_block = 1152; // Encoder bugfix
FilterDecay = (mod_block + SynthDelay) % FrameLength; FilterDecay = (mod_block + SynthDelay) % FrameLength;
// additional FilterDecay samples are needed for decay of synthesis filter // additional FilterDecay samples are needed for decay of synthesis filter
if ( SynthDelay + mod_block >= FrameLength ) { if ( SynthDelay + mod_block >= FrameLength ) {
// ********************************************************************** // **********************************************************************
// Rhoades 4/16/2002 // Rhoades 4/16/2002
// Commented out are blocks of code which cause gapless playback to fail. // Commented out are blocks of code which cause gapless playback to fail.
// Temporary fix... // Temporary fix...
// ********************************************************************** // **********************************************************************
if ( ! TrueGaplessPresent ) { if ( ! TrueGaplessPresent ) {
RESET_Y (); RESET_Y ();
} else { } else {
//if ( FrameLength != LastValidSamples ) { //if ( FrameLength != LastValidSamples ) {
Bitstream_read (20); Bitstream_read (20);
Lese_Bitstrom_SV7 (); Lese_Bitstrom_SV7 ();
Requantisierung ( Max_Band ); Requantisierung ( Max_Band );
//FilterDecay = LastValidSamples; //FilterDecay = LastValidSamples;
//} //}
//else { //else {
//FilterDecay = 0; //FilterDecay = 0;
//} //}
} }
Synthese_Filter_float ( buffer + 2304 ); Synthese_Filter_float ( buffer + 2304 );
output_frame_length = FrameLength + FilterDecay; output_frame_length = FrameLength + FilterDecay;
} }
else { // there are only FilterDecay samples needed for this frame else { // there are only FilterDecay samples needed for this frame
output_frame_length = FilterDecay; output_frame_length = FilterDecay;
} }
} }
if ( samples_to_skip ) { if ( samples_to_skip ) {
if (output_frame_length < samples_to_skip) if (output_frame_length < samples_to_skip)
{ {
samples_to_skip -= output_frame_length; samples_to_skip -= output_frame_length;
output_frame_length = 0; output_frame_length = 0;
} }
else else
{ {
output_frame_length -= samples_to_skip; output_frame_length -= samples_to_skip;
memmove ( buffer, buffer + samples_to_skip * 2, output_frame_length * 2 * sizeof (MPC_SAMPLE_FORMAT) ); memmove ( buffer, buffer + samples_to_skip * 2, output_frame_length * 2 * sizeof (MPC_SAMPLE_FORMAT) );
samples_to_skip = 0; samples_to_skip = 0;
} }
} }
return output_frame_length; return output_frame_length;
} }
@ -158,20 +158,20 @@ unsigned int MPC_decoder::Decode ( MPC_SAMPLE_FORMAT *buffer, unsigned int * vbr
if ( FrameWasValid == 0 ) { // error occurred in bitstream if ( FrameWasValid == 0 ) { // error occurred in bitstream
return (unsigned int)(-1); return (unsigned int)(-1);
} else } else
{ {
if (vbr_update_acc && vbr_update_bits) if (vbr_update_acc && vbr_update_bits)
{ {
(*vbr_update_acc) ++; (*vbr_update_acc) ++;
vbr_ring = (Zaehler << 5) + pos - vbr_ring; vbr_ring = (Zaehler << 5) + pos - vbr_ring;
if (vbr_ring < 0) vbr_ring += 524288; if (vbr_ring < 0) vbr_ring += 524288;
(*vbr_update_bits) += vbr_ring; (*vbr_update_bits) += vbr_ring;
} }
} }
UpdateBuffer ( RING ); UpdateBuffer ( RING );
if (valid_samples > 0) return valid_samples; if (valid_samples > 0) return valid_samples;
} }
} }
void void
@ -191,7 +191,7 @@ MPC_decoder::Requantisierung ( const int Last_Band )
#ifdef MPC_FIXED_POINT #ifdef MPC_FIXED_POINT
#if MPC_FIXED_POINT_FRACTPART == 14 #if MPC_FIXED_POINT_FRACTPART == 14
#define MPC_MULTIPLY_SCF(CcVal, SCF_idx) \ #define MPC_MULTIPLY_SCF(CcVal, SCF_idx) \
MPC_MULTIPLY_EX(CcVal,SCF[SCF_idx],SCF_shift[SCF_idx]) MPC_MULTIPLY_EX(CcVal,SCF[SCF_idx],SCF_shift[SCF_idx])
#else #else
#error FIXME, Cc table is in 18.14 format #error FIXME, Cc table is in 18.14 format
@ -199,7 +199,7 @@ MPC_decoder::Requantisierung ( const int Last_Band )
#endif #endif
#else #else
#define MPC_MULTIPLY_SCF(CcVal, SCF_idx) \ #define MPC_MULTIPLY_SCF(CcVal, SCF_idx) \
MPC_MULTIPLY(CcVal,SCF[SCF_idx]) MPC_MULTIPLY(CcVal,SCF[SCF_idx])
#endif #endif
// requantization and scaling of subband-samples // requantization and scaling of subband-samples
for ( Band = 0; Band <= Last_Band; Band++ ) { // setting pointers for ( Band = 0; Band <= Last_Band; Band++ ) { // setting pointers
@ -232,7 +232,7 @@ MPC_decoder::Requantisierung ( const int Last_Band )
} else { // M!=0, S==0 } else { // M!=0, S==0
facL = MPC_MULTIPLY_SCF( Cc[Res_L[Band]] , (unsigned char)SCF_Index_L[Band][0]); facL = MPC_MULTIPLY_SCF( Cc[Res_L[Band]] , (unsigned char)SCF_Index_L[Band][0]);
for ( n = 0; n < 12; n++, YL += 32, YR += 32 ) { for ( n = 0; n < 12; n++, YL += 32, YR += 32 ) {
*YR = *YL = MPC_MULTIPLY_FLOAT_INT(facL,*L++); *YR = *YL = MPC_MULTIPLY_FLOAT_INT(facL,*L++);
} }
facL = MPC_MULTIPLY_SCF( Cc[Res_L[Band]] , (unsigned char)SCF_Index_L[Band][1]); facL = MPC_MULTIPLY_SCF( Cc[Res_L[Band]] , (unsigned char)SCF_Index_L[Band][1]);
for ( ; n < 24; n++, YL += 32, YR += 32 ) { for ( ; n < 24; n++, YL += 32, YR += 32 ) {
@ -886,8 +886,8 @@ MPC_decoder::MPC_decoder ( MPC_reader *r, double scale_factor )
void MPC_decoder::SetStreamInfo ( const StreamInfo *si ) void MPC_decoder::SetStreamInfo ( const StreamInfo *si )
{ {
RESET_Synthesis (); RESET_Synthesis ();
RESET_Globals (); RESET_Globals ();
StreamVersion = si->simple.StreamVersion; StreamVersion = si->simple.StreamVersion;
MS_used = si->simple.MS; MS_used = si->simple.MS;
@ -899,14 +899,14 @@ void MPC_decoder::SetStreamInfo ( const StreamInfo *si )
SampleRate = (int)si->simple.SampleFreq; SampleRate = (int)si->simple.SampleFreq;
if ( SeekTable != NULL ) free ( SeekTable ); if ( SeekTable != NULL ) free ( SeekTable );
SeekTable = (unsigned short *)calloc ( sizeof(unsigned short), OverallFrames+64 ); SeekTable = (unsigned short *)calloc ( OverallFrames+64, sizeof(unsigned short) );
samples_to_skip = SynthDelay; samples_to_skip = SynthDelay;
} }
bool MPC_decoder::Initialize(const StreamInfo * info) bool MPC_decoder::Initialize(const StreamInfo * info)
{ {
SetStreamInfo(info); SetStreamInfo(info);
// AB: setting position to the beginning of the data-bitstream // AB: setting position to the beginning of the data-bitstream
switch ( StreamVersion ) { switch ( StreamVersion ) {
@ -971,7 +971,7 @@ static unsigned int get_initial_fpos(unsigned int StreamVersion)
case 0x07: case 0x07:
case 0x17: fpos = 200; break; case 0x17: fpos = 200; break;
} }
return fpos; return fpos;
} }
bool MPC_decoder::SeekSeconds ( double seconds ) bool MPC_decoder::SeekSeconds ( double seconds )
@ -985,8 +985,8 @@ bool MPC_decoder::SeekSample(MPC_INT64 destsample)
unsigned long fpos; unsigned long fpos;
unsigned int fwd; unsigned int fwd;
fwd = (unsigned) (destsample / FrameLength); fwd = (unsigned) (destsample / FrameLength);
samples_to_skip = SynthDelay + (unsigned)(destsample % FrameLength); samples_to_skip = SynthDelay + (unsigned)(destsample % FrameLength);
memset ( Y_L , 0, sizeof Y_L ); memset ( Y_L , 0, sizeof Y_L );
memset ( Y_R , 0, sizeof Y_R ); memset ( Y_R , 0, sizeof Y_R );
@ -1058,17 +1058,17 @@ void MPC_decoder::UpdateBuffer ( unsigned int RING )
static unsigned long swap32(unsigned long val) static unsigned long swap32(unsigned long val)
{ {
const unsigned char * src = (const unsigned char*)&val; const unsigned char * src = (const unsigned char*)&val;
return (unsigned long)src[0] | ((unsigned long)src[1] << 8) | ((unsigned long)src[2] << 16) | ((unsigned long)src[3] << 24); return (unsigned long)src[0] | ((unsigned long)src[1] << 8) | ((unsigned long)src[2] << 16) | ((unsigned long)src[3] << 24);
} }
int MPC_decoder::f_read_dword( unsigned int * ptr, unsigned int count) int MPC_decoder::f_read_dword( unsigned int * ptr, unsigned int count)
{ {
count = f_read(ptr,count << 2) >> 2; count = f_read(ptr,count << 2) >> 2;
#ifndef MPC_LITTLE_ENDIAN #ifndef MPC_LITTLE_ENDIAN
unsigned int n; unsigned int n;
for(n=0;n<count;n++) for(n=0;n<count;n++)
ptr[n] = swap32(ptr[n]); ptr[n] = swap32(ptr[n]);
#endif #endif
return count; return count;
} }

@ -31,24 +31,24 @@ typedef MPC_INT64 MPC_SAMPLE_FORMAT_MULTIPLY;
#define MAKE_MPC_SAMPLE_EX(X,Y) (MPC_SAMPLE_FORMAT)((double)(X) * (double)(((MPC_INT64)1)<<(Y))) #define MAKE_MPC_SAMPLE_EX(X,Y) (MPC_SAMPLE_FORMAT)((double)(X) * (double)(((MPC_INT64)1)<<(Y)))
#define MPC_MULTIPLY_NOTRUNCATE(X,Y) \ #define MPC_MULTIPLY_NOTRUNCATE(X,Y) \
(((MPC_SAMPLE_FORMAT_MULTIPLY)(X) * (MPC_SAMPLE_FORMAT_MULTIPLY)(Y)) >> MPC_FIXED_POINT_FRACTPART) (((MPC_SAMPLE_FORMAT_MULTIPLY)(X) * (MPC_SAMPLE_FORMAT_MULTIPLY)(Y)) >> MPC_FIXED_POINT_FRACTPART)
#define MPC_MULTIPLY_EX_NOTRUNCATE(X,Y,Z) \ #define MPC_MULTIPLY_EX_NOTRUNCATE(X,Y,Z) \
(((MPC_SAMPLE_FORMAT_MULTIPLY)(X) * (MPC_SAMPLE_FORMAT_MULTIPLY)(Y)) >> (Z)) (((MPC_SAMPLE_FORMAT_MULTIPLY)(X) * (MPC_SAMPLE_FORMAT_MULTIPLY)(Y)) >> (Z))
#ifdef _DEBUG #ifdef _DEBUG
static inline MPC_SAMPLE_FORMAT MPC_MULTIPLY(MPC_SAMPLE_FORMAT item1,MPC_SAMPLE_FORMAT item2) static inline MPC_SAMPLE_FORMAT MPC_MULTIPLY(MPC_SAMPLE_FORMAT item1,MPC_SAMPLE_FORMAT item2)
{ {
MPC_SAMPLE_FORMAT_MULTIPLY temp = MPC_MULTIPLY_NOTRUNCATE(item1,item2); MPC_SAMPLE_FORMAT_MULTIPLY temp = MPC_MULTIPLY_NOTRUNCATE(item1,item2);
assert(temp == (MPC_SAMPLE_FORMAT_MULTIPLY)(MPC_SAMPLE_FORMAT)temp); assert(temp == (MPC_SAMPLE_FORMAT_MULTIPLY)(MPC_SAMPLE_FORMAT)temp);
return (MPC_SAMPLE_FORMAT)temp; return (MPC_SAMPLE_FORMAT)temp;
} }
static inline MPC_SAMPLE_FORMAT MPC_MULTIPLY_EX(MPC_SAMPLE_FORMAT item1,MPC_SAMPLE_FORMAT item2,unsigned shift) static inline MPC_SAMPLE_FORMAT MPC_MULTIPLY_EX(MPC_SAMPLE_FORMAT item1,MPC_SAMPLE_FORMAT item2,unsigned shift)
{ {
MPC_SAMPLE_FORMAT_MULTIPLY temp = MPC_MULTIPLY_EX_NOTRUNCATE(item1,item2,shift); MPC_SAMPLE_FORMAT_MULTIPLY temp = MPC_MULTIPLY_EX_NOTRUNCATE(item1,item2,shift);
assert(temp == (MPC_SAMPLE_FORMAT_MULTIPLY)(MPC_SAMPLE_FORMAT)temp); assert(temp == (MPC_SAMPLE_FORMAT_MULTIPLY)(MPC_SAMPLE_FORMAT)temp);
return (MPC_SAMPLE_FORMAT)temp; return (MPC_SAMPLE_FORMAT)temp;
} }
#else #else

@ -34,12 +34,12 @@ const int __Dc [1 + 18] = {
static unsigned find_shift(double fval) static unsigned find_shift(double fval)
{ {
MPC_INT64 val = (MPC_INT64)fval; MPC_INT64 val = (MPC_INT64)fval;
if (val<0) val = -val; if (val<0) val = -val;
unsigned ptr = 0; unsigned ptr = 0;
while(val) {val>>=1;ptr++;} while(val) {val>>=1;ptr++;}
return ptr > 31 ? 0 : 31 - ptr; return ptr > 31 ? 0 : 31 - ptr;
} }
/* F U N C T I O N S */ /* F U N C T I O N S */
@ -50,9 +50,9 @@ void
MPC_decoder::ScaleOutput ( double factor ) MPC_decoder::ScaleOutput ( double factor )
{ {
#ifndef MPC_FIXED_POINT #ifndef MPC_FIXED_POINT
factor *= 1.0 / (double)(1<<(MPC_FIXED_POINT_SHIFT-1)); factor *= 1.0 / (double)(1<<(MPC_FIXED_POINT_SHIFT-1));
#else #else
factor *= 1.0 / (double)(1<<(16 - MPC_FIXED_POINT_SHIFT)); factor *= 1.0 / (double)(1<<(16 - MPC_FIXED_POINT_SHIFT));
#endif #endif
int n; int n;
double f1 = factor; double f1 = factor;
@ -60,14 +60,14 @@ MPC_decoder::ScaleOutput ( double factor )
// handles +1.58...-98.41 dB, where's scf[n] / scf[n-1] = 1.20050805774840750476 // handles +1.58...-98.41 dB, where's scf[n] / scf[n-1] = 1.20050805774840750476
SET_SCF(1,factor); SET_SCF(1,factor);
f1 *= 0.83298066476582673961; f1 *= 0.83298066476582673961;
f2 *= 1/0.83298066476582673961; f2 *= 1/0.83298066476582673961;
for ( n = 1; n <= 128; n++ ) { for ( n = 1; n <= 128; n++ ) {
SET_SCF((unsigned char)(1+n),f1); SET_SCF((unsigned char)(1+n),f1);
SET_SCF((unsigned char)(1-n),f2); SET_SCF((unsigned char)(1-n),f2);
f1 *= 0.83298066476582673961; f1 *= 0.83298066476582673961;
f2 *= 1/0.83298066476582673961; f2 *= 1/0.83298066476582673961;
} }

@ -145,8 +145,8 @@ int StreamInfo::ReadHeaderSV6 ( unsigned int HeaderData [8] )
static unsigned int swap32(unsigned int val) static unsigned int swap32(unsigned int val)
{ {
const unsigned char * src = (const unsigned char*)&val; const unsigned char * src = (const unsigned char*)&val;
return (unsigned int)src[0] | ((unsigned int)src[1] << 8) | ((unsigned int)src[2] << 16) | ((unsigned int)src[3] << 24); return (unsigned int)src[0] | ((unsigned int)src[1] << 8) | ((unsigned int)src[2] << 16) | ((unsigned int)src[3] << 24);
} }
// reads file header and tags // reads file header and tags
@ -158,19 +158,19 @@ int StreamInfo::ReadStreamInfo ( MPC_reader* fp)
//memset ( &simple, 0, sizeof (BasicData) ); // Reset Info-Data //memset ( &simple, 0, sizeof (BasicData) ); // Reset Info-Data
if ( (simple.HeaderPosition = JumpID3v2 (fp)) < 0 ) // get header position if ( (simple.HeaderPosition = JumpID3v2 (fp)) < 0 ) // get header position
return ERROR_CODE_FILE; return ERROR_CODE_FILE;
if ( !fp->seek ( simple.HeaderPosition, SEEK_SET ) ) // seek to first byte of mpc data if ( !fp->seek ( simple.HeaderPosition, SEEK_SET ) ) // seek to first byte of mpc data
return ERROR_CODE_FILE; return ERROR_CODE_FILE;
if ( fp->read ( HeaderData, 8*4 ) != 8*4 ) if ( fp->read ( HeaderData, 8*4 ) != 8*4 )
return ERROR_CODE_FILE; return ERROR_CODE_FILE;
if (!fp->seek(simple.HeaderPosition+6*4,SEEK_SET)) return ERROR_CODE_FILE; if (!fp->seek(simple.HeaderPosition+6*4,SEEK_SET)) return ERROR_CODE_FILE;
/*
/* if ( fp->read ( HeaderData, 6*4 ) != 6*4 ) if ( fp->read ( HeaderData, 6*4 ) != 6*4 )
return ERROR_CODE_FILE; return ERROR_CODE_FILE;
HeaderData[6]=HeaderData[7]=0; HeaderData[6]=HeaderData[7]=0;
*/ */
/* /*
if ( fp->seek ( 0L, SEEK_END ) != 0 ) // get filelength if ( fp->seek ( 0L, SEEK_END ) != 0 ) // get filelength
return ERROR_CODE_FILE; return ERROR_CODE_FILE;
@ -180,12 +180,12 @@ int StreamInfo::ReadStreamInfo ( MPC_reader* fp)
simple.TagOffset = simple.TotalFileLength; simple.TagOffset = simple.TotalFileLength;
if ( memcmp ( HeaderData, "MP+", 3 ) == 0 ) if ( memcmp ( HeaderData, "MP+", 3 ) == 0 )
{ {
#ifndef MPC_LITTLE_ENDIAN #ifndef MPC_LITTLE_ENDIAN
{ {
unsigned int ptr; unsigned int ptr;
for(ptr=0;ptr<8;ptr++) HeaderData[ptr] = swap32(HeaderData[ptr]); for(ptr=0;ptr<8;ptr++) HeaderData[ptr] = swap32(HeaderData[ptr]);
} }
#endif #endif
simple.StreamVersion = HeaderData[0] >> 24; simple.StreamVersion = HeaderData[0] >> 24;

@ -202,14 +202,14 @@ static FLAC__StreamDecoderWriteStatus write_callback(
outFrame->sample_rate = frame->header.sample_rate; outFrame->sample_rate = frame->header.sample_rate;
if (channels == 1 || channels == 2) if (channels == 1 || channels == 2)
outFrame->channel_config = aKode::MonoStereo; outFrame->channel_config = aKode::MonoStereo;
else if (channels > 2 && channels < 8) else if (channels > 2 && channels < 8)
outFrame->channel_config = aKode::Surround; outFrame->channel_config = aKode::Surround;
else else
outFrame->channel_config = aKode::MultiChannel; outFrame->channel_config = aKode::MultiChannel;
for(int i = 0; i<channels; i++) { for(int i = 0; i<channels; i++) {
if (outFrame->data[i] == 0) break; if (outFrame->data[i] == 0) break;
if (bits<=8) { if (bits<=8) {
int8_t** data = (int8_t**)outFrame->data; int8_t** data = (int8_t**)outFrame->data;
for(long j=0; j<frameSize; j++) for(long j=0; j<frameSize; j++)
@ -245,15 +245,15 @@ static void metadata_callback(
data->max_block_size = metadata->data.stream_info.max_blocksize; data->max_block_size = metadata->data.stream_info.max_blocksize;
if (data->config.channels <= 2) if (data->config.channels <= 2)
data->config.channel_config = aKode::MonoStereo; data->config.channel_config = aKode::MonoStereo;
else if (data->config.channels <= 7) else if (data->config.channels <= 7)
data->config.channel_config = aKode::Surround; data->config.channel_config = aKode::Surround;
else else
data->config.channel_config = aKode::MultiChannel; data->config.channel_config = aKode::MultiChannel;
data->si = &metadata->data.stream_info; data->si = &metadata->data.stream_info;
data->position = 0; data->position = 0;
} else } else
if (metadata->type == FLAC__METADATA_TYPE_VORBIS_COMMENT) { if (metadata->type == FLAC__METADATA_TYPE_VORBIS_COMMENT) {
@ -263,7 +263,7 @@ static void metadata_callback(
static void error_callback( static void error_callback(
const FLAC__StreamDecoder *, const FLAC__StreamDecoder *,
FLAC__StreamDecoderErrorStatus status, FLAC__StreamDecoderErrorStatus status,
void* /* client_data */) void* /* client_data */)
{ {
std::cerr << "FLAC error: " << FLAC__StreamDecoderErrorStatusString[status] << "\n"; std::cerr << "FLAC error: " << FLAC__StreamDecoderErrorStatusString[status] << "\n";

Loading…
Cancel
Save