Commit 71d5c256 authored by Josh Coalson's avatar Josh Coalson
Browse files

rename set_serial_number to set_ogg_serial_number everywhere

parent 4511f201
......@@ -129,7 +129,7 @@ namespace FLAC {
inline operator bool() const { return is_valid(); }
//@}
virtual bool set_serial_number(long value); ///< See FLAC__stream_decoder_set_serial_number()
virtual bool set_ogg_serial_number(long value); ///< See FLAC__stream_decoder_set_ogg_serial_number()
virtual bool set_md5_checking(bool value); ///< See FLAC__stream_decoder_set_md5_checking()
virtual bool set_metadata_respond(::FLAC__MetadataType type); ///< See FLAC__stream_decoder_set_metadata_respond()
virtual bool set_metadata_respond_application(const FLAC__byte id[4]); ///< See FLAC__stream_decoder_set_metadata_respond_application()
......
......@@ -132,7 +132,7 @@ namespace FLAC {
inline operator bool() const { return is_valid(); }
//@}
virtual bool set_serial_number(long value); ///< See FLAC__stream_encoder_set_serial_number()
virtual bool set_ogg_serial_number(long value); ///< See FLAC__stream_encoder_set_ogg_serial_number()
virtual bool set_verify(bool value); ///< See FLAC__stream_encoder_set_verify()
virtual bool set_streamable_subset(bool value); ///< See FLAC__stream_encoder_set_streamable_subset()
virtual bool set_do_mid_side_stereo(bool value); ///< See FLAC__stream_encoder_set_do_mid_side_stereo()
......
......@@ -680,7 +680,7 @@ FLAC_API void FLAC__stream_decoder_delete(FLAC__StreamDecoder *decoder);
* \retval FLAC__bool
* \c false if the decoder is already initialized, else \c true.
*/
FLAC_API FLAC__bool FLAC__stream_decoder_set_serial_number(FLAC__StreamDecoder *decoder, long serial_number);
FLAC_API FLAC__bool FLAC__stream_decoder_set_ogg_serial_number(FLAC__StreamDecoder *decoder, long serial_number);
/** Set the "MD5 signature checking" flag. If \c true, the decoder will
* compute the MD5 signature of the unencoded audio data while decoding
......
......@@ -651,7 +651,7 @@ FLAC_API void FLAC__stream_encoder_delete(FLAC__StreamEncoder *encoder);
* \retval FLAC__bool
* \c false if the encoder is already initialized, else \c true.
*/
FLAC_API FLAC__bool FLAC__stream_encoder_set_serial_number(FLAC__StreamEncoder *encoder, long serial_number);
FLAC_API FLAC__bool FLAC__stream_encoder_set_ogg_serial_number(FLAC__StreamEncoder *encoder, long serial_number);
/** Set the "verify" flag. If \c true, the encoder will verify it's own
* encoded output by feeding it through an internal decoder and comparing
......
......@@ -335,7 +335,7 @@ FLAC__bool DecoderSession_init_decoder(DecoderSession *decoder_session, decode_o
#ifdef FLAC__HAS_OGG
if(decoder_session->is_ogg) {
if(!decode_options.use_first_serial_number)
FLAC__stream_decoder_set_serial_number(decoder_session->decoder, decode_options.serial_number);
FLAC__stream_decoder_set_ogg_serial_number(decoder_session->decoder, decode_options.serial_number);
init_status = FLAC__stream_decoder_init_ogg_file(decoder_session->decoder, strcmp(infilename, "-")? infilename : 0, write_callback, metadata_callback, error_callback, /*client_data=*/decoder_session);
}
else
......
......@@ -1920,7 +1920,7 @@ FLAC__bool EncoderSession_init_encoder(EncoderSession *e, encode_options_t optio
#ifdef FLAC__HAS_OGG
if(e->use_ogg) {
FLAC__stream_encoder_set_serial_number(e->encoder, options.serial_number);
FLAC__stream_encoder_set_ogg_serial_number(e->encoder, options.serial_number);
init_status = FLAC__stream_encoder_init_ogg_file(e->encoder, e->is_stdout? 0 : e->outfilename, encoder_progress_callback, /*client_data=*/e);
}
......
......@@ -73,10 +73,10 @@ namespace FLAC {
return 0 != decoder_;
}
bool Stream::set_serial_number(long value)
bool Stream::set_ogg_serial_number(long value)
{
FLAC__ASSERT(is_valid());
return (bool)::FLAC__stream_decoder_set_serial_number(decoder_, value);
return (bool)::FLAC__stream_decoder_set_ogg_serial_number(decoder_, value);
}
bool Stream::set_md5_checking(bool value)
......
......@@ -74,10 +74,10 @@ namespace FLAC {
return 0 != encoder_;
}
bool Stream::set_serial_number(long value)
bool Stream::set_ogg_serial_number(long value)
{
FLAC__ASSERT(is_valid());
return (bool)::FLAC__stream_encoder_set_serial_number(encoder_, value);
return (bool)::FLAC__stream_encoder_set_ogg_serial_number(encoder_, value);
}
bool Stream::set_verify(bool value)
......
......@@ -721,7 +721,7 @@ FLAC_API FLAC__bool FLAC__stream_decoder_finish(FLAC__StreamDecoder *decoder)
return !md5_failed;
}
FLAC_API FLAC__bool FLAC__stream_decoder_set_serial_number(FLAC__StreamDecoder *decoder, long value)
FLAC_API FLAC__bool FLAC__stream_decoder_set_ogg_serial_number(FLAC__StreamDecoder *decoder, long value)
{
FLAC__ASSERT(0 != decoder);
FLAC__ASSERT(0 != decoder->private_);
......
......@@ -1370,7 +1370,7 @@ FLAC_API void FLAC__stream_encoder_finish(FLAC__StreamEncoder *encoder)
encoder->protected_->state = FLAC__STREAM_ENCODER_UNINITIALIZED;
}
FLAC_API FLAC__bool FLAC__stream_encoder_set_serial_number(FLAC__StreamEncoder *encoder, long value)
FLAC_API FLAC__bool FLAC__stream_encoder_set_ogg_serial_number(FLAC__StreamEncoder *encoder, long value)
{
FLAC__ASSERT(0 != encoder);
FLAC__ASSERT(0 != encoder->private_);
......
......@@ -528,8 +528,8 @@ static bool test_stream_decoder(Layer layer, bool is_ogg)
printf("OK\n");
if(is_ogg) {
printf("testing set_serial_number()... ");
if(!decoder->set_serial_number(file_utils__ogg_serial_number))
printf("testing set_ogg_serial_number()... ");
if(!decoder->set_ogg_serial_number(file_utils__ogg_serial_number))
return die_s_("returned false", decoder);
printf("OK\n");
}
......
......@@ -185,8 +185,8 @@ static bool test_stream_encoder(Layer layer, bool is_ogg)
printf("OK\n");
if(is_ogg) {
printf("testing set_serial_number()... ");
if(!encoder->set_serial_number(file_utils__ogg_serial_number))
printf("testing set_ogg_serial_number()... ");
if(!encoder->set_ogg_serial_number(file_utils__ogg_serial_number))
return die_s_("returned false", encoder);
printf("OK\n");
}
......
......@@ -457,8 +457,8 @@ static FLAC__bool test_stream_decoder(Layer layer, FLAC__bool is_ogg)
printf("OK\n");
if(is_ogg) {
printf("testing FLAC__stream_decoder_set_serial_number()... ");
if(!FLAC__stream_decoder_set_serial_number(decoder, file_utils__ogg_serial_number))
printf("testing FLAC__stream_decoder_set_ogg_serial_number()... ");
if(!FLAC__stream_decoder_set_ogg_serial_number(decoder, file_utils__ogg_serial_number))
return die_s_("returned false", decoder);
printf("OK\n");
}
......
......@@ -148,8 +148,8 @@ static FLAC__bool test_stream_encoder(Layer layer, FLAC__bool is_ogg)
printf("OK\n");
if(is_ogg) {
printf("testing FLAC__stream_encoder_set_serial_number()... ");
if(!FLAC__stream_encoder_set_serial_number(encoder, file_utils__ogg_serial_number))
printf("testing FLAC__stream_encoder_set_ogg_serial_number()... ");
if(!FLAC__stream_encoder_set_ogg_serial_number(encoder, file_utils__ogg_serial_number))
return die_s_("returned false", encoder);
printf("OK\n");
}
......
......@@ -89,7 +89,7 @@ FLAC__bool file_utils__generate_flacfile(FLAC__bool is_ogg, const char *output_f
return false;
}
FLAC__stream_encoder_set_serial_number(encoder, file_utils__ogg_serial_number);
FLAC__stream_encoder_set_ogg_serial_number(encoder, file_utils__ogg_serial_number);
FLAC__stream_encoder_set_verify(encoder, true);
FLAC__stream_encoder_set_streamable_subset(encoder, true);
FLAC__stream_encoder_set_do_mid_side_stereo(encoder, false);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment