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

Unified Diff: media/video/video_encode_types.cc

Issue 12379011: Interfaces for encoded video sources (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Build fixes Created 7 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
« media/video/video_encode_types.h ('K') | « media/video/video_encode_types.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/video/video_encode_types.cc
diff --git a/media/video/video_encode_types.cc b/media/video/video_encode_types.cc
new file mode 100644
index 0000000000000000000000000000000000000000..b34dd1f5da290ba9771b65d65c82b5336d268b36
--- /dev/null
+++ b/media/video/video_encode_types.cc
@@ -0,0 +1,74 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "media/video/video_encode_types.h"
+
+namespace media {
+
+VideoEncodingLimits::EncoderConfig::EncoderConfig() {
+ // Intentionally empty.
+}
+
+VideoEncodingLimits::EncoderConfig::~EncoderConfig() {
+ // Intentionally empty.
+}
+
+VideoEncodingLimits::VideoEncodingLimits() {
+ // Intentionally empty.
+}
+
+VideoEncodingLimits::~VideoEncodingLimits() {
+ // Intentionally empty.
+}
+
+RuntimeVideoEncodingParameters::RuntimeVideoEncodingParameters() {
+ // Intentionally empty.
+}
+
+RuntimeVideoEncodingParameters::~RuntimeVideoEncodingParameters() {
+ // Intentionally empty.
+}
+
+} // namespace media
+
+std::ostream& operator<<(
+ std::ostream& output,
+ const media::VideoEncodingLimits::EncoderConfig::Range& r) {
+ output << r.min << "..." << r.max << "@" << r.step << " steps";
+ return output;
+}
+
+std::ostream& operator<<(
+ std::ostream& output,
+ const media::VideoEncodingLimits::EncoderConfig& c) {
+ output << c.resolution.width() << "x" << c.resolution.height();
+ output << "@[";
+ std::vector<int>::const_iterator it;
+ for (it = c.frames_per_second.begin(); it != c.frames_per_second.end();
+ ++it) {
+ if (it != c.frames_per_second.begin())
+ output << ", ";
+ output << *it;
+ }
+ output << "] fps";
+ output << ", ";
+ output << "bitrate: " << c.average_bitrate;
+ output << ", ";
+ output << "qp_range: " << c.qp;
+ output << ", ";
+ output << "num_of_streams: " << c.stream_count;
+ output << ", ";
+ output << "num_of_temporal_layers: " << c.temporal_layer_count;
+ return output;
+}
+
+std::ostream& operator<<(std::ostream& output,
+ const media::VideoEncodingLimits& l) {
+ std::vector<media::VideoEncodingLimits::EncoderConfig>::const_iterator it;
+ for (it = l.configs.begin(); it != l.configs.end(); it++) {
+ output << *it << ", ";
+ }
+ return output;
+}
+
« media/video/video_encode_types.h ('K') | « media/video/video_encode_types.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698