cog/Plugins/CoreAudio/CoreAudioPropertiesReader.m

39 lines
623 B
Matlab
Raw Normal View History

//
// MADPropertiesReader.m
// MAD
//
// Created by Vincent Spader on 2/24/07.
// Copyright 2007 __MyCompanyName__. All rights reserved.
//
#import "CoreAudioPropertiesReader.h"
#import "CoreAudioDecoder.h"
@implementation CoreAudioPropertiesReader
+ (NSDictionary *)propertiesForSource:(id<CogSource>)source
{
NSDictionary *properties;
CoreAudioDecoder *decoder;
decoder = [[CoreAudioDecoder alloc] init];
if (![decoder open:source])
{
return nil;
}
properties = [decoder properties];
[decoder close];
return properties;
}
+ (NSArray *)fileTypes
{
return [CoreAudioDecoder fileTypes];
}
@end