From 7ca322eea848a85d976d0a5c7f3b889cd157d941 Mon Sep 17 00:00:00 2001 From: Damiano Galassi Date: Sat, 14 Dec 2013 10:18:26 +0100 Subject: [PATCH] =?UTF-8?q?Handle=20files=20with=20the=20=E2=80=9Cm4r?= =?UTF-8?q?=E2=80=9D=20extension.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- MP42/MP42File.m | 8 ++++---- MP42/MP42MediaFormat.h | 2 +- MP42/MP42MediaFormat.m | 1 + 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/MP42/MP42File.m b/MP42/MP42File.m index c19f1e5..1282095 100644 --- a/MP42/MP42File.m +++ b/MP42/MP42File.m @@ -494,15 +494,15 @@ static void logCallback(MP4LogLevel loglevel, const char* fmt, va_list ap) supportedBrands[2] = "mp42"; supportedBrands[3] = "isom"; supportedBrandsCount = 4; - } - else if ([fileExtension isEqualToString:MP42FileTypeM4A] || [fileExtension isEqualToString:MP42FileTypeM4A]) { + } else if ([fileExtension isEqualToString:MP42FileTypeM4A] || + [fileExtension isEqualToString:MP42FileTypeM4B] || + [fileExtension isEqualToString:MP42FileTypeM4R]) { majorBrand = "M4A "; supportedBrands[0] = majorBrand; supportedBrands[1] = "mp42"; supportedBrands[2] = "isom"; supportedBrandsCount = 3; - } - else { + } else { supportedBrands[0] = majorBrand; supportedBrands[1] = "isom"; supportedBrandsCount = 2; diff --git a/MP42/MP42MediaFormat.h b/MP42/MP42MediaFormat.h index fc5360a..a293eec 100644 --- a/MP42/MP42MediaFormat.h +++ b/MP42/MP42MediaFormat.h @@ -18,7 +18,7 @@ extern NSString *const MP42FileTypeMP4; extern NSString *const MP42FileTypeM4V; extern NSString *const MP42FileTypeM4A; extern NSString *const MP42FileTypeM4B; - +extern NSString *const MP42FileTypeM4R; // Media Type extern NSString *const MP42MediaTypeVideo; diff --git a/MP42/MP42MediaFormat.m b/MP42/MP42MediaFormat.m index e45b345..d8998b6 100644 --- a/MP42/MP42MediaFormat.m +++ b/MP42/MP42MediaFormat.m @@ -13,6 +13,7 @@ NSString *const MP42FileTypeMP4 = @"mp4"; NSString *const MP42FileTypeM4V = @"m4v"; NSString *const MP42FileTypeM4A = @"m4a"; NSString *const MP42FileTypeM4B = @"m4b"; +NSString *const MP42FileTypeM4R = @"m4r"; // Media Type