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

Unified Diff: media/base/text_track_config.h

Issue 23702007: Render inband text tracks in the media pipeline (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix compile errors 11/21 #6 Created 7 years, 1 month 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/base/text_track.h ('k') | media/base/text_track_config.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/text_track_config.h
diff --git a/media/base/text_track_config.h b/media/base/text_track_config.h
new file mode 100644
index 0000000000000000000000000000000000000000..90b24012307251abe5e617bdf5de7abe48c31442
--- /dev/null
+++ b/media/base/text_track_config.h
@@ -0,0 +1,45 @@
+// 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.
+
+#ifndef MEDIA_BASE_TEXT_TRACK_CONFIG_H_
+#define MEDIA_BASE_TEXT_TRACK_CONFIG_H_
+
+#include <string>
+
+#include "media/base/media_export.h"
+
+namespace media {
+
+// Specifies the varieties of text tracks.
+enum TextKind {
+ kTextSubtitles,
+ kTextCaptions,
+ kTextDescriptions,
+ kTextMetadata,
+ kTextNone
+};
+
+class MEDIA_EXPORT TextTrackConfig {
+ public:
+ TextTrackConfig();
+ TextTrackConfig(TextKind kind,
+ const std::string& label,
+ const std::string& language);
+
+ // Returns true if all fields in |config| match this config.
+ bool Matches(const TextTrackConfig& config) const;
+
+ TextKind kind() const { return kind_; }
+ const std::string& label() const { return label_; }
+ const std::string& language() const { return language_; }
+
+ private:
+ TextKind kind_;
+ std::string label_;
+ std::string language_;
+};
+
+} // namespace media
+
+#endif // MEDIA_BASE_TEXT_TRACK_H_
« no previous file with comments | « media/base/text_track.h ('k') | media/base/text_track_config.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698