mirror of
https://github.com/claunia/flac.git
synced 2025-12-16 18:54:26 +00:00
add a "tell" callback to the seekable stream encoder to make the metadata writeback more robust
This commit is contained in:
@@ -375,6 +375,7 @@ public:
|
||||
|
||||
// from FLAC::Encoder::SeekableStream
|
||||
::FLAC__SeekableStreamEncoderSeekStatus seek_callback(FLAC__uint64 absolute_byte_offset);
|
||||
::FLAC__SeekableStreamEncoderTellStatus tell_callback(FLAC__uint64 *absolute_byte_offset);
|
||||
::FLAC__StreamEncoderWriteStatus write_callback(const FLAC__byte buffer[], unsigned bytes, unsigned samples, unsigned current_frame);
|
||||
|
||||
bool die(const char *msg = 0) const;
|
||||
@@ -387,6 +388,13 @@ public:
|
||||
return ::FLAC__SEEKABLE_STREAM_ENCODER_SEEK_STATUS_OK;
|
||||
}
|
||||
|
||||
::FLAC__SeekableStreamEncoderTellStatus SeekableStreamEncoder::tell_callback(FLAC__uint64 *absolute_byte_offset)
|
||||
{
|
||||
(void)absolute_byte_offset;
|
||||
|
||||
return ::FLAC__SEEKABLE_STREAM_ENCODER_TELL_STATUS_OK;
|
||||
}
|
||||
|
||||
::FLAC__StreamEncoderWriteStatus SeekableStreamEncoder::write_callback(const FLAC__byte buffer[], unsigned bytes, unsigned samples, unsigned current_frame)
|
||||
{
|
||||
(void)buffer, (void)bytes, (void)samples, (void)current_frame;
|
||||
|
||||
Reference in New Issue
Block a user