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

Side by Side Diff: media/filters/vp9_raw_bits_reader.h

Issue 2133993002: Parse VP9 compressed header (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: reset curr_frame_info_ when Reset Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « media/filters/vp9_parser_unittest.cc ('k') | media/filters/vp9_raw_bits_reader.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_FILTERS_VP9_RAW_BITS_READER_H_ 5 #ifndef MEDIA_FILTERS_VP9_RAW_BITS_READER_H_
6 #define MEDIA_FILTERS_VP9_RAW_BITS_READER_H_ 6 #define MEDIA_FILTERS_VP9_RAW_BITS_READER_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 30 matching lines...) Expand all
41 bool ReadBool(); 41 bool ReadBool();
42 42
43 // Reads a literal with |bits| bits. 43 // Reads a literal with |bits| bits.
44 // If the read goes beyond the end of buffer, the return value is undefined. 44 // If the read goes beyond the end of buffer, the return value is undefined.
45 int ReadLiteral(int bits); 45 int ReadLiteral(int bits);
46 46
47 // Reads a signed literal with |bits| bits (not including the sign bit). 47 // Reads a signed literal with |bits| bits (not including the sign bit).
48 // If the read goes beyond the end of buffer, the return value is undefined. 48 // If the read goes beyond the end of buffer, the return value is undefined.
49 int ReadSignedLiteral(int bits); 49 int ReadSignedLiteral(int bits);
50 50
51 // Consumes trailing bits up to next byte boundary. Returns true if no
52 // trailing bits or they are all zero.
53 bool ConsumeTrailingBits();
54
51 private: 55 private:
52 std::unique_ptr<BitReader> reader_; 56 std::unique_ptr<BitReader> reader_;
53 57
54 // Indicates if none of the reads since the last Initialize() call has gone 58 // Indicates if none of the reads since the last Initialize() call has gone
55 // beyond the end of available data. 59 // beyond the end of available data.
56 bool valid_; 60 bool valid_;
57 61
58 DISALLOW_COPY_AND_ASSIGN(Vp9RawBitsReader); 62 DISALLOW_COPY_AND_ASSIGN(Vp9RawBitsReader);
59 }; 63 };
60 64
61 } // namespace media 65 } // namespace media
62 66
63 #endif // MEDIA_FILTERS_VP9_RAW_BITS_READER_H_ 67 #endif // MEDIA_FILTERS_VP9_RAW_BITS_READER_H_
OLDNEW
« no previous file with comments | « media/filters/vp9_parser_unittest.cc ('k') | media/filters/vp9_raw_bits_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698