comparison src/flac113/plugin.c @ 372:a157306caf03 trunk

[svn] - finalize the plugin-side of the extension-assist ABI
author nenolod
date Tue, 12 Dec 2006 19:43:23 -0800
parents c812e846b84e
children 3e41d8efe752
comparison
equal deleted inserted replaced
371:96cbec520f57 372:a157306caf03
95 static FLAC__StreamDecoderReadStatus http_read_callback_(const FLAC__StreamDecoder *decoder, FLAC__byte buffer[], size_t *bytes, void *client_data); 95 static FLAC__StreamDecoderReadStatus http_read_callback_(const FLAC__StreamDecoder *decoder, FLAC__byte buffer[], size_t *bytes, void *client_data);
96 static FLAC__StreamDecoderWriteStatus write_callback_(const FLAC__StreamDecoder *decoder, const FLAC__Frame *frame, const FLAC__int32 * const buffer[], void *client_data); 96 static FLAC__StreamDecoderWriteStatus write_callback_(const FLAC__StreamDecoder *decoder, const FLAC__Frame *frame, const FLAC__int32 * const buffer[], void *client_data);
97 static void metadata_callback_(const FLAC__StreamDecoder *decoder, const FLAC__StreamMetadata *metadata, void *client_data); 97 static void metadata_callback_(const FLAC__StreamDecoder *decoder, const FLAC__StreamMetadata *metadata, void *client_data);
98 static void error_callback_(const FLAC__StreamDecoder *decoder, FLAC__StreamDecoderErrorStatus status, void *client_data); 98 static void error_callback_(const FLAC__StreamDecoder *decoder, FLAC__StreamDecoderErrorStatus status, void *client_data);
99 99
100 gchar *flac_fmts[] = { "flac", NULL };
101
100 InputPlugin flac_ip = 102 InputPlugin flac_ip =
101 { 103 {
102 NULL, 104 NULL,
103 NULL, 105 NULL,
104 NULL, 106 NULL,
121 NULL, 123 NULL,
122 NULL, 124 NULL,
123 FLAC_XMMS__get_song_info, 125 FLAC_XMMS__get_song_info,
124 FLAC_XMMS__file_info_box, 126 FLAC_XMMS__file_info_box,
125 NULL, 127 NULL,
126 flac_get_tuple 128 flac_get_tuple,
129 NULL, // set tuple
127 NULL, 130 NULL,
128 NULL, 131 NULL,
129 { "flac", NULL }, 132 flac_fmts,
130 }; 133 };
131 134
132 #define SAMPLES_PER_WRITE 512 135 #define SAMPLES_PER_WRITE 512
133 #define SAMPLE_BUFFER_SIZE ((FLAC__MAX_BLOCK_SIZE + SAMPLES_PER_WRITE) * FLAC_PLUGIN__MAX_SUPPORTED_CHANNELS * (24/8)) 136 #define SAMPLE_BUFFER_SIZE ((FLAC__MAX_BLOCK_SIZE + SAMPLES_PER_WRITE) * FLAC_PLUGIN__MAX_SUPPORTED_CHANNELS * (24/8))
134 static FLAC__byte sample_buffer_[SAMPLE_BUFFER_SIZE]; 137 static FLAC__byte sample_buffer_[SAMPLE_BUFFER_SIZE];