-
Notifications
You must be signed in to change notification settings - Fork 56
Open
Description
Using the following code:
FFmpegWrapper *ffmpegWrapper = [[FFmpegWrapper alloc] init];
[ffmpegWrapper convertInputPath:mkvVideoFilePath outputPath:mp4VideoFilePath options:nil progressBlock:^(NSUInteger bytesRead, uint64_t totalBytesRead, uint64_t totalBytesExpectedToRead) {
NSLog(@"Progress: %.2f", (float)totalBytesRead / totalBytesExpectedToRead);
} completionBlock:^(BOOL success, NSError *error) {
if (success && !error) {
// delete mp4 file
} else {
if (error) {
DDLogError(@"MKV -> MP4 conversion: Error occured: %@", error.localizedDescription);
// do something else with the error
} else {
DDLogError(@"MKV -> MP4 conversion: Unknown error occured.");
}
// check if mkv also needs to be deleted
}];
Problems:
- The video is unplayable.
- Output mp4 is 5 minutes long, while input mkv is 11 seconds long.
- Console is flooded with logs.
- Even though everything failed, the completionBlock is called with success = YES, error = nil.
My console looks like the linked gist file (FFmpegWrapper is basically spamming with logs, 30k lines generated for 11s .mkv movie, it's really long so I don't want to attach it here).
I'm using the version from:
pod 'FFmpegWrapper-up-to-date', '~> 1.2'
Metadata
Metadata
Assignees
Labels
No labels