Commit 6b21f667 authored by Josh Coalson's avatar Josh Coalson

merge down from merged-API-layer branch: cvs -q up -dP -j...

merge down from merged-API-layer branch: cvs -q up -dP -j API_LAYER_MERGING_BASELINE -j API_LAYER_MERGING_BRANCH
parent 461f3eb2
......@@ -81,6 +81,9 @@ Package=<4>
Project_Dep_Name libOggFLAC++_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name plugin_common_static
End Project Dependency
Begin Project Dependency
......@@ -159,6 +162,9 @@ Package=<4>
Project_Dep_Name libOggFLAC++_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name plugin_common_static
End Project Dependency
Begin Project Dependency
......@@ -498,6 +504,24 @@ Package=<4>
###############################################################################
Project: "test_libs_common"=.\src\test_libs_common\test_libs_common_static.dsp - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
Begin Project Dependency
Project_Dep_Name libFLAC_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name libOggFLAC_static
End Project Dependency
}}}
###############################################################################
Project: "test_libFLAC"=.\src\test_libFLAC\test_libFLAC.dsp - Package Owner=<4>
Package=<5>
......@@ -509,6 +533,9 @@ Package=<4>
Begin Project Dependency
Project_Dep_Name libFLAC_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
}}}
###############################################################################
......@@ -524,6 +551,9 @@ Package=<4>
Begin Project Dependency
Project_Dep_Name libFLAC++_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
}}}
###############################################################################
......@@ -539,6 +569,9 @@ Package=<4>
Begin Project Dependency
Project_Dep_Name libOggFLAC_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
}}}
###############################################################################
......@@ -554,6 +587,9 @@ Package=<4>
Begin Project Dependency
Project_Dep_Name libOggFLAC++_static
End Project Dependency
Begin Project Dependency
Project_Dep_Name test_libs_common_static
End Project Dependency
}}}
###############################################################################
......
......@@ -241,17 +241,18 @@ configure.in and src/libFLAC/Makefile.am; the following dependency
graph shows which modules may be pruned without breaking things
further down:
file_encoder.h
stream_encoder.h
format.h
stream_encoder.h
stream_decoder.h
format.h
file_decoder.h
seekable_stream_decoder.h
stream_decoder.h
format.h
stream_decoder.h
format.h
metadata.h
format.h
In other words, for pure decoding applications, both the stream encoder
and metadata editing interfaces can be safely removed.
There is a section dedicated to embedded use in the libFLAC API
HTML documentation (see doc/html/api/index.html).
......@@ -314,6 +314,7 @@ AC_CONFIG_FILES([ \
src/share/utf8/Makefile \
src/test_grabbag/Makefile \
src/test_grabbag/cuesheet/Makefile \
src/test_libs_common/Makefile \
src/test_libFLAC/Makefile \
src/test_libFLAC++/Makefile \
src/test_libOggFLAC/Makefile \
......@@ -327,6 +328,7 @@ AC_CONFIG_FILES([ \
include/OggFLAC++/Makefile \
include/share/Makefile \
include/share/grabbag/Makefile \
include/test_libs_common/Makefile \
doc/Makefile \
doc/html/Makefile \
doc/html/images/Makefile \
......@@ -334,6 +336,8 @@ AC_CONFIG_FILES([ \
man/Makefile \
test/Makefile \
test/cuesheets/Makefile \
test/flac-to-flac-metadata-test-files/Makefile \
test/metaflac-test-files/Makefile \
build/Makefile \
obj/Makefile \
obj/debug/Makefile \
......
......@@ -53,7 +53,7 @@
</div>
<div class="box_header"></div>
<div class="box_body">
This is an informal changelog, a summary of changes in each release. Particulary important for developers is the precise description of changes to the library interfaces.
This is an informal changelog, a summary of changes in each release. Particulary important for developers is the precise description of changes to the library interfaces. See also the <a href="http://flac.sourceforge.net/api/group__porting.html">porting guide</a> for specific instructions on porting to newer versions of FLAC.
<br /><br />
......@@ -68,6 +68,7 @@
<li>Large file (&gt;2GB) support everywhere</li>
<li>Much better recovery for corrupted files</li>
<li><span class="commandname">flac</span> now supports FLAC as input to the encoder (i.e. can re-encode FLAC to FLAC) and preserve all the metadata like tags, etc.</li>
<li>In the developer libraries, the interface has been simplfied by merging the three decoding layers into a single class; ditto for the encoders.</li>
</ul>
</li>
<li>
......@@ -134,12 +135,19 @@
</ul>
</li>
<li>
Interface changes:
Interface changes (see also the <a href="http://flac.sourceforge.net/api/group__porting__1__1__2__to__1__1__3.html">porting guide</a> for specific instructions on porting to FLAC 1.1.3):
<ul>
<li>
all libraries;
<ul>
<li>Merged seekable stream decoder and file decoder into the stream decoder.</li>
<li>Merged seekable stream encoder and file encoder into the stream encoder.</li>
</ul>
</li>
<li>
libFLAC:
<ul>
<li><b>Added</b> FLAC__*_encoder_set_apodization()</li>
<li><b>Added</b> FLAC__stream_encoder_set_apodization()</li>
<li><b>Added</b> FLAC__metadata_object_cuesheet_calculate_cddb_id()</li>
<li><b>Added</b> FLAC__metadata_get_cuesheet()</li>
<li><b>Changed</b> FLAC__StreamDecoderState: removed state FLAC__STREAM_DECODER_UNPARSEABLE_STREAM</li>
......@@ -150,7 +158,7 @@
<li>
libFLAC++:
<ul>
<li><b>Added</b> FLAC::*::Encoder::set_apodization()</li>
<li><b>Added</b> FLAC::Encoder::Stream::set_apodization()</li>
<li><b>Added</b> FLAC::Metadata::CueSheet::calculate_cddb_id()</li>
<li><b>Added</b> FLAC::Metadata::get_cuesheet()</li>
</ul>
......@@ -158,7 +166,7 @@
<li>
libOggFLAC:
<ul>
<li><b>Added</b> OggFLAC__*_encoder_set_apodization()</li>
<li><b>Added</b> OggFLAC__stream_encoder_set_apodization()</li>
<li><b>Added</b> OggFLAC__metadata_object_cuesheet_calculate_cddb_id()</li>
<li><b>Added</b> OggFLAC__metadata_get_cuesheet()</li>
</ul>
......@@ -166,7 +174,7 @@
<li>
libOggFLAC++:
<ul>
<li><b>Added</b> OggFLAC::*::Encoder::set_apodization()</li>
<li><b>Added</b> OggFLAC::Encoder::Stream::set_apodization()</li>
<li><b>Added</b> OggFLAC::Metadata::CueSheet::calculate_cddb_id()</li>
<li><b>Added</b> OggFLAC::Metadata::get_cuesheet()</li>
</ul>
......
This diff is collapsed.
This diff is collapsed.
......@@ -35,12 +35,8 @@ flaccinclude_HEADERS = \
assert.h \
callback.h \
export.h \
file_decoder.h \
file_encoder.h \
format.h \
metadata.h \
ordinals.h \
seekable_stream_decoder.h \
seekable_stream_encoder.h \
stream_decoder.h \
stream_encoder.h
......@@ -36,13 +36,9 @@
#include "assert.h"
#include "callback.h"
#include "file_decoder.h"
#include "file_encoder.h"
#include "format.h"
#include "metadata.h"
#include "ordinals.h"
#include "seekable_stream_decoder.h"
#include "seekable_stream_encoder.h"
#include "stream_decoder.h"
#include "stream_encoder.h"
......@@ -121,6 +117,12 @@
* individual functions. You can see different views of the individual
* functions through the links in top bar across this page.
*
* \section porting_guide Porting Guide
*
* Starting with FLAC 1.1.3 a \link porting Porting Guide \endlink
* has been introduced which gives detailed instructions on how to
* port your code to newer versions of FLAC.
*
* \section embedded_developers Embedded Developers
*
* libFLAC has grown larger over time as more functionality has been
......@@ -144,6 +146,140 @@
* will greatly reduce the size of the library.
*/
/** \defgroup porting Porting Guide for New Versions
*
* This module describes differences in the library interfaces from
* version to version. It assists in the porting of code that uses
* the libraries to newer versions of FLAC.
*/
/** \defgroup porting_1_1_2_to_1_1_3 Porting from FLAC 1.1.2 to 1.1.3
* \ingroup porting
*
* \brief
* This module describes porting from FLAC 1.1.2 to FLAC 1.1.3.
*
* The main change between the APIs in 1.1.2 and 1.1.3 is that the three
* decoding layers and three encoding layers have been merged into a
* single stream decoder and stream encoder. That is, the functionality
* of FLAC__SeekableStreamDecoder and FLAC__FileDecoder has been merged
* into FLAC__StreamDecoder, and FLAC__SeekableStreamEncoder and
* FLAC__FileEncoder into FLAC__StreamEncoder. Only the
* FLAC__StreamDecoder and FLAC__StreamEncoder remain. This can
* simplify code that needs to process both seekable and non-seekable
* streams.
*
* Instead of creating an encoder or decoder of a certain layer, now the
* client will always create a FLAC__StreamEncoder or
* FLAC__StreamDecoder. The different layers are differentiated by the
* initialization function. For example, for the decoder,
* FLAC__stream_decoder_init() has been replaced by
* FLAC__stream_decoder_init_stream(). This init function takes
* callbacks for the I/O, and the seeking callbacks are optional. This
* allows the client to use the same object for seekable and
* non-seekable streams. For decoding a FLAC file directly, the client
* can use FLAC__stream_decoder_init_file() and pass just a filename
* and fewer callbacks; most of the other callbacks are supplied
* internally. For situations where fopen()ing by filename is not
* possible (e.g. Unicode filenames on Windows) the client can instead
* open the file itself and supply the FILE* to
* FLAC__stream_decoder_init_FILE(). The init functions now returns a
* FLAC__StreamDecoderInitStatus instead of FLAC__StreamDecoderState.
* Since the callbacks and client data are now passed to the init
* function, the FLAC__stream_decoder_set_*_callback() functions and
* FLAC__stream_decoder_set_client_data() are no longer needed. The
* rest of the calls to the decoder are the same as before.
*
* As an example, in FLAC 1.1.2 a seekable stream decoder would be set
* up like so:
*@@@@@@CHECK@@@@@@
* \code
* FLAC__SeekableStreamDecoder *decoder = FLAC__seekable_stream_decoder_new();
* if(decoder == NULL) do something;
* FLAC__seekable_stream_decoder_set_md5_checking(decoder, true);
* [... other settings ...]
* FLAC__seekable_stream_decoder_set_read_callback(decoder, my_read_callback);
* FLAC__seekable_stream_decoder_set_seek_callback(decoder, my_seek_callback);
* FLAC__seekable_stream_decoder_set_tell_callback(decoder, my_tell_callback);
* FLAC__seekable_stream_decoder_set_length_callback(decoder, my_length_callback);
* FLAC__seekable_stream_decoder_set_eof_callback(decoder, my_eof_callback);
* FLAC__seekable_stream_decoder_set_write_callback(decoder, my_write_callback);
* FLAC__seekable_stream_decoder_set_metadata_callback(decoder, my_metadata_callback);
* FLAC__seekable_stream_decoder_set_error_callback(decoder, my_error_callback);
* FLAC__seekable_stream_decoder_set_client_data(decoder, my_client_data);
* if(FLAC__seekable_stream_decoder_init(decoder) != FLAC__SEEKABLE_STREAM_DECODER_OK) do something;
* \endcode
*
* In FLAC 1.1.3 it is like this:
*
* \code
* FLAC__StreamDecoder *decoder = FLAC__stream_decoder_new();
* if(decoder == NULL) do something;
* FLAC__stream_decoder_set_md5_checking(decoder, true);
* [... other settings ...]
* if(FLAC__stream_decoder_init_stream(
* decoder,
* my_read_callback,
* my_seek_callback, // or NULL
* my_tell_callback, // or NULL
* my_length_callback, // or NULL
* my_eof_callback, // or NULL
* my_write_callback,
* my_metadata_callback, // or NULL
* my_error_callback,
* my_client_data,
* ) != FLAC__STREAM_DECODER_INIT_STATUS_OK) do something;
* \endcode
*
* or you could do;
*
* \code
* [...]
* FILE *file = fopen("somefile.flac","rb");
* if(file == NULL) do somthing;
* if(FLAC__stream_decoder_init_FILE(
* decoder,
* file,
* my_write_callback,
* my_metadata_callback, // or NULL
* my_error_callback,
* my_client_data,
* ) != FLAC__STREAM_DECODER_INIT_STATUS_OK) do something;
* \endcode
*
* or just:
*
* \code
* [...]
* if(FLAC__stream_decoder_init_FILE(
* decoder,
* "somefile.flac",
* my_write_callback,
* my_metadata_callback, // or NULL
* my_error_callback,
* my_client_data,
* ) != FLAC__STREAM_DECODER_INIT_STATUS_OK) do something;
* \endcode
*
* Another small change to the decoder is in how it handles unparseable
* streams. Before, when the decoder found an unparseable stream
* (reserved for when the decoder encounters a stream from a future
* encoder that it can't parse), it changed the state to
* \c FLAC__STREAM_DECODER_UNPARSEABLE_STREAM. Now the decoder instead
* drops sync and calls the error callback with a new error code
* \c FLAC__STREAM_DECODER_ERROR_STATUS_UNPARSEABLE_STREAM. This is
* more robust. If your error callback does not discriminate on the the
* error state, your code does not need to be changed.
*
* The encoder now has a new setting:
* FLAC__stream_encoder_set_apodization(). This is for setting the
* method used to window the data before LPC analysis. You only need to
* add a call to this function if the default is not There are also
* two new convenience functions that may be useful:
* FLAC__metadata_object_cuesheet_calculate_cddb_id() and
* FLAC__metadata_get_cuesheet().
*/
/** \defgroup flac FLAC C API
*
* The FLAC C API is the interface to libFLAC, a set of structures
......
This diff is collapsed.
This diff is collapsed.
......@@ -1338,11 +1338,40 @@ FLAC_API FLAC__bool FLAC__metadata_object_seektable_template_append_points(FLAC_
* \assert
* \code object != NULL \endcode
* \code object->type == FLAC__METADATA_TYPE_SEEKTABLE \endcode
* \code total_samples > 0 \endcode
* \retval FLAC__bool
* \c false if memory allocation fails, else \c true.
*/
FLAC_API FLAC__bool FLAC__metadata_object_seektable_template_append_spaced_points(FLAC__StreamMetadata *object, unsigned num, FLAC__uint64 total_samples);
/** Append a set of evenly-spaced seek point templates to the end of a
* seek table.
*
* \note
* As with the other ..._seektable_template_... functions, you should
* call FLAC__metadata_object_seektable_template_sort() when finished
* to make the seek table legal.
*
* \param object A pointer to an existing SEEKTABLE object.
* \param samples The number of samples apart to space the placeholder
* points. The first point will be at sample \c 0, the
* second at sample \a samples, then 2*\a samples, and
* so on. As long as \a samples and \a total_samples
* are greater than \c 0, there will always be at least
* one seekpoint at sample \0.
* \param total_samples The total number of samples to be encoded;
* the seekpoints will be spaced
* \a samples samples apart.
* \assert
* \code object != NULL \endcode
* \code object->type == FLAC__METADATA_TYPE_SEEKTABLE \endcode
* \code samples > 0 \endcode
* \code total_samples > 0 \endcode
* \retval FLAC__bool
* \c false if memory allocation fails, else \c true.
*/
FLAC_API FLAC__bool FLAC__metadata_object_seektable_template_append_spaced_points_by_samples(FLAC__StreamMetadata *object, unsigned samples, FLAC__uint64 total_samples);
/** Sort a seek table's seek points according to the format specification,
* removing duplicates.
*
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -19,4 +19,4 @@ if FLaC__HAS_OGG
OGGFLAC_DIRS = OggFLAC OggFLAC++
endif
SUBDIRS = FLAC FLAC++ $(OGGFLAC_DIRS) share
SUBDIRS = FLAC FLAC++ $(OGGFLAC_DIRS) share test_libs_common
This diff is collapsed.
This diff is collapsed.
......@@ -36,9 +36,5 @@ oggflaccincludedir = $(includedir)/OggFLAC
oggflaccinclude_HEADERS = \
all.h \
export.h \
file_decoder.h \
file_encoder.h \
seekable_stream_decoder.h \
seekable_stream_encoder.h \
stream_decoder.h \
stream_encoder.h
......@@ -38,10 +38,6 @@
#include "export.h"
#include "file_decoder.h"
#include "file_encoder.h"
#include "seekable_stream_decoder.h"
#include "seekable_stream_encoder.h"
#include "stream_decoder.h"
#include "stream_encoder.h"
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
## Process this file with automake to produce Makefile.in
AUTOMAKE_OPTIONS = foreign
if FLaC__HAS_OGG
OGGFLAC_DIST = \
file_utils_oggflac.h
endif
EXTRA_DIST = \
file_utils_flac.h \
metadata_utils.h \
$(OGGFLAC_DIST)
......@@ -35,6 +35,7 @@ SUBDIRS = \
$(XMMS_DIRS) \
plugin_winamp2 \
test_grabbag \
test_libs_common \
test_libFLAC \
test_libFLAC++ \
$(OGGFLAC_TEST_DIRS) \
......
......@@ -15,8 +15,8 @@
# restrictive of those mentioned above. See the file COPYING.Xiph in this
# distribution.
.PHONY: all flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams
all: flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams
.PHONY: all flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams
all: flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams
DEFAULT_CONFIG = release
......@@ -30,7 +30,7 @@ debug : all
valgrind: all
release : all
flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams:
flac libFLAC libFLAC++ libOggFLAC libOggFLAC++ metaflac plugin_common plugin_xmms share test_grabbag test_libs_common test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_seeking test_streams:
(cd $@ ; $(MAKE) -f Makefile.lite $(CONFIG))
clean:
......@@ -44,6 +44,7 @@ clean:
-(cd plugin_xmms ; $(MAKE) -f Makefile.lite clean)
-(cd share ; $(MAKE) -f Makefile.lite clean)
-(cd test_grabbag ; $(MAKE) -f Makefile.lite clean)
-(cd test_libs_common ; $(MAKE) -f Makefile.lite clean)
-(cd test_libFLAC ; $(MAKE) -f Makefile.lite clean)
-(cd test_libFLAC++ ; $(MAKE) -f Makefile.lite clean)
-(cd test_libOggFLAC ; $(MAKE) -f Makefile.lite clean)
......@@ -60,9 +61,9 @@ plugin_common: libFLAC
plugin_xmms: libFLAC plugin_common
share: libFLAC
test_grabbag: share
test_libFLAC++: libFLAC libFLAC++
test_libFLAC: libFLAC
test_libOggFLAC++: libFLAC libOggFLAC libOggFLAC++
test_libOggFLAC: libFLAC libOggFLAC
test_libFLAC++: libFLAC libFLAC++ test_libs_common
test_libFLAC: libFLAC test_libs_common
test_libOggFLAC++: libFLAC libOggFLAC libOggFLAC++ test_libs_common
test_libOggFLAC: libFLAC libOggFLAC test_libs_common
test_seeking: libFLAC libOggFLAC
test_streams: libFLAC
This diff is collapsed.
This diff is collapsed.
......@@ -1026,15 +1026,21 @@ int parse_option(int short_option, const char *long_option, const char *option_a
break;
case 'S':
FLAC__ASSERT(0 != option_argument);
if(option_values.num_requested_seek_points < 0)
if(0 == strcmp(option_argument, "-")) {
option_values.num_requested_seek_points = 0;
option_values.num_requested_seek_points++;
if(strlen(option_values.requested_seek_points)+strlen(option_argument)+2 >= sizeof(option_values.requested_seek_points)) {
return usage_error("ERROR: too many seekpoints requested\n");
option_values.requested_seek_points[0] = '\0';
}
else {
strcat(option_values.requested_seek_points, option_argument);
strcat(option_values.requested_seek_points, ";");
if(option_values.num_requested_seek_points < 0)
option_values.num_requested_seek_points = 0;
option_values.num_requested_seek_points++;
if(strlen(option_values.requested_seek_points)+strlen(option_argument)+2 >= sizeof(option_values.requested_seek_points)) {
return usage_error("ERROR: too many seekpoints requested\n");
}
else {
strcat(option_values.requested_seek_points, option_argument);
strcat(option_values.requested_seek_points, ";");
}
}
break;
case 'P':
......
......@@ -47,7 +47,5 @@ libFLAC___la_SOURCES = \
file_decoder.cpp \
file_encoder.cpp \
metadata.cpp \
seekable_stream_decoder.cpp \
seekable_stream_encoder.cpp \
stream_decoder.cpp \
stream_encoder.cpp
......@@ -41,8 +41,6 @@ SRCS_CPP = \
file_decoder.cpp \
file_encoder.cpp \
metadata.cpp \
seekable_stream_decoder.cpp \
seekable_stream_encoder.cpp \
stream_decoder.cpp \
stream_encoder.cpp
......
This diff is collapsed.
This diff is collapsed.
......@@ -104,14 +104,6 @@ SOURCE=.\metadata.cpp
# End Source File
# Begin Source File
SOURCE=.\seekable_stream_decoder.cpp
# End Source File
# Begin Source File
SOURCE=.\seekable_stream_encoder.cpp
# End Source File
# Begin Source File
SOURCE=.\stream_decoder.cpp
# End Source File
# Begin Source File
......
......@@ -97,14 +97,6 @@ SOURCE=.\metadata.cpp
# End Source File
# Begin Source File
SOURCE=.\seekable_stream_decoder.cpp
# End Source File
# Begin Source File
SOURCE=.\seekable_stream_encoder.cpp
# End Source File
# Begin Source File
SOURCE=.\stream_decoder.cpp
# End Source File
# Begin Source File
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -184,8 +184,8 @@ namespace FLAC {
::FLAC__StreamMetadata *m[num_blocks];
#endif
for(unsigned i = 0; i < num_blocks; i++) {
// we can get away with this since we know the encoder will only correct the is_last flags
m[i] = const_cast< ::FLAC__StreamMetadata*>((::FLAC__StreamMetadata*)metadata[i]);
// we can get away with the const_cast since we know the encoder will only correct the is_last flags
m[i] = const_cast< ::FLAC__StreamMetadata*>((const ::FLAC__StreamMetadata*)metadata[i]);
}
#if (defined _MSC_VER) || (defined __SUNPRO_CC)
// complete the hack
......@@ -317,13 +317,10 @@ namespace FLAC {
return ::FLAC__stream_encoder_get_total_samples_estimate(encoder_);
}
Stream::State Stream::init()
::FLAC__StreamEncoderInitStatus Stream::init()
{
FLAC__ASSERT(is_valid());
::FLAC__stream_encoder_set_write_callback(encoder_, write_callback_);
::FLAC__stream_encoder_set_metadata_callback(encoder_, metadata_callback_);