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

Unified Diff: media/base/pipeline_impl.cc

Issue 7193001: Move rtc_video_decoder* from media/filter/ to content/renderer/media/. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 9 years, 6 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_impl.cc
===================================================================
--- media/base/pipeline_impl.cc (revision 90607)
+++ media/base/pipeline_impl.cc (working copy)
@@ -14,7 +14,6 @@
#include "base/compiler_specific.h"
#include "base/stl_util-inl.h"
#include "base/synchronization/condition_variable.h"
-#include "media/filters/rtc_video_decoder.h"
#include "media/base/clock.h"
#include "media/base/filter_collection.h"
#include "media/base/media_format.h"
@@ -617,7 +616,24 @@
pipeline_init_state_->composite_ = new CompositeFilter(message_loop_);
pipeline_init_state_->composite_->set_host(this);
- if (RTCVideoDecoder::IsUrlSupported(url)) {
+ bool raw_media = true;
scherkus (not reviewing) 2011/06/29 00:39:28 I believe you can replace all of this with a helpe
Ronghua 2011/06/29 20:36:39 Done.
+ if (url.length() < strlen(kRawMediaScheme)) {
+ raw_media = false;
+ } else {
+ const char* url_cstr = url.c_str();
+ int s_begin = 0;
+ int s_end = strlen(kRawMediaScheme);
+ for (int i = s_begin; i < s_end; ++i) {
+ const char c = url_cstr[i];
+ const char c_lower = (c >= 'A' && c <= 'Z') ? (c + ('a' - 'A')) : c;
+ if (!c_lower || c_lower != kRawMediaScheme[i]) {
+ raw_media = false;
+ break;
+ }
+ }
+ }
+
+ if (raw_media) {
set_state(kInitVideoDecoder);
InitializeVideoDecoder(NULL);
} else {

Powered by Google App Engine
This is Rietveld 408576698