comparison decoders/flac.c @ 306:c97be6e1bd27

Added framework for Sound_Seek() support.
author Ryan C. Gordon <icculus@icculus.org>
date Sun, 21 Apr 2002 18:39:47 +0000
parents d3dc34315ac7
children 498240aa76f1
comparison
equal deleted inserted replaced
305:c345a40a8a99 306:c97be6e1bd27
58 static void FLAC_quit(void); 58 static void FLAC_quit(void);
59 static int FLAC_open(Sound_Sample *sample, const char *ext); 59 static int FLAC_open(Sound_Sample *sample, const char *ext);
60 static void FLAC_close(Sound_Sample *sample); 60 static void FLAC_close(Sound_Sample *sample);
61 static Uint32 FLAC_read(Sound_Sample *sample); 61 static Uint32 FLAC_read(Sound_Sample *sample);
62 static int FLAC_rewind(Sound_Sample *sample); 62 static int FLAC_rewind(Sound_Sample *sample);
63 static int FLAC_seek(Sound_Sample *sample, Uint32 ms);
63 64
64 static const char *extensions_flac[] = { "FLAC", "FLA", NULL }; 65 static const char *extensions_flac[] = { "FLAC", "FLA", NULL };
65 66
66 const Sound_DecoderFunctions __Sound_DecoderFunctions_FLAC = 67 const Sound_DecoderFunctions __Sound_DecoderFunctions_FLAC =
67 { 68 {
75 FLAC_init, /* init() method */ 76 FLAC_init, /* init() method */
76 FLAC_quit, /* quit() method */ 77 FLAC_quit, /* quit() method */
77 FLAC_open, /* open() method */ 78 FLAC_open, /* open() method */
78 FLAC_close, /* close() method */ 79 FLAC_close, /* close() method */
79 FLAC_read, /* read() method */ 80 FLAC_read, /* read() method */
80 FLAC_rewind /* rewind() method */ 81 FLAC_rewind, /* rewind() method */
82 FLAC_seek /* seek() method */
81 }; 83 };
82 84
83 /* This is what we store in our internal->decoder_private field. */ 85 /* This is what we store in our internal->decoder_private field. */
84 typedef struct 86 typedef struct
85 { 87 {
388 "FLAC: could not reset decoder", 0); 390 "FLAC: could not reset decoder", 0);
389 FLAC__stream_decoder_process_metadata(f->decoder); 391 FLAC__stream_decoder_process_metadata(f->decoder);
390 return(1); 392 return(1);
391 } /* FLAC_rewind */ 393 } /* FLAC_rewind */
392 394
395
396 static int FLAC_seek(Sound_Sample *sample, Uint32 ms)
397 {
398 BAIL_MACRO("!!! FIXME: Not implemented", 0);
399 } /* FLAC_seek */
400
401
393 #endif /* SOUND_SUPPORTS_FLAC */ 402 #endif /* SOUND_SUPPORTS_FLAC */
394 403
395 404
396 /* end of flac.c ... */ 405 /* end of flac.c ... */