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

Unified Diff: media/cast/sender/video_encoder_impl.cc

Issue 899583002: Revert of [Cast] Software encoder support for varying video frame sizes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 | « media/cast/sender/video_encoder_impl.h ('k') | media/cast/sender/video_encoder_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/sender/video_encoder_impl.cc
diff --git a/media/cast/sender/video_encoder_impl.cc b/media/cast/sender/video_encoder_impl.cc
index 4efe32044a80c2d299691bbe6cb570e379935500..52ece8ca22e4d05a922516de704e161f91b6bb29 100644
--- a/media/cast/sender/video_encoder_impl.cc
+++ b/media/cast/sender/video_encoder_impl.cc
@@ -54,8 +54,7 @@
VideoEncoderImpl::VideoEncoderImpl(
scoped_refptr<CastEnvironment> cast_environment,
- const VideoSenderConfig& video_config,
- const CastInitializationCallback& initialization_cb)
+ const VideoSenderConfig& video_config)
: cast_environment_(cast_environment) {
CHECK(cast_environment_->HasVideoThread());
if (video_config.codec == CODEC_VIDEO_VP8) {
@@ -76,15 +75,6 @@
dynamic_config_.key_frame_requested = false;
dynamic_config_.latest_frame_id_to_reference = kStartFrameId;
dynamic_config_.bit_rate = video_config.start_bitrate;
-
- if (!initialization_cb.is_null()) {
- cast_environment_->PostTask(
- CastEnvironment::MAIN,
- FROM_HERE,
- base::Bind(initialization_cb,
- encoder_.get() ? STATUS_VIDEO_INITIALIZED :
- STATUS_UNSUPPORTED_VIDEO_CODEC));
- }
}
VideoEncoderImpl::~VideoEncoderImpl() {
@@ -98,20 +88,11 @@
}
}
-bool VideoEncoderImpl::CanEncodeVariedFrameSizes() const {
- // Both the VP8Encoder and FakeSoftwareVideoEncoder support calls to
- // EncodeVideoFrame() with different frame sizes.
- return true;
-}
-
bool VideoEncoderImpl::EncodeVideoFrame(
const scoped_refptr<media::VideoFrame>& video_frame,
const base::TimeTicks& reference_time,
const FrameEncodedCallback& frame_encoded_callback) {
DCHECK(cast_environment_->CurrentlyOn(CastEnvironment::MAIN));
- DCHECK(!video_frame->visible_rect().IsEmpty());
- DCHECK(!frame_encoded_callback.is_null());
-
cast_environment_->PostTask(CastEnvironment::VIDEO,
FROM_HERE,
base::Bind(&EncodeVideoFrameOnEncoderThread,
« no previous file with comments | « media/cast/sender/video_encoder_impl.h ('k') | media/cast/sender/video_encoder_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698