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

Side by Side Diff: third_party/WebKit/LayoutTests/imagecapture/MediaStreamTrack-applyConstraints-getSettings.html

Issue 2787933002: ImageCapture: separate fillLightMode, redEyeReduction and Torch (Closed)
Patch Set: Created 3 years, 8 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 unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../resources/testharness.js"></script> 2 <script src="../resources/testharness.js"></script>
3 <script src="../resources/testharnessreport.js"></script> 3 <script src="../resources/testharnessreport.js"></script>
4 <script src="../resources/mojo-helpers.js"></script> 4 <script src="../resources/mojo-helpers.js"></script>
5 <script src="resources/mock-imagecapture.js"></script> 5 <script src="resources/mock-imagecapture.js"></script>
6 <body> 6 <body>
7 <canvas id='canvas' width=10 height=10/> 7 <canvas id='canvas' width=10 height=10/>
8 </body> 8 </body>
9 <script> 9 <script>
10 10
(...skipping 15 matching lines...) Expand all
26 26
27 exposureCompensation : 133.77, 27 exposureCompensation : 133.77,
28 colorTemperature : 6000, 28 colorTemperature : 6000,
29 iso : 120.0, 29 iso : 120.0,
30 30
31 brightness : 3, 31 brightness : 3,
32 contrast : 4, 32 contrast : 4,
33 saturation : 5, 33 saturation : 5,
34 sharpness : 6, 34 sharpness : 6,
35 35
36 zoom : 3.141592 36 zoom : 3.141592,
37 // TODO: torch https://crbug.com/700607. 37
38 torch : true
38 }]}; 39 }]};
39 var theMock = null; 40 var theMock = null;
40 var videoTrack = null; 41 var videoTrack = null;
41 mockImageCaptureReady 42 mockImageCaptureReady
42 .then(mock => { 43 .then(mock => {
43 theMock = mock; 44 theMock = mock;
44 }, 45 },
45 error => { 46 error => {
46 assert_unreached("Error creating MockImageCapture: " + error); 47 assert_unreached("Error creating MockImageCapture: " + error);
47 }) 48 })
(...skipping 27 matching lines...) Expand all
75 'brightness'); 76 'brightness');
76 assert_equals(constraints.advanced[0].contrast, settings.contrast, 77 assert_equals(constraints.advanced[0].contrast, settings.contrast,
77 'contrast'); 78 'contrast');
78 assert_equals(constraints.advanced[0].saturation, settings.saturation, 79 assert_equals(constraints.advanced[0].saturation, settings.saturation,
79 'saturation'); 80 'saturation');
80 assert_equals(constraints.advanced[0].sharpness, settings.sharpness, 81 assert_equals(constraints.advanced[0].sharpness, settings.sharpness,
81 'sharpness'); 82 'sharpness');
82 83
83 assert_equals(constraints.advanced[0].zoom, settings.zoom, 'zoom'); 84 assert_equals(constraints.advanced[0].zoom, settings.zoom, 'zoom');
84 85
85 // TODO(mcasas): check |torch| when the mojom interface is updated, 86 assert_equals(constraints.advanced[0].torch, settings.torch, 'torch');
86 // https://crbug.com/700607.
87 87
88 t.done(); 88 t.done();
89 }) 89 })
90 .catch(error => { 90 .catch(error => {
91 assert_unreached("Error applying constraints: " + error.message); 91 assert_unreached("Error applying constraints: " + error.message);
92 }); 92 });
93 93
94 }, 'exercises an applyConstraints() - getSettings() cycle'); 94 }, 'exercises an applyConstraints() - getSettings() cycle');
95 95
96 </script> 96 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698