Changeset 1014
- Timestamp:
- 01/19/09 08:53:27 (1 year ago)
- Files:
-
- trunk/MatroskaImportPrivate.cpp (modified) (1 diff)
- trunk/bitstream_info.c (modified) (2 diffs)
- trunk/bitstream_info.h (modified) (1 diff)
- trunk/ff_private.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/MatroskaImportPrivate.cpp
r989 r1014 986 986 switch ((*desc)->dataFormat) { 987 987 case kAudioFormatAC3: 988 replaceSoundDesc = parse_ac3_bitstream(&asbd, &acl, block.GetBuffer(0).Buffer(), block.GetFrameSize(0) , true);988 replaceSoundDesc = parse_ac3_bitstream(&asbd, &acl, block.GetBuffer(0).Buffer(), block.GetFrameSize(0)); 989 989 break; 990 990 } trunk/bitstream_info.c
r1008 r1014 82 82 * @param buffer Pointer to the buffer data to scan 83 83 * @param buff_size Size of the buffer 84 * @param wellFramed YES if the container is well frame, NO otherwise. AVI is NO!85 84 * @return 1 if successfull, 0 otherwise 86 85 */ 87 86 88 int parse_ac3_bitstream(AudioStreamBasicDescription *asbd, AudioChannelLayout *acl, uint8_t *buffer, int buff_size , bool wellFramed)87 int parse_ac3_bitstream(AudioStreamBasicDescription *asbd, AudioChannelLayout *acl, uint8_t *buffer, int buff_size) 89 88 { 90 89 int offset = ac3_synchronize(buffer, buff_size); … … 142 141 memset(asbd, 0, sizeof(AudioStreamBasicDescription)); 143 142 asbd->mSampleRate = sample_rate >> shift; 144 if(wellFramed && offset == 0 && buff_size == framesize) 145 asbd->mFormatID = kAudioFormatAC3; 146 else 147 asbd->mFormatID = kAudioFormatAC3MS; 143 asbd->mFormatID = kAudioFormatAC3MS; 148 144 asbd->mChannelsPerFrame = nfchans_tbl[acmod] + lfe; 149 145 trunk/bitstream_info.h
r1008 r1014 15 15 #endif 16 16 17 int parse_ac3_bitstream(AudioStreamBasicDescription *asbd, AudioChannelLayout *acl, uint8_t *buffer, int buff_size , bool wellFramed);17 int parse_ac3_bitstream(AudioStreamBasicDescription *asbd, AudioChannelLayout *acl, uint8_t *buffer, int buff_size); 18 18 19 19 typedef struct FFusionParserContext trunk/ff_private.c
r1007 r1014 292 292 QTMetaDataRelease(trackMetaData); 293 293 } 294 if(parse_ac3_bitstream(&asbd, &acl, firstFrame->data, firstFrame->size , false))294 if(parse_ac3_bitstream(&asbd, &acl, firstFrame->data, firstFrame->size)) 295 295 { 296 296 useDefault = 0;
