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

Unified Diff: media/filters/vpx_video_decoder.cc

Issue 1834303005: Refactor audio and video decoder status into common file. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix cast. Created 4 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
Index: media/filters/vpx_video_decoder.cc
diff --git a/media/filters/vpx_video_decoder.cc b/media/filters/vpx_video_decoder.cc
index 8fe66250cd480eedfff3b400670e6542c4a5ef6a..3418498b7ed19e01d7d6122e930b21f9f556eb05 100644
--- a/media/filters/vpx_video_decoder.cc
+++ b/media/filters/vpx_video_decoder.cc
@@ -401,25 +401,25 @@ void VpxVideoDecoder::DecodeBuffer(const scoped_refptr<DecoderBuffer>& buffer,
<< "Called Decode() before successful Initialize()";
if (state_ == kError) {
- bound_decode_cb.Run(kDecodeError);
+ bound_decode_cb.Run(DecoderStatus::DECODE_ERROR);
return;
}
if (state_ == kDecodeFinished) {
- bound_decode_cb.Run(kOk);
+ bound_decode_cb.Run(DecoderStatus::OK);
return;
}
if (state_ == kNormal && buffer->end_of_stream()) {
state_ = kDecodeFinished;
- bound_decode_cb.Run(kOk);
+ bound_decode_cb.Run(DecoderStatus::OK);
return;
}
scoped_refptr<VideoFrame> video_frame;
if (!VpxDecode(buffer, &video_frame)) {
state_ = kError;
- bound_decode_cb.Run(kDecodeError);
+ bound_decode_cb.Run(DecoderStatus::DECODE_ERROR);
return;
}
@@ -432,7 +432,7 @@ void VpxVideoDecoder::DecodeBuffer(const scoped_refptr<DecoderBuffer>& buffer,
}
// VideoDecoderShim expects |decode_cb| call after |output_cb_|.
- bound_decode_cb.Run(kOk);
+ bound_decode_cb.Run(DecoderStatus::OK);
}
void VpxVideoDecoder::Decode(const scoped_refptr<DecoderBuffer>& buffer,

Powered by Google App Engine
This is Rietveld 408576698