/contrib/media/updf/include/FLAC/Makefile |
---|
0,0 → 1,262 |
# Generated automatically from Makefile.in by configure. |
# Makefile.in generated automatically by automake 1.4 from Makefile.am |
# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc. |
# This Makefile.in is free software; the Free Software Foundation |
# gives unlimited permission to copy and/or distribute it, |
# with or without modifications, as long as this notice is preserved. |
# This program is distributed in the hope that it will be useful, |
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without |
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A |
# PARTICULAR PURPOSE. |
# flac - Command-line FLAC encoder/decoder |
# Copyright (C) 2000,2001 Josh Coalson |
# |
# This program is free software; you can redistribute it and/or |
# modify it under the terms of the GNU General Public License |
# as published by the Free Software Foundation; either version 2 |
# of the License, or (at your option) any later version. |
# |
# This program is distributed in the hope that it will be useful, |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
# GNU General Public License for more details. |
# |
# You should have received a copy of the GNU General Public License |
# along with this program; if not, write to the Free Software |
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
SHELL = /bin/sh |
srcdir = . |
top_srcdir = ../.. |
prefix = /usr/local |
exec_prefix = ${prefix} |
bindir = ${exec_prefix}/bin |
sbindir = ${exec_prefix}/sbin |
libexecdir = ${exec_prefix}/libexec |
datadir = ${prefix}/share |
sysconfdir = ${prefix}/etc |
sharedstatedir = ${prefix}/com |
localstatedir = ${prefix}/var |
libdir = ${exec_prefix}/lib |
infodir = ${prefix}/info |
mandir = ${prefix}/man |
oldincludedir = /usr/include |
DESTDIR = |
pkgdatadir = $(datadir)/flac |
pkglibdir = $(libdir)/flac |
pkgincludedir = $(includedir)/flac |
top_builddir = ../.. |
ACLOCAL = aclocal |
AUTOCONF = autoconf |
AUTOMAKE = automake |
AUTOHEADER = autoheader |
INSTALL = /usr/bin/install -c |
INSTALL_PROGRAM = ${INSTALL} $(AM_INSTALL_PROGRAM_FLAGS) |
INSTALL_DATA = ${INSTALL} -m 644 |
INSTALL_SCRIPT = ${INSTALL_PROGRAM} |
transform = s,x,x, |
NORMAL_INSTALL = : |
PRE_INSTALL = : |
POST_INSTALL = : |
NORMAL_UNINSTALL = : |
PRE_UNINSTALL = : |
POST_UNINSTALL = : |
host_alias = i686-pc-linux-gnu |
host_triplet = i686-pc-linux-gnu |
AS = @AS@ |
AWK = |
CC = gcc |
DLLTOOL = @DLLTOOL@ |
FLaC__SIZE16 = short |
FLaC__SIZE32 = int |
FLaC__SIZE64 = long long |
FLaC__USIZE16 = unsigned short |
FLaC__USIZE32 = unsigned int |
FLaC__USIZE64 = unsigned long long |
LIBTOOL = $(SHELL) $(top_builddir)/libtool |
LN_S = ln -s |
MAKEINFO = makeinfo |
NASM = nasm |
OBJDUMP = @OBJDUMP@ |
OBJ_FORMAT = elf |
PACKAGE = flac |
RANLIB = ranlib |
VERSION = 1.0 |
XMMS_CFLAGS = |
XMMS_CONFIG = no |
XMMS_DATA_DIR = |
XMMS_EFFECT_PLUGIN_DIR = |
XMMS_GENERAL_PLUGIN_DIR = |
XMMS_INPUT_PLUGIN_DIR = |
XMMS_LIBS = |
XMMS_OUTPUT_PLUGIN_DIR = |
XMMS_PLUGIN_DIR = |
XMMS_VERSION = |
XMMS_VISUALIZATION_PLUGIN_DIR = |
includedir = ${prefix}/include/FLAC |
include_HEADERS = all.h assert.h file_decoder.h format.h ordinals.h seek_table.h stream_decoder.h stream_encoder.h utility.h |
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs |
CONFIG_CLEAN_FILES = ordinals.h |
HEADERS = $(include_HEADERS) |
DIST_COMMON = Makefile.am Makefile.in ordinals.h.in |
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) |
TAR = gtar |
GZIP_ENV = --best |
all: all-redirect |
.SUFFIXES: |
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) |
cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps include/FLAC/Makefile |
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status |
cd $(top_builddir) \ |
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status |
ordinals.h: $(top_builddir)/config.status ordinals.h.in |
cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status |
install-includeHEADERS: $(include_HEADERS) |
@$(NORMAL_INSTALL) |
$(mkinstalldirs) $(DESTDIR)$(includedir) |
@list='$(include_HEADERS)'; for p in $$list; do \ |
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \ |
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(includedir)/$$p"; \ |
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(includedir)/$$p; \ |
done |
uninstall-includeHEADERS: |
@$(NORMAL_UNINSTALL) |
list='$(include_HEADERS)'; for p in $$list; do \ |
rm -f $(DESTDIR)$(includedir)/$$p; \ |
done |
tags: TAGS |
ID: $(HEADERS) $(SOURCES) $(LISP) |
list='$(SOURCES) $(HEADERS)'; \ |
unique=`for i in $$list; do echo $$i; done | \ |
awk ' { files[$$0] = 1; } \ |
END { for (i in files) print i; }'`; \ |
here=`pwd` && cd $(srcdir) \ |
&& mkid -f$$here/ID $$unique $(LISP) |
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP) |
tags=; \ |
here=`pwd`; \ |
list='$(SOURCES) $(HEADERS)'; \ |
unique=`for i in $$list; do echo $$i; done | \ |
awk ' { files[$$0] = 1; } \ |
END { for (i in files) print i; }'`; \ |
test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \ |
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS) |
mostlyclean-tags: |
clean-tags: |
distclean-tags: |
-rm -f TAGS ID |
maintainer-clean-tags: |
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) |
subdir = include/FLAC |
distdir: $(DISTFILES) |
@for file in $(DISTFILES); do \ |
d=$(srcdir); \ |
if test -d $$d/$$file; then \ |
cp -pr $$d/$$file $(distdir)/$$file; \ |
else \ |
test -f $(distdir)/$$file \ |
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \ |
|| cp -p $$d/$$file $(distdir)/$$file || :; \ |
fi; \ |
done |
info-am: |
info: info-am |
dvi-am: |
dvi: dvi-am |
check-am: all-am |
check: check-am |
installcheck-am: |
installcheck: installcheck-am |
install-exec-am: |
install-exec: install-exec-am |
install-data-am: install-includeHEADERS |
install-data: install-data-am |
install-am: all-am |
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am |
install: install-am |
uninstall-am: uninstall-includeHEADERS |
uninstall: uninstall-am |
all-am: Makefile $(HEADERS) |
all-redirect: all-am |
install-strip: |
$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install |
installdirs: |
$(mkinstalldirs) $(DESTDIR)$(includedir) |
mostlyclean-generic: |
clean-generic: |
distclean-generic: |
-rm -f Makefile $(CONFIG_CLEAN_FILES) |
-rm -f config.cache config.log stamp-h stamp-h[0-9]* |
maintainer-clean-generic: |
mostlyclean-am: mostlyclean-tags mostlyclean-generic |
mostlyclean: mostlyclean-am |
clean-am: clean-tags clean-generic mostlyclean-am |
clean: clean-am |
distclean-am: distclean-tags distclean-generic clean-am |
-rm -f libtool |
distclean: distclean-am |
maintainer-clean-am: maintainer-clean-tags maintainer-clean-generic \ |
distclean-am |
@echo "This command is intended for maintainers to use;" |
@echo "it deletes files that may require special tools to rebuild." |
maintainer-clean: maintainer-clean-am |
.PHONY: uninstall-includeHEADERS install-includeHEADERS tags \ |
mostlyclean-tags distclean-tags clean-tags maintainer-clean-tags \ |
distdir info-am info dvi-am dvi check check-am installcheck-am \ |
installcheck install-exec-am install-exec install-data-am install-data \ |
install-am install uninstall-am uninstall all-redirect all-am all \ |
installdirs mostlyclean-generic distclean-generic clean-generic \ |
maintainer-clean-generic clean mostlyclean distclean maintainer-clean |
# Tell versions [3.59,3.63) of GNU make to not export all variables. |
# Otherwise a system limit (for SysV at least) may be exceeded. |
.NOEXPORT: |
/contrib/media/updf/include/FLAC/Makefile.am |
---|
0,0 → 1,29 |
# flac - Command-line FLAC encoder/decoder |
# Copyright (C) 2000,2001 Josh Coalson |
# |
# This program is free software; you can redistribute it and/or |
# modify it under the terms of the GNU General Public License |
# as published by the Free Software Foundation; either version 2 |
# of the License, or (at your option) any later version. |
# |
# This program is distributed in the hope that it will be useful, |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
# GNU General Public License for more details. |
# |
# You should have received a copy of the GNU General Public License |
# along with this program; if not, write to the Free Software |
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
includedir = ${prefix}/include/FLAC |
include_HEADERS = \ |
all.h \ |
assert.h \ |
file_decoder.h \ |
format.h \ |
ordinals.h \ |
seek_table.h \ |
stream_decoder.h \ |
stream_encoder.h \ |
utility.h |
/contrib/media/updf/include/FLAC/Makefile.in |
---|
0,0 → 1,262 |
# Makefile.in generated automatically by automake 1.4 from Makefile.am |
# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc. |
# This Makefile.in is free software; the Free Software Foundation |
# gives unlimited permission to copy and/or distribute it, |
# with or without modifications, as long as this notice is preserved. |
# This program is distributed in the hope that it will be useful, |
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without |
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A |
# PARTICULAR PURPOSE. |
# flac - Command-line FLAC encoder/decoder |
# Copyright (C) 2000,2001 Josh Coalson |
# |
# This program is free software; you can redistribute it and/or |
# modify it under the terms of the GNU General Public License |
# as published by the Free Software Foundation; either version 2 |
# of the License, or (at your option) any later version. |
# |
# This program is distributed in the hope that it will be useful, |
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
# GNU General Public License for more details. |
# |
# You should have received a copy of the GNU General Public License |
# along with this program; if not, write to the Free Software |
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
SHELL = @SHELL@ |
srcdir = @srcdir@ |
top_srcdir = @top_srcdir@ |
VPATH = @srcdir@ |
prefix = @prefix@ |
exec_prefix = @exec_prefix@ |
bindir = @bindir@ |
sbindir = @sbindir@ |
libexecdir = @libexecdir@ |
datadir = @datadir@ |
sysconfdir = @sysconfdir@ |
sharedstatedir = @sharedstatedir@ |
localstatedir = @localstatedir@ |
libdir = @libdir@ |
infodir = @infodir@ |
mandir = @mandir@ |
oldincludedir = /usr/include |
DESTDIR = |
pkgdatadir = $(datadir)/@PACKAGE@ |
pkglibdir = $(libdir)/@PACKAGE@ |
pkgincludedir = $(includedir)/@PACKAGE@ |
top_builddir = ../.. |
ACLOCAL = @ACLOCAL@ |
AUTOCONF = @AUTOCONF@ |
AUTOMAKE = @AUTOMAKE@ |
AUTOHEADER = @AUTOHEADER@ |
INSTALL = @INSTALL@ |
INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS) |
INSTALL_DATA = @INSTALL_DATA@ |
INSTALL_SCRIPT = @INSTALL_SCRIPT@ |
transform = @program_transform_name@ |
NORMAL_INSTALL = : |
PRE_INSTALL = : |
POST_INSTALL = : |
NORMAL_UNINSTALL = : |
PRE_UNINSTALL = : |
POST_UNINSTALL = : |
host_alias = @host_alias@ |
host_triplet = @host@ |
AS = @AS@ |
AWK = @AWK@ |
CC = @CC@ |
DLLTOOL = @DLLTOOL@ |
FLaC__SIZE16 = @FLaC__SIZE16@ |
FLaC__SIZE32 = @FLaC__SIZE32@ |
FLaC__SIZE64 = @FLaC__SIZE64@ |
FLaC__USIZE16 = @FLaC__USIZE16@ |
FLaC__USIZE32 = @FLaC__USIZE32@ |
FLaC__USIZE64 = @FLaC__USIZE64@ |
LIBTOOL = @LIBTOOL@ |
LN_S = @LN_S@ |
MAKEINFO = @MAKEINFO@ |
NASM = @NASM@ |
OBJDUMP = @OBJDUMP@ |
OBJ_FORMAT = @OBJ_FORMAT@ |
PACKAGE = @PACKAGE@ |
RANLIB = @RANLIB@ |
VERSION = @VERSION@ |
XMMS_CFLAGS = @XMMS_CFLAGS@ |
XMMS_CONFIG = @XMMS_CONFIG@ |
XMMS_DATA_DIR = @XMMS_DATA_DIR@ |
XMMS_EFFECT_PLUGIN_DIR = @XMMS_EFFECT_PLUGIN_DIR@ |
XMMS_GENERAL_PLUGIN_DIR = @XMMS_GENERAL_PLUGIN_DIR@ |
XMMS_INPUT_PLUGIN_DIR = @XMMS_INPUT_PLUGIN_DIR@ |
XMMS_LIBS = @XMMS_LIBS@ |
XMMS_OUTPUT_PLUGIN_DIR = @XMMS_OUTPUT_PLUGIN_DIR@ |
XMMS_PLUGIN_DIR = @XMMS_PLUGIN_DIR@ |
XMMS_VERSION = @XMMS_VERSION@ |
XMMS_VISUALIZATION_PLUGIN_DIR = @XMMS_VISUALIZATION_PLUGIN_DIR@ |
includedir = ${prefix}/include/FLAC |
include_HEADERS = all.h assert.h file_decoder.h format.h ordinals.h seek_table.h stream_decoder.h stream_encoder.h utility.h |
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs |
CONFIG_CLEAN_FILES = ordinals.h |
HEADERS = $(include_HEADERS) |
DIST_COMMON = Makefile.am Makefile.in ordinals.h.in |
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) |
TAR = gtar |
GZIP_ENV = --best |
all: all-redirect |
.SUFFIXES: |
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) |
cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps include/FLAC/Makefile |
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status |
cd $(top_builddir) \ |
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status |
ordinals.h: $(top_builddir)/config.status ordinals.h.in |
cd $(top_builddir) && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status |
install-includeHEADERS: $(include_HEADERS) |
@$(NORMAL_INSTALL) |
$(mkinstalldirs) $(DESTDIR)$(includedir) |
@list='$(include_HEADERS)'; for p in $$list; do \ |
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \ |
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(includedir)/$$p"; \ |
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(includedir)/$$p; \ |
done |
uninstall-includeHEADERS: |
@$(NORMAL_UNINSTALL) |
list='$(include_HEADERS)'; for p in $$list; do \ |
rm -f $(DESTDIR)$(includedir)/$$p; \ |
done |
tags: TAGS |
ID: $(HEADERS) $(SOURCES) $(LISP) |
list='$(SOURCES) $(HEADERS)'; \ |
unique=`for i in $$list; do echo $$i; done | \ |
awk ' { files[$$0] = 1; } \ |
END { for (i in files) print i; }'`; \ |
here=`pwd` && cd $(srcdir) \ |
&& mkid -f$$here/ID $$unique $(LISP) |
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP) |
tags=; \ |
here=`pwd`; \ |
list='$(SOURCES) $(HEADERS)'; \ |
unique=`for i in $$list; do echo $$i; done | \ |
awk ' { files[$$0] = 1; } \ |
END { for (i in files) print i; }'`; \ |
test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \ |
|| (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS) |
mostlyclean-tags: |
clean-tags: |
distclean-tags: |
-rm -f TAGS ID |
maintainer-clean-tags: |
distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) |
subdir = include/FLAC |
distdir: $(DISTFILES) |
@for file in $(DISTFILES); do \ |
d=$(srcdir); \ |
if test -d $$d/$$file; then \ |
cp -pr $$d/$$file $(distdir)/$$file; \ |
else \ |
test -f $(distdir)/$$file \ |
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \ |
|| cp -p $$d/$$file $(distdir)/$$file || :; \ |
fi; \ |
done |
info-am: |
info: info-am |
dvi-am: |
dvi: dvi-am |
check-am: all-am |
check: check-am |
installcheck-am: |
installcheck: installcheck-am |
install-exec-am: |
install-exec: install-exec-am |
install-data-am: install-includeHEADERS |
install-data: install-data-am |
install-am: all-am |
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am |
install: install-am |
uninstall-am: uninstall-includeHEADERS |
uninstall: uninstall-am |
all-am: Makefile $(HEADERS) |
all-redirect: all-am |
install-strip: |
$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install |
installdirs: |
$(mkinstalldirs) $(DESTDIR)$(includedir) |
mostlyclean-generic: |
clean-generic: |
distclean-generic: |
-rm -f Makefile $(CONFIG_CLEAN_FILES) |
-rm -f config.cache config.log stamp-h stamp-h[0-9]* |
maintainer-clean-generic: |
mostlyclean-am: mostlyclean-tags mostlyclean-generic |
mostlyclean: mostlyclean-am |
clean-am: clean-tags clean-generic mostlyclean-am |
clean: clean-am |
distclean-am: distclean-tags distclean-generic clean-am |
-rm -f libtool |
distclean: distclean-am |
maintainer-clean-am: maintainer-clean-tags maintainer-clean-generic \ |
distclean-am |
@echo "This command is intended for maintainers to use;" |
@echo "it deletes files that may require special tools to rebuild." |
maintainer-clean: maintainer-clean-am |
.PHONY: uninstall-includeHEADERS install-includeHEADERS tags \ |
mostlyclean-tags distclean-tags clean-tags maintainer-clean-tags \ |
distdir info-am info dvi-am dvi check check-am installcheck-am \ |
installcheck install-exec-am install-exec install-data-am install-data \ |
install-am install uninstall-am uninstall all-redirect all-am all \ |
installdirs mostlyclean-generic distclean-generic clean-generic \ |
maintainer-clean-generic clean mostlyclean distclean maintainer-clean |
# Tell versions [3.59,3.63) of GNU make to not export all variables. |
# Otherwise a system limit (for SysV at least) may be exceeded. |
.NOEXPORT: |
/contrib/media/updf/include/FLAC/all.h |
---|
0,0 → 1,32 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__ALL_H |
#define FLAC__ALL_H |
#include "assert.h" |
#include "file_decoder.h" |
#include "format.h" |
#include "ordinals.h" |
#include "seek_table.h" |
#include "stream_decoder.h" |
#include "stream_encoder.h" |
#include "utility.h" |
#endif |
/contrib/media/updf/include/FLAC/assert.h |
---|
0,0 → 1,31 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__ASSERT_H |
#define FLAC__ASSERT_H |
/* we need this since some compilers (like MSVC) leave asserts on release code (and we don't want to use their ASSERT) */ |
#ifdef DEBUG |
#include <assert.h> |
#define FLAC__ASSERT(x) assert(x) |
#else |
#define FLAC__ASSERT(x) |
#endif |
#endif |
/contrib/media/updf/include/FLAC/file_decoder.h |
---|
0,0 → 1,136 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__FILE_DECODER_H |
#define FLAC__FILE_DECODER_H |
#include "stream_decoder.h" |
typedef enum { |
FLAC__FILE_DECODER_OK = 0, |
FLAC__FILE_DECODER_SEEKING, |
FLAC__FILE_DECODER_END_OF_FILE, |
FLAC__FILE_DECODER_ERROR_OPENING_FILE, |
FLAC__FILE_DECODER_MEMORY_ALLOCATION_ERROR, |
FLAC__FILE_DECODER_SEEK_ERROR, |
FLAC__FILE_DECODER_STREAM_ERROR, |
FLAC__FILE_DECODER_MD5_ERROR, |
FLAC__FILE_DECODER_STREAM_DECODER_ERROR, |
FLAC__FILE_DECODER_ALREADY_INITIALIZED, |
FLAC__FILE_DECODER_INVALID_CALLBACK, |
FLAC__FILE_DECODER_UNINITIALIZED |
} FLAC__FileDecoderState; |
extern const char *FLAC__FileDecoderStateString[]; |
/*********************************************************************** |
* |
* class FLAC__FileDecoder : public FLAC__StreamDecoder |
* |
***********************************************************************/ |
struct FLAC__FileDecoderProtected; |
struct FLAC__FileDecoderPrivate; |
typedef struct { |
struct FLAC__FileDecoderProtected *protected; |
struct FLAC__FileDecoderPrivate *private; |
} FLAC__FileDecoder; |
/*********************************************************************** |
* |
* Class constructor/destructor |
* |
***********************************************************************/ |
/* |
* Any parameters that are not set before FLAC__file_decoder_init() |
* will take on the defaults from the constructor, shown below. |
* For more on what the parameters mean, see the documentation. |
* |
* FLAC__bool md5_checking (DEFAULT: false) MD5 checking will be turned off if a seek is requested |
* (*write_callback)() (DEFAULT: NULL ) The callbacks are the only values that MUST be set before FLAC__file_decoder_init() |
* (*metadata_callback)() (DEFAULT: NULL ) |
* (*error_callback)() (DEFAULT: NULL ) |
* void* client_data (DEFAULT: NULL ) passed back through the callbacks |
*/ |
FLAC__FileDecoder *FLAC__file_decoder_new(); |
void FLAC__file_decoder_delete(FLAC__FileDecoder *); |
/*********************************************************************** |
* |
* Public class method prototypes |
* |
***********************************************************************/ |
/* |
* Various "set" methods. These may only be called when the decoder |
* is in the state FLAC__FILE_DECODER_UNINITIALIZED, i.e. after |
* FLAC__file_decoder_new() or FLAC__file_decoder_finish(), but |
* before FLAC__file_decoder_init(). If this is the case they will |
* return true, otherwise false. |
* |
* NOTE that these functions do not validate the values as many are |
* interdependent. The FLAC__file_decoder_init() function will do |
* this, so make sure to pay attention to the state returned by |
* FLAC__file_decoder_init(). |
* |
* Any parameters that are not set before FLAC__file_decoder_init() |
* will take on the defaults from the constructor. NOTE that |
* FLAC__file_decoder_flush() or FLAC__file_decoder_reset() do |
* NOT reset the values to the constructor defaults. |
*/ |
FLAC__bool FLAC__file_decoder_set_md5_checking(const FLAC__FileDecoder *decoder, FLAC__bool value); |
FLAC__bool FLAC__file_decoder_set_filename(const FLAC__FileDecoder *decoder, const char *value); |
FLAC__bool FLAC__file_decoder_set_write_callback(const FLAC__FileDecoder *decoder, FLAC__StreamDecoderWriteStatus (*value)(const FLAC__FileDecoder *decoder, const FLAC__Frame *frame, const FLAC__int32 *buffer[], void *client_data)); |
FLAC__bool FLAC__file_decoder_set_metadata_callback(const FLAC__FileDecoder *decoder, void (*value)(const FLAC__FileDecoder *decoder, const FLAC__StreamMetaData *metadata, void *client_data)); |
FLAC__bool FLAC__file_decoder_set_error_callback(const FLAC__FileDecoder *decoder, void (*value)(const FLAC__FileDecoder *decoder, FLAC__StreamDecoderErrorStatus status, void *client_data)); |
FLAC__bool FLAC__file_decoder_set_client_data(const FLAC__FileDecoder *decoder, void *value); |
/* |
* Various "get" methods |
*/ |
FLAC__FileDecoderState FLAC__file_decoder_get_state(const FLAC__FileDecoder *decoder); |
FLAC__bool FLAC__file_decoder_get_md5_checking(const FLAC__FileDecoder *decoder); |
/* |
* Initialize the instance; should be called after construction and |
* 'set' calls but before any of the 'process' or 'seek' calls. Will |
* set and return the decoder state, which will be FLAC__FILE_DECODER_OK |
* if initializationsucceeded. |
*/ |
FLAC__FileDecoderState FLAC__file_decoder_init(FLAC__FileDecoder *decoder); |
/* |
* Flush the decoding buffer, release resources, and return the decoder |
* state to FLAC__FILE_DECODER_UNINITIALIZED. Only returns false if |
* md5_checking is set AND the stored MD5 sum is non-zero AND the stored |
* MD5 sum and computed MD5 sum do not match. |
*/ |
FLAC__bool FLAC__file_decoder_finish(FLAC__FileDecoder *decoder); |
/* |
* Methods for decoding the data |
*/ |
FLAC__bool FLAC__file_decoder_process_whole_file(FLAC__FileDecoder *decoder); |
FLAC__bool FLAC__file_decoder_process_metadata(FLAC__FileDecoder *decoder); |
FLAC__bool FLAC__file_decoder_process_one_frame(FLAC__FileDecoder *decoder); |
FLAC__bool FLAC__file_decoder_process_remaining_frames(FLAC__FileDecoder *decoder); |
FLAC__bool FLAC__file_decoder_seek_absolute(FLAC__FileDecoder *decoder, FLAC__uint64 sample); |
#endif |
/contrib/media/updf/include/FLAC/format.h |
---|
0,0 → 1,476 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__FORMAT_H |
#define FLAC__FORMAT_H |
#include "ordinals.h" |
/* changing the following values to be higher will break the framing and hence the stream format, so DON'T! */ |
#define FLAC__MIN_BLOCK_SIZE (16u) |
#define FLAC__MAX_BLOCK_SIZE (65535u) |
#define FLAC__MAX_CHANNELS (8u) |
#define FLAC__MIN_BITS_PER_SAMPLE (4u) |
/*NOTE: only up to 24 because of the current predictor coefficient quantization and the fact we use FLAC__int32s for all work */ |
#define FLAC__MAX_BITS_PER_SAMPLE (24u) |
/* the following is ((2 ** 20) - 1) div 10 */ |
#define FLAC__MAX_SAMPLE_RATE (1048570u) |
#define FLAC__MAX_LPC_ORDER (32u) |
#define FLAC__MIN_QLP_COEFF_PRECISION (5u) |
/* changing FLAC__MAX_FIXED_ORDER also means changing all of fixed.c and more, so DON'T! */ |
#define FLAC__MAX_FIXED_ORDER (4u) |
#define FLAC__MAX_RICE_PARTITION_ORDER (15u) |
/* VERSION should come from configure */ |
#ifdef VERSION |
#define FLAC__VERSION_STRING VERSION |
#endif |
extern const FLAC__byte FLAC__STREAM_SYNC_STRING[4]; /* = "fLaC" */; |
extern const unsigned FLAC__STREAM_SYNC; /* = 0x664C6143 */; |
extern const unsigned FLAC__STREAM_SYNC_LEN; /* = 32 bits */; |
/***************************************************************************** |
* |
* NOTE: Within the bitstream, all fixed-width numbers are big-endian coded. |
* All numbers are unsigned unless otherwise noted. |
* |
*****************************************************************************/ |
/***************************************************************************** |
* |
* Subframe structures |
* |
*****************************************************************************/ |
/*****************************************************************************/ |
typedef enum { |
FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE = 0 |
} FLAC__EntropyCodingMethodType; |
extern const char *FLAC__EntropyCodingMethodTypeString[]; |
/***************************************************************************** |
* |
* 4: partition order => (2 ** order) subdivisions |
*/ |
typedef struct { |
unsigned order; |
unsigned parameters[1 << FLAC__MAX_RICE_PARTITION_ORDER]; |
unsigned raw_bits[1 << FLAC__MAX_RICE_PARTITION_ORDER]; |
} FLAC__EntropyCodingMethod_PartitionedRice; |
extern const unsigned FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE_ORDER_LEN; /* = 4 bits */ |
extern const unsigned FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE_PARAMETER_LEN; /* = 4 bits */ |
extern const unsigned FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE_RAW_LEN; /* = 5 bits */ |
extern const unsigned FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE_ESCAPE_PARAMETER; /* = (1<<FLAC__ENTROPY_CODING_METHOD_PARTITIONED_RICE_PARAMETER_LEN)-1 */ |
/***************************************************************************** |
* |
* 2: entropy coding method: |
* 00: partitioned rice coding |
* 01-11: reserved |
* ?: entropy coding method data |
*/ |
typedef struct { |
FLAC__EntropyCodingMethodType type; |
union { |
FLAC__EntropyCodingMethod_PartitionedRice partitioned_rice; |
} data; |
} FLAC__EntropyCodingMethod; |
extern const unsigned FLAC__ENTROPY_CODING_METHOD_TYPE_LEN; /* = 2 bits */ |
/*****************************************************************************/ |
typedef enum { |
FLAC__SUBFRAME_TYPE_CONSTANT = 0, |
FLAC__SUBFRAME_TYPE_VERBATIM = 1, |
FLAC__SUBFRAME_TYPE_FIXED = 2, |
FLAC__SUBFRAME_TYPE_LPC = 3 |
} FLAC__SubframeType; |
extern const char *FLAC__SubframeTypeString[]; |
/***************************************************************************** |
* |
* n: constant value for signal; n = frame's bits-per-sample |
*/ |
typedef struct { |
FLAC__int32 value; |
} FLAC__Subframe_Constant; |
/***************************************************************************** |
* |
* n*i: unencoded signal; n = frame's bits-per-sample, i = frame's blocksize |
*/ |
typedef struct { |
const FLAC__int32 *data; |
} FLAC__Subframe_Verbatim; |
/***************************************************************************** |
* |
* n: unencoded warm-up samples (n = fixed-predictor order * bits per sample) |
* ?: entropy coding method info |
* ?: encoded residual ((blocksize minus fixed-predictor order) samples) |
* The order is stored in the main subframe header |
*/ |
typedef struct { |
FLAC__EntropyCodingMethod entropy_coding_method; |
unsigned order; |
FLAC__int32 warmup[FLAC__MAX_FIXED_ORDER]; |
const FLAC__int32 *residual; |
} FLAC__Subframe_Fixed; |
/***************************************************************************** |
* |
* n: unencoded warm-up samples (n = lpc order * bits per sample) |
* 4: (qlp coeff precision in bits)-1 (1111 = invalid, use to check for erroneous sync) |
* 5: qlp shift needed in bits (signed) |
* n: unencoded predictor coefficients (n = lpc order * qlp coeff precision) |
* ?: entropy coding method info |
* ?: encoded residual ((blocksize minus lpc order) samples) |
* The order is stored in the main subframe header |
*/ |
typedef struct { |
FLAC__EntropyCodingMethod entropy_coding_method; |
unsigned order; |
unsigned qlp_coeff_precision; |
int quantization_level; |
FLAC__int32 qlp_coeff[FLAC__MAX_LPC_ORDER]; |
FLAC__int32 warmup[FLAC__MAX_LPC_ORDER]; |
const FLAC__int32 *residual; |
} FLAC__Subframe_LPC; |
extern const unsigned FLAC__SUBFRAME_LPC_QLP_COEFF_PRECISION_LEN; /* = 4 bits */ |
extern const unsigned FLAC__SUBFRAME_LPC_QLP_SHIFT_LEN; /* = 5 bits */ |
/***************************************************************************** |
* |
* 1: zero pad, to prevent sync-fooling string of 1s (use to check for erroneous sync) |
* 6: subframe type |
* 000000: constant value |
* 000001: verbatim |
* 00001x: reserved |
* 0001xx: reserved |
* 001xxx: fixed predictor, xxx=order <= 4, else reserved |
* 01xxxx: reserved |
* 1xxxxx: lpc, xxxxx=order-1 |
* 1: 'wasted bits' flag |
* 0: no wasted bits in source subblock |
* 1: all samples in source subblock contain n 0 least significant bits. n-1 follows, unary coded, i.e. n=3, 001 follows, n=7, 0000001 follows. |
* ?: unary coded (n-1) |
* ?: subframe-specific data (c.f. FLAC__Subframe_*) |
*/ |
typedef struct { |
FLAC__SubframeType type; |
union { |
FLAC__Subframe_Constant constant; |
FLAC__Subframe_Fixed fixed; |
FLAC__Subframe_LPC lpc; |
FLAC__Subframe_Verbatim verbatim; |
} data; |
unsigned wasted_bits; |
} FLAC__Subframe; |
extern const unsigned FLAC__SUBFRAME_ZERO_PAD_LEN; /* = 1 bit */ |
extern const unsigned FLAC__SUBFRAME_TYPE_LEN; /* = 6 bits */ |
extern const unsigned FLAC__SUBFRAME_WASTED_BITS_FLAG_LEN; /* = 1 bit */ |
extern const unsigned FLAC__SUBFRAME_TYPE_CONSTANT_BYTE_ALIGNED_MASK; /* = 0x00 */ |
extern const unsigned FLAC__SUBFRAME_TYPE_VERBATIM_BYTE_ALIGNED_MASK; /* = 0x02 */ |
extern const unsigned FLAC__SUBFRAME_TYPE_FIXED_BYTE_ALIGNED_MASK; /* = 0x10 */ |
extern const unsigned FLAC__SUBFRAME_TYPE_LPC_BYTE_ALIGNED_MASK; /* = 0x40 */ |
/*****************************************************************************/ |
/***************************************************************************** |
* |
* Frame structures |
* |
*****************************************************************************/ |
typedef enum { |
FLAC__CHANNEL_ASSIGNMENT_INDEPENDENT = 0, |
FLAC__CHANNEL_ASSIGNMENT_LEFT_SIDE = 1, |
FLAC__CHANNEL_ASSIGNMENT_RIGHT_SIDE = 2, |
FLAC__CHANNEL_ASSIGNMENT_MID_SIDE = 3 |
} FLAC__ChannelAssignment; |
extern const char *FLAC__ChannelAssignmentString[]; |
typedef enum { |
FLAC__FRAME_NUMBER_TYPE_FRAME_NUMBER, |
FLAC__FRAME_NUMBER_TYPE_SAMPLE_NUMBER |
} FLAC__FrameNumberType; |
extern const char *FLAC__FrameNumberTypeString[]; |
/***************************************************************************** |
* |
* 14: sync code '11111111111110' |
* 2: reserved |
* 00: currently required value |
* 01-11: reserved |
* 4: blocksize in samples |
* 0000: get from stream header => implies constant blocksize throughout stream |
* 0001: 192 samples (AES/EBU) => implies constant blocksize throughout stream |
* 0010-0101: 576 * (2^(n-2)) samples, i.e. 576/1152/2304/4608 => implies constant blocksize throughout stream |
* 0110: get 8 bit (blocksize-1) from end of header => possibly variable blocksize throughout stream unless it's the last frame |
* 0111: get 16 bit (blocksize-1) from end of header => possibly variable blocksize throughout stream unless it's the last frame |
* 1000-1111: 256 * (2^(n-8)) samples, i.e. 256/512/1024/2048/4096/8192/16384/32768 => implies constant blocksize throughout stream |
* 4: sample rate: |
* 0000: get from stream header |
* 0001-0011: reserved |
* 0100: 8kHz |
* 0101: 16kHz |
* 0110: 22.05kHz |
* 0111: 24kHz |
* 1000: 32kHz |
* 1001: 44.1kHz |
* 1010: 48kHz |
* 1011: 96kHz |
* 1100: get 8 bit sample rate (in kHz) from end of header |
* 1101: get 16 bit sample rate (in Hz) from end of header |
* 1110: get 16 bit sample rate (in tens of Hz) from end of header |
* 1111: invalid, to prevent sync-fooling string of 1s (use to check for erroneous sync) |
* 4: channel assignment |
* 0000-0111: (number of independent channels)-1. when == 0001, channel 0 is the left channel and channel 1 is the right |
* 1000: left/side stereo : channel 0 is the left channel, channel 1 is the side(difference) channel |
* 1001: right/side stereo: channel 0 is the side(difference) channel, channel 1 is the right channel |
* 1010: mid/side stereo : channel 0 is the mid(average) channel, channel 1 is the side(difference) channel |
* 1011-1111: reserved |
* 3: sample size in bits |
* 000: get from stream header |
* 001: 8 bits per sample |
* 010: 12 bits per sample |
* 011: reserved |
* 100: 16 bits per sample |
* 101: 20 bits per sample |
* 110: 24 bits per sample |
* 111: reserved |
* 1: zero pad, to prevent sync-fooling string of 1s (use to check for erroneous sync) |
* ?: if(variable blocksize) |
* 8-56: 'UTF-8' coded sample number (decoded number is 0-36 bits) (use to check for erroneous sync) |
* else |
* 8-48: 'UTF-8' coded frame number (decoded number is 0-31 bits) (use to check for erroneous sync) |
* ?: if(blocksize bits == 11x) |
* 8/16 bit (blocksize-1) |
* ?: if(sample rate bits == 11xx) |
* 8/16 bit sample rate |
* 8: CRC-8 (polynomial = x^8 + x^2 + x^1 + x^0, initialized with 0) of everything before the crc, including the sync code |
*/ |
typedef struct { |
unsigned blocksize; /* in samples */ |
unsigned sample_rate; /* in Hz */ |
unsigned channels; |
FLAC__ChannelAssignment channel_assignment; |
unsigned bits_per_sample; |
FLAC__FrameNumberType number_type; |
union { |
FLAC__uint32 frame_number; |
FLAC__uint64 sample_number; |
} number; |
FLAC__uint8 crc; |
} FLAC__FrameHeader; |
extern const unsigned FLAC__FRAME_HEADER_SYNC; /* = 0x3ffe */ |
extern const unsigned FLAC__FRAME_HEADER_SYNC_LEN; /* = 14 bits */ |
extern const unsigned FLAC__FRAME_HEADER_RESERVED_LEN; /* = 2 bits */ |
extern const unsigned FLAC__FRAME_HEADER_BLOCK_SIZE_LEN; /* = 4 bits */ |
extern const unsigned FLAC__FRAME_HEADER_SAMPLE_RATE_LEN; /* = 4 bits */ |
extern const unsigned FLAC__FRAME_HEADER_CHANNEL_ASSIGNMENT_LEN; /* = 4 bits */ |
extern const unsigned FLAC__FRAME_HEADER_BITS_PER_SAMPLE_LEN; /* = 3 bits */ |
extern const unsigned FLAC__FRAME_HEADER_ZERO_PAD_LEN; /* = 1 bit */ |
extern const unsigned FLAC__FRAME_HEADER_CRC_LEN; /* = 8 bits */ |
/***************************************************************************** |
* |
* 16: CRC-16 (polynomial = x^16 + x^15 + x^2 + x^0, initialized with 0) of everything before the crc, back to and including the frame header sync code |
*/ |
typedef struct { |
FLAC__uint16 crc; |
} FLAC__FrameFooter; |
extern const unsigned FLAC__FRAME_FOOTER_CRC_LEN; /* = 16 bits */ |
typedef struct { |
FLAC__FrameHeader header; |
FLAC__Subframe subframes[FLAC__MAX_CHANNELS]; |
FLAC__FrameFooter footer; |
} FLAC__Frame; |
/*****************************************************************************/ |
/***************************************************************************** |
* |
* Meta-data structures |
* |
*****************************************************************************/ |
typedef enum { |
FLAC__METADATA_TYPE_STREAMINFO = 0, |
FLAC__METADATA_TYPE_PADDING = 1, |
FLAC__METADATA_TYPE_APPLICATION = 2, |
FLAC__METADATA_TYPE_SEEKTABLE = 3 |
} FLAC__MetaDataType; |
extern const char *FLAC__MetaDataTypeString[]; |
/***************************************************************************** |
* |
* 16: minimum blocksize (in samples) of all blocks in the stream |
* 16: maximum blocksize (in samples) of all blocks in the stream |
* 24: minimum framesize (in bytes) of all frames in the stream; 0 => unknown |
* 24: maximum framesize (in bytes) of all frames in the stream; 0 => unknown |
* 20: sample rate in Hz, 0 is invalid |
* 3: (number of channels)-1 |
* 5: (bits per sample)-1 |
* 36: total samples, 0 => unknown |
*128: MD5 digest of the original unencoded audio data |
*---- ----------------- |
* 34 bytes total |
*/ |
typedef struct { |
unsigned min_blocksize, max_blocksize; |
unsigned min_framesize, max_framesize; |
unsigned sample_rate; |
unsigned channels; |
unsigned bits_per_sample; |
FLAC__uint64 total_samples; |
FLAC__byte md5sum[16]; |
} FLAC__StreamMetaData_StreamInfo; |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_MIN_BLOCK_SIZE_LEN; /* = 16 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_MAX_BLOCK_SIZE_LEN; /* = 16 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_MIN_FRAME_SIZE_LEN; /* = 24 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_MAX_FRAME_SIZE_LEN; /* = 24 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_SAMPLE_RATE_LEN; /* = 20 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_CHANNELS_LEN; /* = 3 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_BITS_PER_SAMPLE_LEN; /* = 5 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_TOTAL_SAMPLES_LEN; /* = 36 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_MD5SUM_LEN; /* = 128 bits */ |
extern const unsigned FLAC__STREAM_METADATA_STREAMINFO_LENGTH; /* = 34 bytes */ |
/***************************************************************************** |
* |
* n: '0' bits |
*----- ----------------- |
* n/8 bytes total |
*/ |
typedef struct { |
int dummy; /* conceptually this is an empty struct since we don't store the padding bytes */ |
/* empty structs are allowed by C++ but not C, hence the 'dummy' */ |
} FLAC__StreamMetaData_Padding; |
/***************************************************************************** |
* |
* 32: Registered application ID |
* n: Application data |
*------- ----------------- |
* 4+n/8 bytes total |
*/ |
typedef struct { |
FLAC__byte id[4]; |
FLAC__byte *data; |
} FLAC__StreamMetaData_Application; |
extern const unsigned FLAC__STREAM_METADATA_APPLICATION_ID_LEN; /* = 32 bits */ |
/***************************************************************************** |
* |
* 64: sample number of target frame |
* 64: offset, in bytes, of target frame with respect to beginning of first frame |
* 16: number of samples in the target frame |
*----- ----------------- |
* 18 bytes total |
*/ |
typedef struct { |
FLAC__uint64 sample_number; |
FLAC__uint64 stream_offset; |
unsigned frame_samples; |
} FLAC__StreamMetaData_SeekPoint; |
extern const unsigned FLAC__STREAM_METADATA_SEEKPOINT_SAMPLE_NUMBER_LEN; /* = 64 bits */ |
extern const unsigned FLAC__STREAM_METADATA_SEEKPOINT_STREAM_OFFSET_LEN; /* = 64 bits */ |
extern const unsigned FLAC__STREAM_METADATA_SEEKPOINT_FRAME_SAMPLES_LEN; /* = 16 bits */ |
extern const unsigned FLAC__STREAM_METADATA_SEEKPOINT_LEN; /* = 18 bytes */ |
extern const FLAC__uint64 FLAC__STREAM_METADATA_SEEKPOINT_PLACEHOLDER; /* = 0xffffffffffffffff */ |
/***************************************************************************** |
* |
* 0: num_points is implied by the metadata block 'length' field (i.e. num_points = length / 18) |
* n*18*8: seek points (n = num_points, 18 is the size of a seek point in bytes) |
* ------- ----------------- |
* n*18 bytes total |
* |
* NOTE: the seek points must be sorted by ascending sample number. |
* NOTE: each seek point's sample number must be the first sample of the target frame. |
* NOTE: each seek point's sample number must be unique within the table. |
* NOTE: existence of a SEEKTABLE block implies a correct setting of total_samples in the stream_info block. |
* NOTE: behavior is undefined when more than one SEEKTABLE block is present in a stream. |
*/ |
typedef struct { |
unsigned num_points; |
FLAC__StreamMetaData_SeekPoint *points; |
} FLAC__StreamMetaData_SeekTable; |
/***************************************************************************** |
* |
* 1: =1 if this is the last meta-data block, else =0 |
* 7: meta-data type (c.f. FLAC__MetaDataType) |
* 24: length (in bytes) of the block-specific data to follow |
*---- ----------------- |
* 4 bytes total |
*/ |
typedef struct { |
FLAC__MetaDataType type; |
FLAC__bool is_last; |
unsigned length; /* in bytes */ |
union { |
FLAC__StreamMetaData_StreamInfo stream_info; |
FLAC__StreamMetaData_Padding padding; |
FLAC__StreamMetaData_Application application; |
FLAC__StreamMetaData_SeekTable seek_table; |
} data; |
} FLAC__StreamMetaData; |
extern const unsigned FLAC__STREAM_METADATA_IS_LAST_LEN; /* = 1 bits */ |
extern const unsigned FLAC__STREAM_METADATA_TYPE_LEN; /* = 7 bits */ |
extern const unsigned FLAC__STREAM_METADATA_LENGTH_LEN; /* = 24 bits */ |
/*****************************************************************************/ |
/***************************************************************************** |
* |
* Stream structures |
* |
*****************************************************************************/ |
typedef struct { |
FLAC__StreamMetaData_StreamInfo stream_info; |
FLAC__Frame *frames; |
} FLAC__Stream; |
/*****************************************************************************/ |
#endif |
/contrib/media/updf/include/FLAC/ordinals.h |
---|
0,0 → 1,56 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__ORDINALS_H |
#define FLAC__ORDINALS_H |
#ifdef true |
#undef true |
#endif |
#ifdef false |
#undef false |
#endif |
#define true 1 |
#define false 0 |
typedef int FLAC__bool; |
typedef signed char FLAC__int8; |
typedef unsigned char FLAC__uint8; |
#ifdef _MSC_VER |
typedef __int16 FLAC__int16; |
typedef __int32 FLAC__int32; |
typedef __int64 FLAC__int64; |
typedef unsigned __int16 FLAC__uint16; |
typedef unsigned __int32 FLAC__uint32; |
typedef unsigned __int64 FLAC__uint64; |
#else |
typedef short FLAC__int16; |
typedef int FLAC__int32; |
typedef long long FLAC__int64; |
typedef unsigned short FLAC__uint16; |
typedef unsigned int FLAC__uint32; |
typedef unsigned long long FLAC__uint64; |
#endif |
typedef FLAC__uint8 FLAC__byte; |
typedef float FLAC__real; |
#endif |
/contrib/media/updf/include/FLAC/ordinals.h.in |
---|
0,0 → 1,56 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__ORDINALS_H |
#define FLAC__ORDINALS_H |
#ifdef true |
#undef true |
#endif |
#ifdef false |
#undef false |
#endif |
#define true 1 |
#define false 0 |
typedef int FLAC__bool; |
typedef signed char FLAC__int8; |
typedef unsigned char FLAC__uint8; |
#ifdef _MSC_VER |
typedef __int16 FLAC__int16; |
typedef __int32 FLAC__int32; |
typedef __int64 FLAC__int64; |
typedef unsigned __int16 FLAC__uint16; |
typedef unsigned __int32 FLAC__uint32; |
typedef unsigned __int64 FLAC__uint64; |
#else |
typedef @FLaC__SIZE16@ FLAC__int16; |
typedef @FLaC__SIZE32@ FLAC__int32; |
typedef @FLaC__SIZE64@ FLAC__int64; |
typedef @FLaC__USIZE16@ FLAC__uint16; |
typedef @FLaC__USIZE32@ FLAC__uint32; |
typedef @FLaC__USIZE64@ FLAC__uint64; |
#endif |
typedef FLAC__uint8 FLAC__byte; |
typedef float FLAC__real; |
#endif |
/contrib/media/updf/include/FLAC/seek_table.h |
---|
0,0 → 1,27 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__SEEK_TABLE_H |
#define FLAC__SEEK_TABLE_H |
#include "format.h" |
FLAC__bool FLAC__seek_table_is_valid(const FLAC__StreamMetaData_SeekTable *seek_table); |
#endif |
/contrib/media/updf/include/FLAC/stream_decoder.h |
---|
0,0 → 1,164 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__STREAM_DECODER_H |
#define FLAC__STREAM_DECODER_H |
#include "format.h" |
typedef enum { |
FLAC__STREAM_DECODER_SEARCH_FOR_METADATA = 0, |
FLAC__STREAM_DECODER_READ_METADATA, |
FLAC__STREAM_DECODER_SEARCH_FOR_FRAME_SYNC, |
FLAC__STREAM_DECODER_READ_FRAME, |
FLAC__STREAM_DECODER_END_OF_STREAM, |
FLAC__STREAM_DECODER_ABORTED, |
FLAC__STREAM_DECODER_UNPARSEABLE_STREAM, |
FLAC__STREAM_DECODER_MEMORY_ALLOCATION_ERROR, |
FLAC__STREAM_DECODER_ALREADY_INITIALIZED, |
FLAC__STREAM_DECODER_INVALID_CALLBACK, |
FLAC__STREAM_DECODER_UNINITIALIZED |
} FLAC__StreamDecoderState; |
extern const char *FLAC__StreamDecoderStateString[]; |
typedef enum { |
FLAC__STREAM_DECODER_READ_CONTINUE, |
FLAC__STREAM_DECODER_READ_END_OF_STREAM, |
FLAC__STREAM_DECODER_READ_ABORT |
} FLAC__StreamDecoderReadStatus; |
extern const char *FLAC__StreamDecoderReadStatusString[]; |
typedef enum { |
FLAC__STREAM_DECODER_WRITE_CONTINUE, |
FLAC__STREAM_DECODER_WRITE_ABORT |
} FLAC__StreamDecoderWriteStatus; |
extern const char *FLAC__StreamDecoderWriteStatusString[]; |
typedef enum { |
FLAC__STREAM_DECODER_ERROR_LOST_SYNC, |
FLAC__STREAM_DECODER_ERROR_BAD_HEADER, |
FLAC__STREAM_DECODER_ERROR_FRAME_CRC_MISMATCH |
} FLAC__StreamDecoderErrorStatus; |
extern const char *FLAC__StreamDecoderErrorStatusString[]; |
/*********************************************************************** |
* |
* class FLAC__StreamDecoder |
* |
***********************************************************************/ |
struct FLAC__StreamDecoderProtected; |
struct FLAC__StreamDecoderPrivate; |
typedef struct { |
struct FLAC__StreamDecoderProtected *protected; |
struct FLAC__StreamDecoderPrivate *private; |
} FLAC__StreamDecoder; |
/*********************************************************************** |
* |
* Class constructor/destructor |
* |
***********************************************************************/ |
/* |
* Any parameters that are not set before FLAC__stream_decoder_init() |
* will take on the defaults from the constructor, shown below. |
* For more on what the parameters mean, see the documentation. |
* |
* (*read_callback)() (DEFAULT: NULL ) The callbacks are the only values that MUST be set before FLAC__stream_decoder_init() |
* (*write_callback)() (DEFAULT: NULL ) |
* (*metadata_callback)() (DEFAULT: NULL ) |
* (*error_callback)() (DEFAULT: NULL ) |
* void* client_data (DEFAULT: NULL ) passed back through the callbacks |
*/ |
FLAC__StreamDecoder *FLAC__stream_decoder_new(); |
void FLAC__stream_decoder_delete(FLAC__StreamDecoder *); |
/*********************************************************************** |
* |
* Public class method prototypes |
* |
***********************************************************************/ |
/* |
* Various "set" methods. These may only be called when the decoder |
* is in the state FLAC__STREAM_DECODER_UNINITIALIZED, i.e. after |
* FLAC__stream_decoder_new() or FLAC__stream_decoder_finish(), but |
* before FLAC__stream_decoder_init(). If this is the case they will |
* return true, otherwise false. |
* |
* NOTE that these functions do not validate the values as many are |
* interdependent. The FLAC__stream_decoder_init() function will do |
* this, so make sure to pay attention to the state returned by |
* FLAC__stream_decoder_init(). |
* |
* Any parameters that are not set before FLAC__stream_decoder_init() |
* will take on the defaults from the constructor. NOTE that |
* FLAC__stream_decoder_flush() or FLAC__stream_decoder_reset() do |
* NOT reset the values to the constructor defaults. |
*/ |
FLAC__bool FLAC__stream_decoder_set_read_callback(const FLAC__StreamDecoder *decoder, FLAC__StreamDecoderReadStatus (*value)(const FLAC__StreamDecoder *decoder, FLAC__byte buffer[], unsigned *bytes, void *client_data)); |
FLAC__bool FLAC__stream_decoder_set_write_callback(const FLAC__StreamDecoder *decoder, FLAC__StreamDecoderWriteStatus (*value)(const FLAC__StreamDecoder *decoder, const FLAC__Frame *frame, const FLAC__int32 *buffer[], void *client_data)); |
FLAC__bool FLAC__stream_decoder_set_metadata_callback(const FLAC__StreamDecoder *decoder, void (*value)(const FLAC__StreamDecoder *decoder, const FLAC__StreamMetaData *metadata, void *client_data)); |
FLAC__bool FLAC__stream_decoder_set_error_callback(const FLAC__StreamDecoder *decoder, void (*value)(const FLAC__StreamDecoder *decoder, FLAC__StreamDecoderErrorStatus status, void *client_data)); |
FLAC__bool FLAC__stream_decoder_set_client_data(const FLAC__StreamDecoder *decoder, void *value); |
/* |
* Methods to return the current stream decoder state, number |
* of channels, channel assignment, bits-per-sample, sample |
* rate in Hz, and blocksize in samples. All but the decoder |
* state will only be valid after decoding has started. |
*/ |
FLAC__StreamDecoderState FLAC__stream_decoder_get_state(const FLAC__StreamDecoder *decoder); |
unsigned FLAC__stream_decoder_get_channels(const FLAC__StreamDecoder *decoder); |
FLAC__ChannelAssignment FLAC__stream_decoder_get_channel_assignment(const FLAC__StreamDecoder *decoder); |
unsigned FLAC__stream_decoder_get_bits_per_sample(const FLAC__StreamDecoder *decoder); |
unsigned FLAC__stream_decoder_get_sample_rate(const FLAC__StreamDecoder *decoder); |
unsigned FLAC__stream_decoder_get_blocksize(const FLAC__StreamDecoder *decoder); |
/* |
* Initialize the instance; should be called after construction and |
* 'set' calls but before any of the 'process' calls. Will set and |
* return the decoder state, which will be |
* FLAC__STREAM_DECODER_SEARCH_FOR_METADATA if initialization |
* succeeded. |
*/ |
FLAC__StreamDecoderState FLAC__stream_decoder_init(FLAC__StreamDecoder *decoder); |
/* |
* Flush the decoding buffer, release resources, and return the decoder |
* state to FLAC__STREAM_DECODER_UNINITIALIZED. |
*/ |
void FLAC__stream_decoder_finish(FLAC__StreamDecoder *decoder); |
/* |
* state control methods |
*/ |
FLAC__bool FLAC__stream_decoder_flush(FLAC__StreamDecoder *decoder); |
FLAC__bool FLAC__stream_decoder_reset(FLAC__StreamDecoder *decoder); |
/* |
* Methods for decoding the data |
*/ |
FLAC__bool FLAC__stream_decoder_process_whole_stream(FLAC__StreamDecoder *decoder); |
FLAC__bool FLAC__stream_decoder_process_metadata(FLAC__StreamDecoder *decoder); |
FLAC__bool FLAC__stream_decoder_process_one_frame(FLAC__StreamDecoder *decoder); |
FLAC__bool FLAC__stream_decoder_process_remaining_frames(FLAC__StreamDecoder *decoder); |
#endif |
/contrib/media/updf/include/FLAC/stream_encoder.h |
---|
0,0 → 1,193 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2000,2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__STREAM_ENCODER_H |
#define FLAC__STREAM_ENCODER_H |
#include "format.h" |
typedef enum { |
FLAC__STREAM_ENCODER_OK = 0, |
FLAC__STREAM_ENCODER_INVALID_CALLBACK, |
FLAC__STREAM_ENCODER_INVALID_NUMBER_OF_CHANNELS, |
FLAC__STREAM_ENCODER_INVALID_BITS_PER_SAMPLE, |
FLAC__STREAM_ENCODER_INVALID_SAMPLE_RATE, |
FLAC__STREAM_ENCODER_INVALID_BLOCK_SIZE, |
FLAC__STREAM_ENCODER_INVALID_QLP_COEFF_PRECISION, |
FLAC__STREAM_ENCODER_MID_SIDE_CHANNELS_MISMATCH, |
FLAC__STREAM_ENCODER_MID_SIDE_SAMPLE_SIZE_MISMATCH, |
FLAC__STREAM_ENCODER_ILLEGAL_MID_SIDE_FORCE, |
FLAC__STREAM_ENCODER_BLOCK_SIZE_TOO_SMALL_FOR_LPC_ORDER, |
FLAC__STREAM_ENCODER_NOT_STREAMABLE, |
FLAC__STREAM_ENCODER_FRAMING_ERROR, |
FLAC__STREAM_ENCODER_INVALID_SEEK_TABLE, |
FLAC__STREAM_ENCODER_FATAL_ERROR_WHILE_ENCODING, |
FLAC__STREAM_ENCODER_FATAL_ERROR_WHILE_WRITING, /* that is, the write_callback returned an error */ |
FLAC__STREAM_ENCODER_MEMORY_ALLOCATION_ERROR, |
FLAC__STREAM_ENCODER_ALREADY_INITIALIZED, |
FLAC__STREAM_ENCODER_UNINITIALIZED |
} FLAC__StreamEncoderState; |
extern const char *FLAC__StreamEncoderStateString[]; |
typedef enum { |
FLAC__STREAM_ENCODER_WRITE_OK = 0, |
FLAC__STREAM_ENCODER_WRITE_FATAL_ERROR |
} FLAC__StreamEncoderWriteStatus; |
extern const char *FLAC__StreamEncoderWriteStatusString[]; |
/*********************************************************************** |
* |
* class FLAC__StreamEncoder |
* |
***********************************************************************/ |
struct FLAC__StreamEncoderProtected; |
struct FLAC__StreamEncoderPrivate; |
typedef struct { |
struct FLAC__StreamEncoderProtected *protected; |
struct FLAC__StreamEncoderPrivate *private; |
} FLAC__StreamEncoder; |
/*********************************************************************** |
* |
* Class constructor/destructor |
* |
***********************************************************************/ |
/* |
* Any parameters that are not set before FLAC__stream_encoder_init() |
* will take on the defaults from the constructor, shown below. |
* For more on what the parameters mean, see the documentation. |
* |
* FLAC__bool streamable_subset (DEFAULT: true ) true to limit encoder to generating a Subset stream, else false |
* FLAC__bool do_mid_side_stereo (DEFAULT: false) if true then channels must be 2 |
* FLAC__bool loose_mid_side_stereo (DEFAULT: false) if true then do_mid_side_stereo must be true |
* unsigned channels (DEFAULT: 2 ) must be <= FLAC__MAX_CHANNELS |
* unsigned bits_per_sample (DEFAULT: 16 ) do not give the encoder wider data than what you specify here or bad things will happen! |
* unsigned sample_rate (DEFAULT: 44100) |
* unsigned blocksize (DEFAULT: 1152 ) |
* unsigned max_lpc_order (DEFAULT: 0 ) 0 => encoder will not try general LPC, only fixed predictors; must be <= FLAC__MAX_LPC_ORDER |
* unsigned qlp_coeff_precision (DEFAULT: 0 ) >= FLAC__MIN_QLP_COEFF_PRECISION, or 0 to let encoder select based on blocksize; |
* qlp_coeff_precision+bits_per_sample must be < 32 |
* FLAC__bool do_qlp_coeff_prec_search (DEFAULT: false) false => use qlp_coeff_precision, true => search around qlp_coeff_precision, take best |
* FLAC__bool do_escape_coding (DEFAULT: false) true => search for escape codes in the entropy coding stage for slightly better compression |
* FLAC__bool do_exhaustive_model_search (DEFAULT: false) false => use estimated bits per residual for scoring, true => generate all, take shortest |
* unsigned min_residual_partition_order (DEFAULT: 0 ) 0 => estimate Rice parameter based on residual variance; >0 => partition residual, use parameter |
* unsigned max_residual_partition_order (DEFAULT: 0 ) for each based on mean; min_ and max_ specify the min and max Rice partition order |
* unsigned rice_parameter_search_dist (DEFAULT: 0 ) 0 => try only calc'd parameter k; else try all [k-dist..k+dist] parameters, use best |
* FLAC__uint64 total_samples_estimate (DEFAULT: 0 ) may be 0 if unknown. acts as a placeholder in the STREAMINFO until the actual total is calculated |
* const FLAC__StreamMetaData_SeekTable *seek_table (DEFAULT: NULL) optional seek_table to prepend, NULL => no seek table |
* unsigned padding (DEFAULT: 0 ) size of PADDING block to add (goes after seek table); 0 => do not add a PADDING block |
* FLAC__bool last_metadata_is_last (DEFAULT: true ) the value the encoder will use for the 'is_last' flag of the last metadata block it writes; set |
* this to false if you will be adding more metadata blocks before the audio frames, else true |
* (*write_callback)() (DEFAULT: NULL ) The callbacks are the only values that MUST be set before FLAC__stream_encoder_init() |
* (*metadata_callback)() (DEFAULT: NULL ) |
* void* client_data (DEFAULT: NULL ) passed back through the callbacks |
*/ |
FLAC__StreamEncoder *FLAC__stream_encoder_new(); |
void FLAC__stream_encoder_delete(FLAC__StreamEncoder *encoder); |
/*********************************************************************** |
* |
* Public class method prototypes |
* |
***********************************************************************/ |
/* |
* Various "set" methods. These may only be called when the encoder |
* is in the state FLAC__STREAM_ENCODER_UNINITIALIZED, i.e. after |
* FLAC__stream_encoder_new() or FLAC__stream_encoder_finish(), but |
* before FLAC__stream_encoder_init(). If this is the case they will |
* return true, otherwise false. |
* |
* NOTE that these functions do not validate the values as many are |
* interdependent. The FLAC__stream_encoder_init() function will do |
* this, so make sure to pay attention to the state returned by |
* FLAC__stream_encoder_init(). |
* |
* Any parameters that are not set before FLAC__stream_encoder_init() |
* will take on the defaults from the constructor. NOTE that |
* FLAC__stream_encoder_finish() does NOT reset the values to the |
* constructor defaults. |
*/ |
FLAC__bool FLAC__stream_encoder_set_streamable_subset(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_do_mid_side_stereo(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_loose_mid_side_stereo(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_channels(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_bits_per_sample(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_sample_rate(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_blocksize(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_max_lpc_order(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_qlp_coeff_precision(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_do_qlp_coeff_prec_search(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_do_escape_coding(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_do_exhaustive_model_search(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_min_residual_partition_order(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_max_residual_partition_order(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_rice_parameter_search_dist(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_total_samples_estimate(const FLAC__StreamEncoder *encoder, FLAC__uint64 value); |
FLAC__bool FLAC__stream_encoder_set_seek_table(const FLAC__StreamEncoder *encoder, const FLAC__StreamMetaData_SeekTable *value); |
FLAC__bool FLAC__stream_encoder_set_padding(const FLAC__StreamEncoder *encoder, unsigned value); |
FLAC__bool FLAC__stream_encoder_set_last_metadata_is_last(const FLAC__StreamEncoder *encoder, FLAC__bool value); |
FLAC__bool FLAC__stream_encoder_set_write_callback(const FLAC__StreamEncoder *encoder, FLAC__StreamEncoderWriteStatus (*value)(const FLAC__StreamEncoder *encoder, const FLAC__byte buffer[], unsigned bytes, unsigned samples, unsigned current_frame, void *client_data)); |
FLAC__bool FLAC__stream_encoder_set_metadata_callback(const FLAC__StreamEncoder *encoder, void (*value)(const FLAC__StreamEncoder *encoder, const FLAC__StreamMetaData *metadata, void *client_data)); |
FLAC__bool FLAC__stream_encoder_set_client_data(const FLAC__StreamEncoder *encoder, void *value); |
/* |
* Various "get" methods |
*/ |
FLAC__StreamEncoderState FLAC__stream_encoder_get_state(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_streamable_subset(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_do_mid_side_stereo(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_loose_mid_side_stereo(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_channels(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_bits_per_sample(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_sample_rate(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_blocksize(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_max_lpc_order(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_qlp_coeff_precision(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_do_qlp_coeff_prec_search(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_do_escape_coding(const FLAC__StreamEncoder *encoder); |
FLAC__bool FLAC__stream_encoder_get_do_exhaustive_model_search(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_min_residual_partition_order(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_max_residual_partition_order(const FLAC__StreamEncoder *encoder); |
unsigned FLAC__stream_encoder_get_rice_parameter_search_dist(const FLAC__StreamEncoder *encoder); |
/* |
* Initialize the instance; should be called after construction and |
* 'set' calls but before any of the 'process' calls. Will set and |
* return the encoder state, which will be FLAC__STREAM_ENCODER_OK |
* if initialization succeeded. |
*/ |
FLAC__StreamEncoderState FLAC__stream_encoder_init(FLAC__StreamEncoder *encoder); |
/* |
* Flush the encoding buffer, release resources, and return the encoder |
* state to FLAC__STREAM_ENCODER_UNINITIALIZED. Note that this can |
* generate one or more write_callback()s before returning. |
*/ |
void FLAC__stream_encoder_finish(FLAC__StreamEncoder *encoder); |
/* |
* Methods for encoding the data |
*/ |
FLAC__bool FLAC__stream_encoder_process(FLAC__StreamEncoder *encoder, const FLAC__int32 *buf[], unsigned samples); |
FLAC__bool FLAC__stream_encoder_process_interleaved(FLAC__StreamEncoder *encoder, const FLAC__int32 buf[], unsigned samples); |
#endif |
/contrib/media/updf/include/FLAC/utility.h |
---|
0,0 → 1,27 |
/* libFLAC - Free Lossless Audio Codec library |
* Copyright (C) 2001 Josh Coalson |
* |
* This library is free software; you can redistribute it and/or |
* modify it under the terms of the GNU Library General Public |
* License as published by the Free Software Foundation; either |
* version 2 of the License, or (at your option) any later version. |
* |
* This library is distributed in the hope that it will be useful, |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
* Library General Public License for more details. |
* |
* You should have received a copy of the GNU Library General Public |
* License along with this library; if not, write to the |
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
* Boston, MA 02111-1307, USA. |
*/ |
#ifndef FLAC__UTILITY_H |
#define FLAC__UTILITY_H |
#include "format.h" |
FLAC__bool FLAC__utility_get_streaminfo(const char *filename, FLAC__StreamMetaData_StreamInfo *streaminfo); |
#endif |