View | Details | Raw Unified | Return to bug 10874
Collapse All | Expand All

(-)mpd-0.12.1/configure.ac (-15 / +25 lines)
Lines 164-173 Link Here
164
	XIPH_PATH_AO([AC_DEFINE(HAVE_AO, 1, [Define to play with ao]) MPD_LIBS="$MPD_LIBS $AO_LIBS" MPD_CFLAGS="$MPD_CFLAGS $AO_CFLAGS"], enable_ao=no)
164
	XIPH_PATH_AO([AC_DEFINE(HAVE_AO, 1, [Define to play with ao]) MPD_LIBS="$MPD_LIBS $AO_LIBS" MPD_CFLAGS="$MPD_CFLAGS $AO_CFLAGS"], enable_ao=no)
165
fi
165
fi
166
166
167
if test x$enable_shout = xyes; then
168
	XIPH_PATH_SHOUT([AC_DEFINE(HAVE_SHOUT, 1, [Define to enable libshout support]) MPD_LIBS="$MPD_LIBS $SHOUT_LIBS" MPD_CFLAGS="$MPD_CFLAGS $SHOUT_CFLAGS"], enable_shout=no)
169
fi
170
171
if test x$enable_sun = xyes; then
167
if test x$enable_sun = xyes; then
172
	AC_CHECK_HEADER(sys/audioio.h,[enable_sun=yes;AC_DEFINE(HAVE_SUN,1,[Define to enable SUN audio support])],[AC_MSG_WARN(Sun audioio headers not found -- disabling SUN support);enable_sun=no])
168
	AC_CHECK_HEADER(sys/audioio.h,[enable_sun=yes;AC_DEFINE(HAVE_SUN,1,[Define to enable SUN audio support])],[AC_MSG_WARN(Sun audioio headers not found -- disabling SUN support);enable_sun=no])
173
fi
169
fi
Lines 549-557 Link Here
549
545
550
546
551
if test x$enable_oggflac = xyes; then
547
if test x$enable_oggflac = xyes; then
552
	oldmpdcflags="$MPD_CFLAGS"
548
	# libOggFLAC was merged into libFLAC in FLAC-1.1.3
553
	oldmpdlibs="$MPD_LIBS"
549
	# FLAC_API_SUPPORTS_OGG_FLAC first appears in FLAC-1.1.3
554
	AM_PATH_LIBOGGFLAC(MPD_LIBS="$MPD_LIBS $LIBOGGFLAC_LIBS" MPD_CFLAGS="$MPD_CFLAGS $LIBOGGFLAC_CFLAGS",enable_oggflac=no)
550
	oldcflags="$CFLAGS"
551
	oldlibs="$LIBS"
552
	oldldpath="$LD_LIBRARY_PATH"
553
	CFLAGS="$CFLAGS $LIBFLAC_CFLAGS"
554
	LIBS="$LIBS $LIBFLAC_LIBS -logg"
555
	LD_LIBRARY_PATH="$LIBFLAC_LIBDIR:$LD_LIBRARY_PATH"
556
	AC_TRY_RUN([
557
#include <FLAC/export.h>
558
int main () { return !FLAC_API_SUPPORTS_OGG_FLAC; }
559
],oggflac_in_flac=yes,oggflac_in_flac=no,oggflac_in_flac=yes)
560
	CFLAGS="$oldcflags"
561
	LIBS="$oldlibs"
562
	LD_LIBRARY_PATH="$oldldpath"
563
	if test x$oggflac_in_flac = xyes; then
564
		oldmpdcflags="$MPD_CFLAGS"
565
		oldmpdlibs="$MPD_LIBS"
566
		MPD_LIBS="$MPD_LIBS $LIBOGGFLAC_LIBS"
567
		MPD_CFLAGS="$MPD_CFLAGS $LIBOGGFLAC_CFLAGS"
568
	else
569
		oldmpdcflags="$MPD_CFLAGS"
570
		oldmpdlibs="$MPD_LIBS"
571
		AM_PATH_LIBOGGFLAC(MPD_LIBS="$MPD_LIBS $LIBOGGFLAC_LIBS" MPD_CFLAGS="$MPD_CFLAGS $LIBOGGFLAC_CFLAGS",enable_oggflac=no)
572
	fi
555
fi
573
fi
556
574
557
if test x$enable_oggflac = xyes; then
575
if test x$enable_oggflac = xyes; then
Lines 568-581 Link Here
568
	AC_DEFINE(HAVE_AUDIOFILE,1,[Define for audiofile support])
586
	AC_DEFINE(HAVE_AUDIOFILE,1,[Define for audiofile support])
569
fi
587
fi
570
588
571
if test x$enable_mod = xyes; then
572
	AM_PATH_LIBMIKMOD(3.1.7, MPD_CFLAGS="$MPD_CFLAGS $LIBMIKMOD_CFLAGS"
573
		MPD_LIBS="$MPD_LIBS $LIBMIKMOD_LIBS $LIBMIKMOD_LDADD", enable_mod=no)
574
	if test x$enable_mod = xyes; then
575
		AC_DEFINE(HAVE_MIKMOD, 1, [Define for mikmod support])
576
	fi
