Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Unified Diff: media/video/capture/mac/video_capture_device_qtkit_mac.mm

Issue 464853002: Mac Video Capture: correct to float the erroneous handling of frame rate as int. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/video/capture/mac/video_capture_device_qtkit_mac.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/video/capture/mac/video_capture_device_qtkit_mac.mm
diff --git a/media/video/capture/mac/video_capture_device_qtkit_mac.mm b/media/video/capture/mac/video_capture_device_qtkit_mac.mm
index 599cfac59eefb52ba42012ac42b032ad86071f02..7f4a853c63a9bde6d9b260a720a947d143f68cbc 100644
--- a/media/video/capture/mac/video_capture_device_qtkit_mac.mm
+++ b/media/video/capture/mac/video_capture_device_qtkit_mac.mm
@@ -174,7 +174,9 @@
}
}
-- (BOOL)setCaptureHeight:(int)height width:(int)width frameRate:(int)frameRate {
+- (BOOL)setCaptureHeight:(int)height
+ width:(int)width
+ frameRate:(float)frameRate {
if (!captureDeviceInput_) {
[self sendErrorString:[NSString
stringWithUTF8String:"No video capture device set."]];
@@ -185,7 +187,7 @@
stringWithUTF8String:"Video capture capabilities already set."]];
return NO;
}
- if (frameRate <= 0) {
+ if (frameRate <= 0.0f) {
[self sendErrorString:[NSString stringWithUTF8String: "Wrong frame rate."]];
return NO;
}
@@ -205,7 +207,7 @@
};
[output setPixelBufferAttributes:videoSettingsDictionary];
- [output setMinimumVideoFrameInterval:(NSTimeInterval)1/(float)frameRate];
+ [output setMinimumVideoFrameInterval:(NSTimeInterval)1/frameRate];
return YES;
}
« no previous file with comments | « media/video/capture/mac/video_capture_device_qtkit_mac.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698