From 52c44e9a5d59aa6d7a2fae212f24f700fd67b9cb Mon Sep 17 00:00:00 2001 From: Josh Coalson Date: Fri, 23 Feb 2001 23:11:34 +0000 Subject: [PATCH] shorten APPLICATION id to 32 bits --- doc/format.html | 2 +- include/FLAC/format.h | 12 +++++++----- src/libFLAC/format.c | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/doc/format.html b/doc/format.html index 7864da6..b9ee003 100644 --- a/doc/format.html +++ b/doc/format.html @@ -522,7 +522,7 @@ - <128> + <32> Registered application ID diff --git a/include/FLAC/format.h b/include/FLAC/format.h index e5fcafe..7f6ca99 100644 --- a/include/FLAC/format.h +++ b/include/FLAC/format.h @@ -345,17 +345,17 @@ typedef struct { /***************************************************************************** * - * 128: Registered application ID - * n: Application data - *-------- ----------------- - * 16+n/8 bytes total + * 32: Registered application ID + * n: Application data + *------- ----------------- + * 4+n/8 bytes total */ typedef struct { byte id[16]; byte *data; } FLAC__StreamMetaData_Application; -extern const unsigned FLAC__STREAM_METADATA_APPLICATION_ID_LEN; /* = 128 bits */ +extern const unsigned FLAC__STREAM_METADATA_APPLICATION_ID_LEN; /* = 32 bits */ /***************************************************************************** * @@ -371,6 +371,8 @@ typedef struct { unsigned length; /* in bytes */ union { FLAC__StreamMetaData_StreamInfo stream_info; + FLAC__StreamMetaData_Padding padding; + FLAC__StreamMetaData_Application application; } data; } FLAC__StreamMetaData; diff --git a/src/libFLAC/format.c b/src/libFLAC/format.c index a6a00a9..3524dde 100644 --- a/src/libFLAC/format.c +++ b/src/libFLAC/format.c @@ -36,7 +36,7 @@ const unsigned FLAC__STREAM_METADATA_STREAMINFO_TOTAL_SAMPLES_LEN = 36; /* bits const unsigned FLAC__STREAM_METADATA_STREAMINFO_MD5SUM_LEN = 128; /* bits */ const unsigned FLAC__STREAM_METADATA_STREAMINFO_LENGTH = 34; /* bytes */ -const unsigned FLAC__STREAM_METADATA_APPLICATION_ID_LEN = 128; /* bits */ +const unsigned FLAC__STREAM_METADATA_APPLICATION_ID_LEN = 32; /* bits */ const unsigned FLAC__STREAM_METADATA_IS_LAST_LEN = 1; /* bits */ const unsigned FLAC__STREAM_METADATA_TYPE_LEN = 7; /* bits */ -- 2.7.4