577
fi
578
579
AC_OUTPUT(src/mp4ff/Makefile doc/Makefile src/Makefile Makefile )
589
AC_OUTPUT(src/mp4ff/Makefile doc/Makefile src/Makefile Makefile )
580
590
581
echo ""
591
echo ""
(-)mpd-0.12.1/src/inputPlugins/_flac_common.h (+5 lines)
Lines 30-36 Link Here
30
#include "../inputStream.h"
30
#include "../inputStream.h"
31
#include "../outputBuffer.h"
31
#include "../outputBuffer.h"
32
#include "../decode.h"
32
#include "../decode.h"
33
#include <FLAC/export.h>
34
#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
33
#include <FLAC/seekable_stream_decoder.h>
35
#include <FLAC/seekable_stream_decoder.h>
36
#else
37
#include <FLAC/stream_decoder.h>
38
#endif
34
#include <FLAC/metadata.h>
39
#include <FLAC/metadata.h>
35
40
36
#define FLAC_CHUNK_SIZE 4080
41
#define FLAC_CHUNK_SIZE 4080
(-)mpd-0.12.1/src/inputPlugins/flac_plugin.c (-3 / +183 lines)
Lines 33-43 Link Here
33
#include <stdio.h>
33
#include <stdio.h>
34
#include <string.h>
34
#include <string.h>
35
#include <unistd.h>
35
#include <unistd.h>
36
#include <FLAC/export.h>
37
#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
38
#define LEGACY_FLAC
39
#else
40
#undef LEGACY_FLAC
41
#endif
42
#ifdef LEGACY_FLAC
36
#include <FLAC/seekable_stream_decoder.h>
43
#include <FLAC/seekable_stream_decoder.h>
44
#else
45
#include <FLAC/stream_decoder.h>
46
#endif
37
#include <FLAC/metadata.h>
47
#include <FLAC/metadata.h>
38
48
39
/* this code is based on flac123, from flac-tools */
49
/* this code is based on flac123, from flac-tools */
40
50
51
#ifdef LEGACY_FLAC
41
static void flacError(const FLAC__SeekableStreamDecoder *,
52
static void flacError(const FLAC__SeekableStreamDecoder *,
42
		      FLAC__StreamDecoderErrorStatus, void *);
53
		      FLAC__StreamDecoderErrorStatus, void *);
43
static void flacPrintErroredState(FLAC__SeekableStreamDecoderState state);
54
static void flacPrintErroredState(FLAC__SeekableStreamDecoderState state);
Lines 64-85 Link Here
64
							  *, FLAC__uint64 *,
75
							  *, FLAC__uint64 *,
65
							  void *);
76
							  void *);
66
static FLAC__bool flacEOF(const FLAC__SeekableStreamDecoder *, void *);
77
static FLAC__bool flacEOF(const FLAC__SeekableStreamDecoder *, void *);
78
#else
79
static void flacError(const FLAC__StreamDecoder *,
80
		      FLAC__StreamDecoderErrorStatus, void *);
81
static void flacPrintErroredState(FLAC__StreamDecoderState state);
82
static void flacMetadata(const FLAC__StreamDecoder *,
83
			 const FLAC__StreamMetadata *, void *);
84
static FLAC__StreamDecoderWriteStatus flacWrite(const
85
						FLAC__StreamDecoder *,
86
						const FLAC__Frame *,
87
						const FLAC__int32 * const buf[],
88
						void *);
89
static FLAC__StreamDecoderReadStatus flacRead(const
90
						      FLAC__StreamDecoder
91
						      *, FLAC__byte buf[],
92
						      size_t *, void *);
93
static FLAC__StreamDecoderSeekStatus flacSeek(const
94
						      FLAC__StreamDecoder
95
						      *, FLAC__uint64, void *);
96
static FLAC__StreamDecoderTellStatus flacTell(const
97
						      FLAC__StreamDecoder
98
						      *, FLAC__uint64 *,
99
						      void *);
100
static FLAC__StreamDecoderLengthStatus flacLength(const
101
							  FLAC__StreamDecoder
102
							  *, FLAC__uint64 *,
103
							  void *);
104
static FLAC__bool flacEOF(const FLAC__StreamDecoder *, void *);
105
#endif
67
106
68
static int flac_decode(OutputBuffer * cb, DecoderControl * dc,
107
static int flac_decode(OutputBuffer * cb, DecoderControl * dc,
69
		       InputStream * inStream)
108
		       InputStream * inStream)
