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

Unified Diff: media/base/pipeline.h

Issue 39170: Pipeline_Impl was modified to properly render a stream that has video but no ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 10 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
Index: media/base/pipeline.h
===================================================================
--- media/base/pipeline.h (revision 10997)
+++ media/base/pipeline.h (working copy)
@@ -17,14 +17,21 @@
namespace media {
-// Error definitions for pipeline.
+// Error definitions for pipeline. All codes indicate an error except:
+// PIPELINE_OK indicates the pipeline is running normally.
+// PIPELINE_STOPPING is used internally when Pipeline::Stop() is called.
enum PipelineError {
PIPELINE_OK,
+ PIPELINE_STOPPING,
+ PIPELINE_ERROR_URL_NOT_FOUND,
PIPELINE_ERROR_NETWORK,
PIPELINE_ERROR_DECODE,
PIPELINE_ERROR_ABORT,
PIPELINE_ERROR_INITIALIZATION_FAILED,
- PIPELINE_STOPPING
+ PIPELINE_ERROR_REQUIRED_FILTER_MISSING,
+ PIPELINE_ERROR_OUT_OF_MEMORY,
+ PIPELINE_ERROR_COULD_NOT_RENDER,
+ PIPELINE_ERROR_READ
};
// Base class for Pipeline class which allows for read-only access to members.
@@ -90,6 +97,12 @@
// operating correctly, this will return OK.
virtual PipelineError GetError() const = 0;
+ // If the |major_mime_type| exists in the pipeline and is being rendered, this
+ // method will return true. Types are defined in media/base/media_foramt.h.
+ // For example, to determine if a pipeline contains video:
+ // bool has_video = pipeline->IsRendered(mime_type::kMajorTypeVideo);
+ virtual bool IsRendered(const std::string& major_mime_type) const = 0;
+
protected:
virtual ~PipelineStatus() {}
};

Powered by Google App Engine
This is Rietveld 408576698