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

Unified Diff: content/common/gpu/media/h264_parser.cc

Issue 10837058: Make H264BitReader ignore trailing zero bytes and stop bit. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Add back tests after merge from master. Created 8 years, 3 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 | « content/common/gpu/media/h264_bit_reader_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/media/h264_parser.cc
diff --git a/content/common/gpu/media/h264_parser.cc b/content/common/gpu/media/h264_parser.cc
index d25a8021cdb2daec756b9aa662c16f4b82ab0d19..2cefb752026cbb63ecc4dec8ff0516c3fae772bc 100644
--- a/content/common/gpu/media/h264_parser.cc
+++ b/content/common/gpu/media/h264_parser.cc
@@ -730,8 +730,9 @@ H264Parser::Result H264Parser::ParsePPS(int* pps_id) {
READ_BOOL_OR_RETURN(&pps->constrained_intra_pred_flag);
READ_BOOL_OR_RETURN(&pps->redundant_pic_cnt_present_flag);
- if (br_.HasMoreRBSPData()) {
- READ_BOOL_OR_RETURN(&pps->transform_8x8_mode_flag);
+ int temp;
+ if (br_.ReadBits(1, &temp)) {
+ pps->transform_8x8_mode_flag = temp;
READ_BOOL_OR_RETURN(&pps->pic_scaling_matrix_present_flag);
if (pps->pic_scaling_matrix_present_flag) {
« no previous file with comments | « content/common/gpu/media/h264_bit_reader_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698