70
{
109
{
110
#ifdef LEGACY_FLAC
71
	FLAC__SeekableStreamDecoder *flacDec = NULL;
111
	FLAC__SeekableStreamDecoder *flacDec = NULL;
112
#else
113
	FLAC__StreamDecoder *flacDec = NULL;
114
#endif
72
	FlacData data;
115
	FlacData data;
73
	int status = 1;
116
	int status = 1;
74
	int ret = 0;
117
	int ret = 0;
75
118
76
	init_FlacData(&data, cb, dc, inStream);
119
	init_FlacData(&data, cb, dc, inStream);
77
120
121
#ifdef LEGACY_FLAC
78
	if (!(flacDec = FLAC__seekable_stream_decoder_new())) {
122
	if (!(flacDec = FLAC__seekable_stream_decoder_new())) {
79
		ret = -1;
123
		ret = -1;
80
		goto fail;
124
		goto fail;
81
	}
125
	}
82
	/*status&=FLAC__file_decoder_set_md5_checking(flacDec,1); */
126
	/*status&=FLAC__seekable_decoder_set_md5_checking(flacDec,1); */
83
	status &= FLAC__seekable_stream_decoder_set_read_callback(flacDec,
127
	status &= FLAC__seekable_stream_decoder_set_read_callback(flacDec,
84
								  flacRead);
128
								  flacRead);
85
	status &= FLAC__seekable_stream_decoder_set_seek_callback(flacDec,
129
	status &= FLAC__seekable_stream_decoder_set_seek_callback(flacDec,
Lines 130-149 Link Here
130
		ret = -1;
174
		ret = -1;
131
		goto fail;
175
		goto fail;
132
	}
176
	}
177
#else
178
	if (!(flacDec = FLAC__stream_decoder_new())) {
179
		ret = -1;
180
		goto fail;
181
	}
182
	/*status&=FLAC__stream_decoder_set_md5_checking(flacDec,1); */
183
	status &= FLAC__stream_decoder_set_metadata_respond(flacDec, FLAC__METADATA_TYPE_VORBIS_COMMENT);
184
	if (!status) {
185
		ERROR("flac problem before init()\n");
186
		flacPrintErroredState(FLAC__stream_decoder_get_state(flacDec));
187
		ret = -1;
188
		goto fail;
189
	}
190
191
	if (FLAC__stream_decoder_init_stream(flacDec, flacRead, flacSeek, flacTell, flacLength, flacEOF, flacWrite, flacMetadata, flacError, (void *)&data) !=
192
	    FLAC__STREAM_DECODER_INIT_STATUS_OK) {
193
		ERROR("flac problem doing init()\n");
194
		flacPrintErroredState(FLAC__stream_decoder_get_state(flacDec));
195
		ret = -1;
196
		goto fail;
197
	}
198
199
	if (!FLAC__stream_decoder_process_until_end_of_metadata(flacDec)) {
200
		ERROR("flac problem reading metadata\n");
201
		flacPrintErroredState(FLAC__stream_decoder_get_state(flacDec));
202
		ret = -1;
203
		goto fail;
204
	}
205
#endif
133
206
134
	dc->state = DECODE_STATE_DECODE;
207
	dc->state = DECODE_STATE_DECODE;
135
208
136
	while (1) {
209
	while (1) {
210
#ifdef LEGACY_FLAC
137
		FLAC__seekable_stream_decoder_process_single(flacDec);
211
		FLAC__seekable_stream_decoder_process_single(flacDec);
138
		if (FLAC__seekable_stream_decoder_get_state(flacDec) !=
212
		if (FLAC__seekable_stream_decoder_get_state(flacDec) !=
139
		    FLAC__SEEKABLE_STREAM_DECODER_OK) {
213
		    FLAC__SEEKABLE_STREAM_DECODER_OK) {
140
			break;
214
			break;
141
		}
215
		}
216
#else
217
		FLAC__stream_decoder_process_single(flacDec);
218
		if (FLAC__stream_decoder_get_state(flacDec) >
219
		    FLAC__STREAM_DECODER_READ_FRAME) {
220
			break;
221
		}
222
#endif
142
		if (dc->seek) {
223
		if (dc->seek) {
143
			FLAC__uint64 sampleToSeek = dc->seekWhere *
224
			FLAC__uint64 sampleToSeek = dc->seekWhere *
144
			    dc->audioFormat.sampleRate + 0.5;
225
			    dc->audioFormat.sampleRate + 0.5;
226
#ifdef LEGACY_FLAC
145
			if (FLAC__seekable_stream_decoder_seek_absolute(flacDec,
227
			if (FLAC__seekable_stream_decoder_seek_absolute(flacDec,
146
									sampleToSeek))
228
									sampleToSeek))
229
#else
230
			if (FLAC__stream_decoder_seek_absolute(flacDec, sampleToSeek))
231
#endif
147
			{
232
			{
148
				clearOutputBuffer(cb);
233
				clearOutputBuffer(cb);
149
				data.time = ((float)sampleToSeek) /
234
				data.time = ((float)sampleToSeek) /
Lines 157-165 Link Here
157
	/* I don't think we need this bit here! -shank */
242
	/* I don't think we need this bit here! -shank */
158
	/*FLAC__file_decoder_process_until_end_of_file(flacDec); */
243
	/*FLAC__file_decoder_process_until_end_of_file(flacDec); */
159
	if (!dc->stop) {
244
	if (!dc->stop) {
245
#ifdef LEGACY_FLAC
160
		flacPrintErroredState(FLAC__seekable_stream_decoder_get_state
246
		flacPrintErroredState(FLAC__seekable_stream_decoder_get_state
161
				      (flacDec));
247
				      (flacDec));
162
		FLAC__seekable_stream_decoder_finish(flacDec);
248
		FLAC__seekable_stream_decoder_finish(flacDec);
249
#else
250
		flacPrintErroredState(FLAC__stream_decoder_get_state(flacDec));
251
		FLAC__stream_decoder_finish(flacDec);
252
#endif
163
	}
253
	}
164
	/* send last little bit */
254
	/* send last little bit */
165
	if (data.chunk_length > 0 && !dc->stop) {
255
	if (data.chunk_length > 0 && !dc->stop) {
Lines 180-198 Link Here
180
		freeReplayGainInfo(data.replayGainInfo);
270
		freeReplayGainInfo(data.replayGainInfo);
181
271
182
	if (flacDec)
272
	if (flacDec)
273
#ifdef LEGACY_FLAC
183
		FLAC__seekable_stream_decoder_delete(flacDec);
274
		FLAC__seekable_stream_decoder_delete(flacDec);
275
#else
276
		FLAC__stream_decoder_delete(flacDec);
277
#endif
184
278
185
	closeInputStream(inStream);
279
	closeInputStream(inStream);
186
280
187
	return ret;
281
	return ret;
188
}
282
}
189
283
284
#ifdef LEGACY_FLAC
190
static FLAC__SeekableStreamDecoderReadStatus flacRead(const
285
static FLAC__SeekableStreamDecoderReadStatus flacRead(const
191
						      FLAC__SeekableStreamDecoder
286
						      FLAC__SeekableStreamDecoder
192
						      * flacDec,
287
						      * flacDec,
193
						      FLAC__byte buf[],
288
						      FLAC__byte buf[],
194
						      unsigned *bytes,
289
						      unsigned *bytes,
195
						      void *fdata)
290
						      void *fdata)
291
#else
292
static FLAC__StreamDecoderReadStatus flacRead(const
293
						      FLAC__StreamDecoder* flacDec,
294
						      FLAC__byte buf[],
295
						      size_t *bytes,
296
						      void *fdata)
297
#endif
196
{
298
{
197
	FlacData *data = (FlacData *) fdata;
299
	FlacData *data = (FlacData *) fdata;
198
	size_t r;
300
	size_t r;
Lines 208-261 Link Here
208
	*bytes = r;
310
	*bytes = r;
209
311
210
	if (*bytes == 0 && !inputStreamAtEOF(data->inStream) && !data->dc->stop)
312
	if (*bytes == 0 && !inputStreamAtEOF(data->inStream) && !data->dc->stop)
313
#ifdef LEGACY_FLAC
211
		return FLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_ERROR;
314
		return FLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_ERROR;
315
#else
316
		return FLAC__STREAM_DECODER_READ_STATUS_ABORT;
317
#endif
212
318
319
#ifdef LEGACY_FLAC
213
	return FLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_OK;
320
	return FLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_OK;
321
#else
322
	return FLAC__STREAM_DECODER_READ_STATUS_CONTINUE;
323
#endif
214
}
324
}
215
325
326
#ifdef LEGACY_FLAC
216
static FLAC__SeekableStreamDecoderSeekStatus flacSeek(const
327
static FLAC__SeekableStreamDecoderSeekStatus flacSeek(const
217
						      FLAC__SeekableStreamDecoder
328
						      FLAC__SeekableStreamDecoder
218
						      * flacDec,
329
						      * flacDec,
219
						      FLAC__uint64 offset,
330
						      FLAC__uint64 offset,
220
						      void *fdata)
331
						      void *fdata)
332
#else
333
static FLAC__StreamDecoderSeekStatus flacSeek(const
334
						      FLAC__StreamDecoder* flacDec,
335
						      FLAC__uint64 offset,
336
						      void *fdata)
337
#endif
221
{
338
{
222
	FlacData *data = (FlacData *) fdata;
339
	FlacData *data = (FlacData *) fdata;
223
340
224
	if (seekInputStream(data->inStream, offset, SEEK_SET) < 0) {
341
	if (seekInputStream(data->inStream, offset, SEEK_SET) < 0) {
342
#ifdef LEGACY_FLAC
225
		return FLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_ERROR;
343
		return FLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_ERROR;
344
#else
345
		return FLAC__STREAM_DECODER_SEEK_STATUS_ERROR;
346
#endif
226
	}
347
	}
227
348
349
#ifdef LEGACY_FLAC
228
	return FLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_OK;
350
	return FLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_OK;
351
#else
352
	return FLAC__STREAM_DECODER_SEEK_STATUS_OK;
353
#endif
229
}
354
}
230
355
356
#ifdef LEGACY_FLAC
231
static FLAC__SeekableStreamDecoderTellStatus flacTell(const
357
static FLAC__SeekableStreamDecoderTellStatus flacTell(const
232
						      FLAC__SeekableStreamDecoder
358
						      FLAC__SeekableStreamDecoder* flacDec,
233
						      * flacDec,
359
						      FLAC__uint64 * offset,
360
						      void *fdata)
361
#else
362
static FLAC__StreamDecoderTellStatus flacTell(const
363
						      FLAC__StreamDecoder* flacDec,
234
						      FLAC__uint64 * offset,
364
						      FLAC__uint64 * offset,
235
						      void *fdata)
365
						      void *fdata)
366
#endif
236
{
367
{
237
	FlacData *data = (FlacData *) fdata;
368
	FlacData *data = (FlacData *) fdata;
238
369
239
	*offset = (long)(data->inStream->offset);
370
	*offset = (long)(data->inStream->offset);
240
371
372
#ifdef LEGACY_FLAC
241
	return FLAC__SEEKABLE_STREAM_DECODER_TELL_STATUS_OK;
373
	return FLAC__SEEKABLE_STREAM_DECODER_TELL_STATUS_OK;
374
#else
375
	return FLAC__STREAM_DECODER_TELL_STATUS_OK;
376
#endif
242
}
377
}
243
378
379
#ifdef LEGACY_FLAC
244
static FLAC__SeekableStreamDecoderLengthStatus flacLength(const
380
static FLAC__SeekableStreamDecoderLengthStatus flacLength(const
245
							  FLAC__SeekableStreamDecoder
381
							  FLAC__SeekableStreamDecoder
246
							  * flacDec,
382
							  * flacDec,
247
							  FLAC__uint64 * length,
383
							  FLAC__uint64 * length,
248
							  void *fdata)
384
							  void *fdata)
385
#else
386
static FLAC__StreamDecoderLengthStatus flacLength(const
387
							  FLAC__StreamDecoder* flacDec,
388
							  FLAC__uint64 * length,
389
							  void *fdata)
390
#endif
249
{
391
{
250
	FlacData *data = (FlacData *) fdata;
392
	FlacData *data = (FlacData *) fdata;
251
393
252
	*length = (size_t) (data->inStream->size);
394
	*length = (size_t) (data->inStream->size);
253
395
396
#ifdef LEGACY_FLAC
254
	return FLAC__SEEKABLE_STREAM_DECODER_LENGTH_STATUS_OK;
397
	return FLAC__SEEKABLE_STREAM_DECODER_LENGTH_STATUS_OK;
398
#else
399
	return FLAC__STREAM_DECODER_LENGTH_STATUS_OK;
400
#endif
255
}
401
}
256
402
403
#ifdef LEGACY_FLAC
257
static FLAC__bool flacEOF(const FLAC__SeekableStreamDecoder * flacDec,
404
static FLAC__bool flacEOF(const FLAC__SeekableStreamDecoder * flacDec,
258
			  void *fdata)
405
			  void *fdata)
406
#else
407
static FLAC__bool flacEOF(const FLAC__StreamDecoder * flacDec, void *fdata)
408
#endif
259
{
409
{
260
	FlacData *data = (FlacData *) fdata;
410
	FlacData *data = (FlacData *) fdata;
261
411
Lines 264-277 Link Here
264
	return false;
414
	return false;
265
}
415
}
266
416
417
#ifdef LEGACY_FLAC
267
static void flacError(const FLAC__SeekableStreamDecoder * dec,
418
static void flacError(const FLAC__SeekableStreamDecoder * dec,
268
		      FLAC__StreamDecoderErrorStatus status, void *fdata)
419
		      FLAC__StreamDecoderErrorStatus status, void *fdata)
420
#else
421
static void flacError(const FLAC__StreamDecoder * dec,
422
		      FLAC__StreamDecoderErrorStatus status, void *fdata)
423
#endif
269
{
424
{
270
	flac_error_common_cb("flac", status, (FlacData *) fdata);
425
	flac_error_common_cb("flac", status, (FlacData *) fdata);
271
}
426
}
272
427
428
#ifdef LEGACY_FLAC
273
static void flacPrintErroredState(FLAC__SeekableStreamDecoderState state)
429
static void flacPrintErroredState(FLAC__SeekableStreamDecoderState state)
430
#else
431
static void flacPrintErroredState(FLAC__StreamDecoderState state)
432
#endif
274
{
433
{
434
#ifdef LEGACY_FLAC
275
	switch (state) {
435
	switch (state) {
276
	case FLAC__SEEKABLE_STREAM_DECODER_MEMORY_ALLOCATION_ERROR:
436
	case FLAC__SEEKABLE_STREAM_DECODER_MEMORY_ALLOCATION_ERROR:
277
		ERROR("flac allocation error\n");
437
		ERROR("flac allocation error\n");
Lines 299-317 Link Here
299
	case FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM:
459
	case FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM:
300
		break;
460
		break;
301
	}
461
	}
462
#else
463
	ERROR("%s\n", FLAC__StreamDecoderStateString[state]);
464
#endif
302
}
465
}
303
466
467
#ifdef LEGACY_FLAC
304
static void flacMetadata(const FLAC__SeekableStreamDecoder * dec,
468
static void flacMetadata(const FLAC__SeekableStreamDecoder * dec,
305
			 const FLAC__StreamMetadata * block, void *vdata)
469
			 const FLAC__StreamMetadata * block, void *vdata)
470
#else
471
static void flacMetadata(const FLAC__StreamDecoder * dec,
472
			 const FLAC__StreamMetadata * block, void *vdata)
473
#endif
306
{
474
{
307
	flac_metadata_common_cb(block, (FlacData *) vdata);
475
	flac_metadata_common_cb(block, (FlacData *) vdata);
308
}
476
}
309
477
478
#ifdef LEGACY_FLAC
310
static FLAC__StreamDecoderWriteStatus flacWrite(const
479
static FLAC__StreamDecoderWriteStatus flacWrite(const
311
						FLAC__SeekableStreamDecoder *
480
						FLAC__SeekableStreamDecoder *
312
						dec, const FLAC__Frame * frame,
481
						dec, const FLAC__Frame * frame,
313
						const FLAC__int32 * const buf[],
482
						const FLAC__int32 * const buf[],
314
						void *vdata)
483
						void *vdata)
484
#else
485
static FLAC__StreamDecoderWriteStatus flacWrite(const
486
						FLAC__StreamDecoder *
487
						dec, const FLAC__Frame * frame,
488
						const FLAC__int32 * const buf[],
489
						void *vdata)
490
#endif
315
{
491
{
316
	FlacData *data = (FlacData *) vdata;
492
	FlacData *data = (FlacData *) vdata;
317
	FLAC__uint32 samples = frame->header.blocksize;
493
	FLAC__uint32 samples = frame->header.blocksize;
Lines 325-331 Link Here
325
	timeChange = ((float)samples) / frame->header.sample_rate;
501
	timeChange = ((float)samples) / frame->header.sample_rate;
326
	data->time += timeChange;
502
	data->time += timeChange;
327
503
504
#ifdef LEGACY_FLAC
328
	FLAC__seekable_stream_decoder_get_decode_position(dec, &newPosition);
505
	FLAC__seekable_stream_decoder_get_decode_position(dec, &newPosition);
506
#else
507
	FLAC__stream_decoder_get_decode_position(dec, &newPosition);
508
#endif
329
	if (data->position) {
509
	if (data->position) {
330
		data->bitRate =
510
		data->bitRate =
331
		    ((newPosition - data->position) * 8.0 / timeChange)
511
		    ((newPosition - data->position) * 8.0 / timeChange)
(-)mpd-0.12.1/src/inputPlugins/oggflac_plugin.c (-2 / +179 lines)
Lines 37-62 Link Here
37
#include <stdio.h>
37
#include <stdio.h>
38
#include <string.h>
38
#include <string.h>
39
#include <unistd.h>
39
#include <unistd.h>
40
#include <FLAC/export.h>
41
#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
42
#define LEGACY_FLAC
43
#else
44
#undef LEGACY_FLAC
45
#endif
46
#ifdef LEGACY_FLAC
40
#include <OggFLAC/seekable_stream_decoder.h>
47
#include <OggFLAC/seekable_stream_decoder.h>
48
#else
49
#include <FLAC/stream_decoder.h>
50
#endif
41
#include <FLAC/metadata.h>
51
#include <FLAC/metadata.h>
42
52
53
#ifdef LEGACY_FLAC
43
static void oggflac_cleanup(InputStream * inStream,
54
static void oggflac_cleanup(InputStream * inStream,
44
			    FlacData * data,
55
			    FlacData * data,
45
			    OggFLAC__SeekableStreamDecoder * decoder)
56
			    OggFLAC__SeekableStreamDecoder * decoder)
57
#else
58
static void oggflac_cleanup(InputStream * inStream,
59
			    FlacData * data,
60
			    FLAC__StreamDecoder * decoder)
61
#endif
46
{
62
{
47
	if (data->replayGainInfo)
63
	if (data->replayGainInfo)
48
		freeReplayGainInfo(data->replayGainInfo);
64
		freeReplayGainInfo(data->replayGainInfo);
49
	if (decoder)
65
	if (decoder)
66
#ifdef LEGACY_FLAC
50
		OggFLAC__seekable_stream_decoder_delete(decoder);
67
		OggFLAC__seekable_stream_decoder_delete(decoder);
68
#else
69
		FLAC__stream_decoder_delete(decoder);
70
#endif
51
	closeInputStream(inStream);
71
	closeInputStream(inStream);
52
}
72
}
53
73
74
#ifdef LEGACY_FLAC
54
static OggFLAC__SeekableStreamDecoderReadStatus of_read_cb(const
75
static OggFLAC__SeekableStreamDecoderReadStatus of_read_cb(const
55
							   OggFLAC__SeekableStreamDecoder
76
							   OggFLAC__SeekableStreamDecoder
56
							   * decoder,
77
							   * decoder,
57
							   FLAC__byte buf[],
78
							   FLAC__byte buf[],
58
							   unsigned *bytes,
79
							   unsigned *bytes,
59
							   void *fdata)
80
							   void *fdata)
81
#else
82
static FLAC__StreamDecoderReadStatus of_read_cb(const
83
							   FLAC__StreamDecoder* decoder,
84
							   FLAC__byte buf[],
85
							   size_t *bytes,
86
							   void *fdata)
87
#endif
60
{
88
{
61
	FlacData *data = (FlacData *) fdata;
89
	FlacData *data = (FlacData *) fdata;
62
	size_t r;
90
	size_t r;
Lines 72-126 Link Here
72
	*bytes = r;
100
	*bytes = r;
73
101
74
	if (r == 0 && !inputStreamAtEOF(data->inStream) && !data->dc->stop)
102
	if (r == 0 && !inputStreamAtEOF(data->inStream) && !data->dc->stop)
103
#ifdef LEGACY_FLAC
75
		return OggFLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_ERROR;
104
		return OggFLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_ERROR;
105
#else
106
		return FLAC__STREAM_DECODER_READ_STATUS_ABORT;
107
#endif
76
108
109
#ifdef LEGACY_FLAC
77
	return OggFLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_OK;
110
	return OggFLAC__SEEKABLE_STREAM_DECODER_READ_STATUS_OK;
111
#else
112
	return FLAC__STREAM_DECODER_READ_STATUS_CONTINUE;
113
#endif
78
}
114
}
79
115
116
#ifdef LEGACY_FLAC
80
static OggFLAC__SeekableStreamDecoderSeekStatus of_seek_cb(const
117
static OggFLAC__SeekableStreamDecoderSeekStatus of_seek_cb(const
81
							   OggFLAC__SeekableStreamDecoder
118
							   OggFLAC__SeekableStreamDecoder
82
							   * decoder,
119
							   * decoder,
83
							   FLAC__uint64 offset,
120
							   FLAC__uint64 offset,
84
							   void *fdata)
121
							   void *fdata)
122
#else
123
static FLAC__StreamDecoderSeekStatus of_seek_cb(const
124
							   FLAC__StreamDecoder* decoder,
125
							   FLAC__uint64 offset,
126
							   void *fdata)
127
#endif
85
{
128
{
86
	FlacData *data = (FlacData *) fdata;
129
	FlacData *data = (FlacData *) fdata;
87
130
88
	if (seekInputStream(data->inStream, offset, SEEK_SET) < 0) {
131
	if (seekInputStream(data->inStream, offset, SEEK_SET) < 0) {
132
#ifdef LEGACY_FLAC
89
		return OggFLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_ERROR;
133
		return OggFLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_ERROR;
134
#else
135
		return FLAC__STREAM_DECODER_SEEK_STATUS_ERROR;
136
#endif
90
	}
137
	}
91
138
139
#ifdef LEGACY_FLAC
92
	return OggFLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_OK;
140
	return OggFLAC__SEEKABLE_STREAM_DECODER_SEEK_STATUS_OK;
141
#else
142
	return FLAC__STREAM_DECODER_SEEK_STATUS_OK;
143
#endif
93
}
144
}
94
145
146
#ifdef LEGACY_FLAC
95
static OggFLAC__SeekableStreamDecoderTellStatus of_tell_cb(const
147
static OggFLAC__SeekableStreamDecoderTellStatus of_tell_cb(const
96
							   OggFLAC__SeekableStreamDecoder
148
							   OggFLAC__SeekableStreamDecoder
97
							   * decoder,
149
							   * decoder,
98
							   FLAC__uint64 *
150
							   FLAC__uint64 *
99
							   offset, void *fdata)
151
							   offset, void *fdata)
152
#else
153
static FLAC__StreamDecoderTellStatus of_tell_cb(const
154
							   FLAC__StreamDecoder* decoder,
155
							   FLAC__uint64 *
156
							   offset, void *fdata)
157
#endif
100
{
158
{
101
	FlacData *data = (FlacData *) fdata;
159
	FlacData *data = (FlacData *) fdata;
102
160
103
	*offset = (long)(data->inStream->offset);
161
	*offset = (long)(data->inStream->offset);
104
162
163
#ifdef LEGACY_FLAC
105
	return OggFLAC__SEEKABLE_STREAM_DECODER_TELL_STATUS_OK;
164
	return OggFLAC__SEEKABLE_STREAM_DECODER_TELL_STATUS_OK;
165
#else
166
	return FLAC__STREAM_DECODER_TELL_STATUS_OK;
167
#endif
106
}
168
}
107
169
170
#ifdef LEGACY_FLAC
108
static OggFLAC__SeekableStreamDecoderLengthStatus of_length_cb(const
171
static OggFLAC__SeekableStreamDecoderLengthStatus of_length_cb(const
109
							       OggFLAC__SeekableStreamDecoder
172
							       OggFLAC__SeekableStreamDecoder
110
							       * decoder,
173
							       * decoder,
111
							       FLAC__uint64 *
174
							       FLAC__uint64 *
112
							       length,
175
							       length,
113
							       void *fdata)
176
							       void *fdata)
177
#else
178
static FLAC__StreamDecoderLengthStatus of_length_cb(const
179
							       FLAC__StreamDecoder* decoder,
180
							       FLAC__uint64 *
181
							       length,
182
							       void *fdata)
183
#endif
114
{
184
{
115
	FlacData *data = (FlacData *) fdata;
185
	FlacData *data = (FlacData *) fdata;
116
186
117
	*length = (size_t) (data->inStream->size);
187
	*length = (size_t) (data->inStream->size);
118
188
189
#ifdef LEGACY_FLAC
119
	return OggFLAC__SEEKABLE_STREAM_DECODER_LENGTH_STATUS_OK;
190
	return OggFLAC__SEEKABLE_STREAM_DECODER_LENGTH_STATUS_OK;
191
#else
192
	return FLAC__STREAM_DECODER_LENGTH_STATUS_OK;
193
#endif
120
}
194
}
121
195
196
#ifdef LEGACY_FLAC
122
static FLAC__bool of_EOF_cb(const OggFLAC__SeekableStreamDecoder * decoder,
197
static FLAC__bool of_EOF_cb(const OggFLAC__SeekableStreamDecoder * decoder,
123
			    void *fdata)
198
			    void *fdata)
199
#else
200
static FLAC__bool of_EOF_cb(const FLAC__StreamDecoder * decoder, void *fdata)
201
#endif
124
{
202
{
125
	FlacData *data = (FlacData *) fdata;
203
	FlacData *data = (FlacData *) fdata;
126
204
Lines 129-142 Link Here
129
	return false;
207
	return false;
130
}
208
}
131
209
210
#ifdef LEGACY_FLAC
132
static void of_error_cb(const OggFLAC__SeekableStreamDecoder * decoder,
211
static void of_error_cb(const OggFLAC__SeekableStreamDecoder * decoder,
133
			FLAC__StreamDecoderErrorStatus status, void *fdata)
212
			FLAC__StreamDecoderErrorStatus status, void *fdata)
213
#else
214
static void of_error_cb(const FLAC__StreamDecoder * decoder,
215
			FLAC__StreamDecoderErrorStatus status, void *fdata)
216
#endif
134
{
217
{
135
	flac_error_common_cb("oggflac", status, (FlacData *) fdata);
218
	flac_error_common_cb("oggflac", status, (FlacData *) fdata);
136
}
219
}
137
220
221
#ifdef LEGACY_FLAC
138
static void oggflacPrintErroredState(OggFLAC__SeekableStreamDecoderState state)
222
static void oggflacPrintErroredState(OggFLAC__SeekableStreamDecoderState state)
223
#else
224
static void oggflacPrintErroredState(FLAC__StreamDecoderState state)
225
#endif
139
{
226
{
227
#ifdef LEGACY_FLAC
140
	switch (state) {
228
	switch (state) {
141
	case OggFLAC__SEEKABLE_STREAM_DECODER_MEMORY_ALLOCATION_ERROR:
229
	case OggFLAC__SEEKABLE_STREAM_DECODER_MEMORY_ALLOCATION_ERROR:
142
		ERROR("oggflac allocation error\n");
230
		ERROR("oggflac allocation error\n");
Lines 164-177 Link Here
164
	case OggFLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM:
252
	case OggFLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM:
165
		break;
253
		break;
166
	}
254
	}
255
#else
256
	ERROR("%s\n", FLAC__StreamDecoderStateString[state]);
257
#endif
167
}
258
}
168
259
260
#ifdef LEGACY_FLAC
169
static FLAC__StreamDecoderWriteStatus oggflacWrite(const
261
static FLAC__StreamDecoderWriteStatus oggflacWrite(const
170
						   OggFLAC__SeekableStreamDecoder
262
						   OggFLAC__SeekableStreamDecoder
171
						   * decoder,
263
						   * decoder,
172
						   const FLAC__Frame * frame,
264
						   const FLAC__Frame * frame,
173
						   const FLAC__int32 *
265
						   const FLAC__int32 *
174
						   const buf[], void *vdata)
266
						   const buf[], void *vdata)
267
#else
268
static FLAC__StreamDecoderWriteStatus oggflacWrite(const
269
						   FLAC__StreamDecoder * decoder,
270
						   const FLAC__Frame * frame,
271
						   const FLAC__int32 *
272
						   const buf[], void *vdata)
273
#endif
175
{
274
{
176
	FlacData *data = (FlacData *) vdata;
275
	FlacData *data = (FlacData *) vdata;
177
	FLAC__uint32 samples = frame->header.blocksize;
276
	FLAC__uint32 samples = frame->header.blocksize;
Lines 222-229 Link Here
222
}
321
}
223
322
224
/* used by TagDup */
323
/* used by TagDup */
324
#ifdef LEGACY_FLAC
225
static void of_metadata_dup_cb(const OggFLAC__SeekableStreamDecoder * decoder,
325
static void of_metadata_dup_cb(const OggFLAC__SeekableStreamDecoder * decoder,
226
			       const FLAC__StreamMetadata * block, void *vdata)
326
			       const FLAC__StreamMetadata * block, void *vdata)
327
#else
328
static void of_metadata_dup_cb(const FLAC__StreamDecoder * decoder,
329
			       const FLAC__StreamMetadata * block, void *vdata)
330
#endif
227
{
331
{
228
	FlacData *data = (FlacData *) vdata;
332
	FlacData *data = (FlacData *) vdata;
229
333
Lines 243-262 Link Here
243
}
347
}
244
348
245
/* used by decode */
349
/* used by decode */
350
#ifdef LEGACY_FLAC
246
static void of_metadata_decode_cb(const OggFLAC__SeekableStreamDecoder * dec,
351
static void of_metadata_decode_cb(const OggFLAC__SeekableStreamDecoder * dec,
247
				  const FLAC__StreamMetadata * block,
352
				  const FLAC__StreamMetadata * block,
248
				  void *vdata)
353
				  void *vdata)
354
#else
355
static void of_metadata_decode_cb(const FLAC__StreamDecoder * dec,
356
				  const FLAC__StreamMetadata * block,
357
				  void *vdata)
358
#endif
249
{
359
{
250
	flac_metadata_common_cb(block, (FlacData *) vdata);
360
	flac_metadata_common_cb(block, (FlacData *) vdata);
251
}
361
}
252
362
363
#ifdef LEGACY_FLAC
253
static OggFLAC__SeekableStreamDecoder
364
static OggFLAC__SeekableStreamDecoder
254
    * full_decoder_init_and_read_metadata(FlacData * data,
365
    * full_decoder_init_and_read_metadata(FlacData * data,
255
					  unsigned int metadata_only)
366
					  unsigned int metadata_only)
367
#else
368
static FLAC__StreamDecoder
369
    * full_decoder_init_and_read_metadata(FlacData * data,
370
					  unsigned int metadata_only)
371
#endif
256
{
372
{
373
#ifdef LEGACY_FLAC
257
	OggFLAC__SeekableStreamDecoder *decoder = NULL;
374
	OggFLAC__SeekableStreamDecoder *decoder = NULL;
375
#else
376
	FLAC__StreamDecoder *decoder = NULL;
377
#endif
258
	unsigned int s = 1;
378
	unsigned int s = 1;
259
379
380
#ifdef LEGACY_FLAC
260
	if (!(decoder = OggFLAC__seekable_stream_decoder_new()))
381
	if (!(decoder = OggFLAC__seekable_stream_decoder_new()))
261
		return NULL;
382
		return NULL;
262
383
Lines 303-315 Link Here
303
		ERROR("oggflac problem reading metadata\n");
424
		ERROR("oggflac problem reading metadata\n");
304
		goto fail;
425
		goto fail;
305
	}
426
	}
427
#else
428
	if (!(decoder = FLAC__stream_decoder_new()))
429
		return NULL;
430
431
	if (metadata_only) {
432
		s &= FLAC__stream_decoder_set_metadata_respond
433
		    (decoder, FLAC__METADATA_TYPE_STREAMINFO);
434
	}
435
436
	s &= FLAC__stream_decoder_set_metadata_respond(decoder, FLAC__METADATA_TYPE_VORBIS_COMMENT);
437
438
	if (!s) {
439
		ERROR("oggflac problem before init()\n");
440
		goto fail;
441
	}
442
	if (FLAC__stream_decoder_init_ogg_stream(decoder, of_read_cb, of_seek_cb, of_tell_cb, of_length_cb, of_EOF_cb, oggflacWrite, metadata_only? of_metadata_dup_cb : of_metadata_decode_cb, of_error_cb, (void *)data) !=
443
	    FLAC__STREAM_DECODER_INIT_STATUS_OK) {
444
		ERROR("oggflac problem doing init()\n");
445
		goto fail;
446
	}
447
	if (!FLAC__stream_decoder_process_until_end_of_metadata(decoder)) {
448
		ERROR("oggflac problem reading metadata\n");
449
		goto fail;
450
	}
451
#endif
306
452
307
	return decoder;
453
	return decoder;
308
454
309
fail:
455
fail:
456
#ifdef LEGACY_FLAC
310
	oggflacPrintErroredState(OggFLAC__seekable_stream_decoder_get_state
457
	oggflacPrintErroredState(OggFLAC__seekable_stream_decoder_get_state
311
				 (decoder));
458
				 (decoder));
312
	OggFLAC__seekable_stream_decoder_delete(decoder);
459
	OggFLAC__seekable_stream_decoder_delete(decoder);
460
#else
461
	oggflacPrintErroredState(FLAC__stream_decoder_get_state(decoder));
462
	FLAC__stream_decoder_delete(decoder);
463
#endif
313
	return NULL;
464
	return NULL;
314
}
465
}
315
466
Lines 317-323 Link Here
317
static MpdTag *oggflac_TagDup(char *file)
468
static MpdTag *oggflac_TagDup(char *file)
318
{
469
{
319
	InputStream inStream;
470
	InputStream inStream;
471
#ifdef LEGACY_FLAC
320
	OggFLAC__SeekableStreamDecoder *decoder;
472
	OggFLAC__SeekableStreamDecoder *decoder;
473
#else
474
	FLAC__StreamDecoder *decoder;
475
#endif
321
	FlacData data;
476
	FlacData data;
322
477
323
	if (openInputStream(&inStream, file) < 0)
478
	if (openInputStream(&inStream, file) < 0)
Lines 346-352 Link Here
346
static int oggflac_decode(OutputBuffer * cb, DecoderControl * dc,
501
static int oggflac_decode(OutputBuffer * cb, DecoderControl * dc,
347
			  InputStream * inStream)
502
			  InputStream * inStream)
348
{
503
{
504
#ifdef LEGACY_FLAC
349
	OggFLAC__SeekableStreamDecoder *decoder = NULL;
505
	OggFLAC__SeekableStreamDecoder *decoder = NULL;
506
#else
507
	FLAC__StreamDecoder *decoder = NULL;
508
#endif
350
	FlacData data;
509
	FlacData data;
351
	int ret = 0;
510
	int ret = 0;
352
511
Lines 360-375 Link Here
360
	dc->state = DECODE_STATE_DECODE;
519
	dc->state = DECODE_STATE_DECODE;
361
520
362
	while (1) {
521
	while (1) {
522
#ifdef LEGACY_FLAC
363
		OggFLAC__seekable_stream_decoder_process_single(decoder);
523
		OggFLAC__seekable_stream_decoder_process_single(decoder);
364
		if (OggFLAC__seekable_stream_decoder_get_state(decoder) !=
524
		if (OggFLAC__seekable_stream_decoder_get_state(decoder) !=
365
		    OggFLAC__SEEKABLE_STREAM_DECODER_OK) {
525
		    OggFLAC__SEEKABLE_STREAM_DECODER_OK) {
366
			break;
526
			break;
367
		}
527
		}
528
#else
529
		FLAC__stream_decoder_process_single(decoder);
530
		if (FLAC__stream_decoder_get_state(decoder) >
531
		    FLAC__STREAM_DECODER_READ_FRAME) {
532
			break;
533
		}
534
#endif
368
		if (dc->seek) {
535
		if (dc->seek) {
369
			FLAC__uint64 sampleToSeek = dc->seekWhere *
536
			FLAC__uint64 sampleToSeek = dc->seekWhere *
370
			    dc->audioFormat.sampleRate + 0.5;
537
			    dc->audioFormat.sampleRate + 0.5;
538
#ifdef LEGACY_FLAC
371
			if (OggFLAC__seekable_stream_decoder_seek_absolute
539
			if (OggFLAC__seekable_stream_decoder_seek_absolute
372
			    (decoder, sampleToSeek)) {
540
			    (decoder, sampleToSeek))
541
#else
542
			if (FLAC__stream_decoder_seek_absolute(decoder, sampleToSeek))
543
#endif
544
			{
373
				clearOutputBuffer(cb);
545
				clearOutputBuffer(cb);
374
				data.time = ((float)sampleToSeek) /
546
				data.time = ((float)sampleToSeek) /
375
				    dc->audioFormat.sampleRate;
547
				    dc->audioFormat.sampleRate;
Lines 381-389 Link Here
381
	}
553
	}
382
554
383
	if (!dc->stop) {
555
	if (!dc->stop) {
556
#ifdef LEGACY_FLAC
384
		oggflacPrintErroredState
557
		oggflacPrintErroredState
385
		    (OggFLAC__seekable_stream_decoder_get_state(decoder));
558
		    (OggFLAC__seekable_stream_decoder_get_state(decoder));
386
		OggFLAC__seekable_stream_decoder_finish(decoder);
559
		OggFLAC__seekable_stream_decoder_finish(decoder);
560
#else
561
		oggflacPrintErroredState(FLAC__stream_decoder_get_state(decoder));
562
		FLAC__stream_decoder_finish(decoder);
563
#endif
387
	}
564
	}
388
	/* send last little bit */
565
	/* send last little bit */
389
	if (data.chunk_length > 0 && !dc->stop) {
566
	if (data.chunk_length > 0 && !dc->stop) {
Lines 416-422 Link Here
416
	oggflac_mime_types
593
	oggflac_mime_types
417
};
594
};
418
595
419
#else /* !HAVE_FLAC */
596
#else /* !HAVE_OGGFLAC */
420
597
421
InputPlugin oggflacPlugin = {
598
InputPlugin oggflacPlugin = {
422
	NULL,
599
	NULL,

Return to bug 10874