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

Unified Diff: content/renderer/media/media_stream_constraints_util_video_content.h

Issue 2751643003: Minor refactoring of SelectSettings results for consistency. (Closed)
Patch Set: rebase Created 3 years, 9 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 | « no previous file | content/renderer/media/media_stream_constraints_util_video_device.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/media_stream_constraints_util_video_content.h
diff --git a/content/renderer/media/media_stream_constraints_util_video_content.h b/content/renderer/media/media_stream_constraints_util_video_content.h
index 5ec86dd9d8c5681587c8c633d931619dfae008cc..250b4ecd03729a75fc582d524113459dabd4594e 100644
--- a/content/renderer/media/media_stream_constraints_util_video_content.h
+++ b/content/renderer/media/media_stream_constraints_util_video_content.h
@@ -7,6 +7,7 @@
#include <string>
+#include "base/logging.h"
#include "content/common/content_export.h"
#include "media/capture/video_capture_types.h"
#include "third_party/webrtc/base/optional.h"
@@ -46,11 +47,18 @@ class CONTENT_EXPORT VideoContentCaptureSourceSelectionResult {
// Accessors.
const char* failed_constraint_name() const { return failed_constraint_name_; }
- const std::string& device_id() const { return device_id_; }
+ const std::string& device_id() const {
+ DCHECK(HasValue());
+ return device_id_;
+ }
const rtc::Optional<bool>& noise_reduction() const {
+ DCHECK(HasValue());
return noise_reduction_;
}
- media::VideoCaptureParams capture_params() const { return capture_params_; }
+ media::VideoCaptureParams capture_params() const {
+ DCHECK(HasValue());
+ return capture_params_;
+ }
// Convenience accessors for fields embedded in the |capture_params_| field.
int Height() const;
« no previous file with comments | « no previous file | content/renderer/media/media_stream_constraints_util_video_device.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698