1 --- vlc-0.8.6/modules/codec/flac.c.orig 2007-01-02 01:06:46.000000000 +0000
2 +++ vlc-0.8.6/modules/codec/flac.c 2007-01-02 01:43:51.000000000 +0000
7 - FLAC__stream_decoder_set_read_callback( p_sys->p_flac,
8 - DecoderReadCallback );
9 - FLAC__stream_decoder_set_write_callback( p_sys->p_flac,
10 - DecoderWriteCallback );
11 - FLAC__stream_decoder_set_metadata_callback( p_sys->p_flac,
12 - DecoderMetadataCallback );
13 - FLAC__stream_decoder_set_error_callback( p_sys->p_flac,
14 - DecoderErrorCallback );
15 - FLAC__stream_decoder_set_client_data( p_sys->p_flac, p_dec );
17 - FLAC__stream_decoder_init( p_sys->p_flac );
18 + FLAC__stream_decoder_init_stream( p_sys->p_flac,
19 + DecoderReadCallback,
24 + DecoderWriteCallback,
25 + DecoderMetadataCallback,
26 + DecoderErrorCallback,
31 /* Set output properties */
33 case FLAC__STREAM_DECODER_END_OF_STREAM:
34 msg_Dbg( p_dec, "the decoder has reached the end of the stream." );
36 + case FLAC__STREAM_DECODER_OGG_ERROR:
37 + msg_Dbg( p_dec, "the decoder got ogg error." );
39 + case FLAC__STREAM_DECODER_SEEK_ERROR:
40 + msg_Dbg( p_dec, "the decoder got seek error." );
42 case FLAC__STREAM_DECODER_ABORTED:
43 msg_Warn( p_dec, "the decoder was aborted by the read callback." );
45 - case FLAC__STREAM_DECODER_UNPARSEABLE_STREAM:
46 - msg_Warn( p_dec, "the decoder encountered reserved fields in use "
49 case FLAC__STREAM_DECODER_MEMORY_ALLOCATION_ERROR:
50 msg_Err( p_dec, "error when allocating memory." );
52 - case FLAC__STREAM_DECODER_ALREADY_INITIALIZED:
53 - msg_Err( p_dec, "FLAC__stream_decoder_init() was called when the "
54 - "decoder was already initialized, usually because "
55 - "FLAC__stream_decoder_finish() was not called." );
57 - case FLAC__STREAM_DECODER_INVALID_CALLBACK:
58 - msg_Err( p_dec, "FLAC__stream_decoder_init() was called without "
59 - "all callbacks being set." );
61 case FLAC__STREAM_DECODER_UNINITIALIZED:
62 msg_Err( p_dec, "decoder in uninitialized state." );
64 @@ -1193,15 +1186,14 @@
65 FLAC__stream_encoder_set_bits_per_sample( p_sys->p_flac, 16 );
66 p_enc->fmt_in.i_codec = AOUT_FMT_S16_NE;
68 - FLAC__stream_encoder_set_write_callback( p_sys->p_flac,
69 - EncoderWriteCallback );
70 - FLAC__stream_encoder_set_metadata_callback( p_sys->p_flac,
71 - EncoderMetadataCallback );
72 - FLAC__stream_encoder_set_client_data( p_sys->p_flac, p_enc );
74 /* Get and store the STREAMINFO metadata block as a p_extra */
76 - FLAC__stream_encoder_init( p_sys->p_flac );
77 + FLAC__stream_encoder_init_stream( p_sys->p_flac ,
78 + EncoderWriteCallback,
81 + EncoderMetadataCallback,