summaryrefslogtreecommitdiff
path: root/src/test_libOggFLAC
diff options
context:
space:
mode:
authorJosh Coalson <jcoalson@users.sourceforce.net>2003-09-25 04:08:46 +0000
committerJosh Coalson <jcoalson@users.sourceforce.net>2003-09-25 04:08:46 +0000
commite7e56751d1c82e2caadf275161e84b9fc67cf60b (patch)
tree81b55a87a96619211a780f5f76c788a38711d609 /src/test_libOggFLAC
parent6e2c6d9958163acf0711e5bc39a8ea02d720d314 (diff)
downloadflac-e7e56751d1c82e2caadf275161e84b9fc67cf60b.tar.gz
add metadata callback back to ogg stream encoder
Diffstat (limited to 'src/test_libOggFLAC')
-rw-r--r--src/test_libOggFLAC/file_utils.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/test_libOggFLAC/file_utils.c b/src/test_libOggFLAC/file_utils.c
index 8ed2b580..78f69f1f 100644
--- a/src/test_libOggFLAC/file_utils.c
+++ b/src/test_libOggFLAC/file_utils.c
@@ -58,6 +58,11 @@ static FLAC__StreamEncoderWriteStatus encoder_write_callback_(const OggFLAC__Str
return FLAC__STREAM_ENCODER_WRITE_STATUS_OK;
}
+static void encoder_metadata_callback_(const OggFLAC__StreamEncoder *encoder, const FLAC__StreamMetadata *metadata, void *client_data)
+{
+ (void)encoder, (void)metadata, (void)client_data;
+}
+
FLAC__bool file_utils__generate_oggflacfile(const char *output_filename, unsigned *output_filesize, unsigned length, const FLAC__StreamMetadata *streaminfo, FLAC__StreamMetadata **metadata, unsigned num_metadata)
{
FLAC__int32 samples[1024];
@@ -99,6 +104,7 @@ FLAC__bool file_utils__generate_oggflacfile(const char *output_filename, unsigne
OggFLAC__stream_encoder_set_total_samples_estimate(encoder, streaminfo->data.stream_info.total_samples);
OggFLAC__stream_encoder_set_metadata(encoder, metadata, num_metadata);
OggFLAC__stream_encoder_set_write_callback(encoder, encoder_write_callback_);
+ OggFLAC__stream_encoder_set_metadata_callback(encoder, encoder_metadata_callback_);
OggFLAC__stream_encoder_set_client_data(encoder, &encoder_client_data);
if(OggFLAC__stream_encoder_init(encoder) != OggFLAC__STREAM_ENCODER_OK) {