1 --- faad2/plugins/mpeg4ip/aa_file.cpp.orig 2006-01-25 21:44:44.000000000 +0100
2 +++ faad2/plugins/mpeg4ip/aa_file.cpp 2006-01-25 22:29:06.103470750 +0100
5 int aac_file_next_frame (codec_data_t *your,
8 + frame_timestamp_t *ts)
10 aac_codec_t *aac = (aac_codec_t *)your;
14 calc = aac->m_framecount * 1024 * M_LLU;
17 + ts->msec_timestamp = calc;
18 *buffer = aac->m_buffer;
20 return (aac->m_buffer_size);
21 --- faad2/plugins/mpeg4ip/faad2.h.orig 2004-01-05 15:05:12.000000000 +0100
22 +++ faad2/plugins/mpeg4ip/faad2.h 2006-01-25 22:17:53.373427750 +0100
25 int aac_file_next_frame(codec_data_t *ifptr,
28 + frame_timestamp_t *ts);
29 int aac_file_eof(codec_data_t *ifptr);
31 void aac_file_used_for_frame(codec_data_t *ifptr,
32 --- faad2/plugins/mpeg4ip/faad2.cpp.orig 2006-01-25 22:43:27.605311250 +0100
33 +++ faad2/plugins/mpeg4ip/faad2.cpp 2006-01-25 22:27:24.273106750 +0100
36 * Create CAACodec class
38 -static codec_data_t *aac_codec_create (const char *compressor,
39 +static codec_data_t *aac_codec_create (
40 + const char* /*stream_type*/,
41 + const char* /*compressor*/,
44 format_list_t *media_fmt,
46 * Decode task call for FAAC
48 static int aac_decode (codec_data_t *ptr,
50 + frame_timestamp_t* ts,
55 if (aac->m_record_sync_time) {
56 aac->m_current_frame = 0;
57 aac->m_record_sync_time = 0;
58 - aac->m_current_time = ts;
59 - aac->m_last_rtp_ts = ts;
60 + aac->m_current_time = ts->msec_timestamp;
61 + aac->m_last_rtp_ts = ts->msec_timestamp;
63 - if (aac->m_last_rtp_ts == ts) {
64 + if (aac->m_last_rtp_ts == ts->msec_timestamp) {
65 aac->m_current_time += aac->m_msec_per_frame;
66 aac->m_current_frame++;
68 - aac->m_last_rtp_ts = ts;
69 - aac->m_current_time = ts;
70 + aac->m_last_rtp_ts = ts->msec_timestamp;
71 + aac->m_current_time = ts->msec_timestamp;
72 aac->m_current_frame = 0;
76 aac->m_vft->audio_configure(aac->m_ifptr,
81 aac->m_output_frame_size);
82 - uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr);
83 + uint8_t *now = aac->m_vft->audio_get_buffer(aac->m_ifptr, aac->m_freq, aac->m_current_time);
84 aac->m_audio_inited = 1;
90 static int aac_codec_check (lib_message_func_t message,
91 + const char *stream_type,
92 const char *compressor,
97 if (userdata != NULL) {
98 mpeg4_audio_config_t audio_config;
99 - decode_mpeg4_audio_config(userdata, userdata_size, &audio_config);
100 + decode_mpeg4_audio_config(userdata, userdata_size, &audio_config, false);
101 message(LOG_DEBUG, "aac", "audio type is %d", audio_config.audio_object_type);
102 if (fmtp != NULL) free_fmtp_parse(fmtp);