class Vp9Parser

Defined at line 274 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.h

A parser for VP9 bitstream.

Public Methods

void Vp9Parser (const Vp9Parser & )

Defined at line 377 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.h

Vp9Parser & operator= (const Vp9Parser & )

Defined at line 378 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.h

const Context & context ()

Return current parsing context.

Defined at line 421 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.h

void Vp9Parser (bool parsing_compressed_header)

See homonymous member variables for information on the parameters.

Defined at line 558 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

void Vp9Parser (bool parsing_compressed_header, bool needs_external_context_update)

Defined at line 562 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

void ~Vp9Parser ()

Defined at line 569 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

void SetStream (const uint8_t * stream, off_t stream_size, const std::vector<uint32_t> & spatial_layer_frame_size, std::unique_ptr<DecryptConfig> stream_config)

Set a new stream buffer to read from, starting at |stream| and of size

|stream_size| in bytes. |stream| must point to the beginning of a single

frame or a single superframe, is owned by caller and must remain valid

until the next call to SetStream(). |spatial_layer_frame_size| may be

filled if the parsed stream is VP9 SVC. It stands for frame sizes of

spatial layers. SVC frame might have multiple frames without superframe

index. The info helps Vp9Parser detecting the beginning of each frame.

Defined at line 571 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

void SetStream (const uint8_t * stream, off_t stream_size, std::unique_ptr<DecryptConfig> stream_config)

Defined at line 583 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

Result ParseNextFrame (Vp9FrameHeader * fhdr, gfx::Size * allocate_size, std::unique_ptr<DecryptConfig> * frame_decrypt_config)

Parse the next frame in the current stream buffer, filling |fhdr| with

the parsed frame header and updating current segmentation and loop filter

state. The necessary frame size to decode |fhdr| fills in |allocate_size|.

The size can be larger than frame size of |fhdr| in the case of SVC stream.

Also fills |frame_decrypt_config| _if_ the parser was set to use a super

frame decrypt config.

Return kOk if a frame has successfully been parsed,

kEOStream if there is no more data in the current stream buffer,

kAwaitingRefresh if this frame awaiting frame context update, or

kInvalidStream on error.

Defined at line 699 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

std::unique_ptr<DecryptConfig> NextFrameDecryptContextForTesting ()

Perform the same superframe parsing logic, but don't attempt to parse

the normal frame headers afterwards, and then only return the decrypt

config, since the frame itself isn't useful for the testing.

Returns |true| if a frame would have been sent to |ParseUncompressedHeader|

|false| if there was an error parsing the superframe.

Defined at line 790 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

std::string IncrementIVForTesting (const std::string & iv, uint32_t by)

Defined at line 808 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

ContextRefreshCallback GetContextRefreshCb (size_t frame_context_idx)

Return a ContextRefreshCallback, which, if not null, has to be called with

the new context state after the frame associated with |frame_context_idx|

is decoded.

Defined at line 781 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

void Reset ()

Clear parser state and return to an initialized state.

Defined at line 589 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.cc

Enumerations

enum Result
Name Value
kOk 0
kInvalidStream 1
kEOStream 2
kAwaitingRefresh 3

ParseNextFrame() return values. See documentation for ParseNextFrame().

Defined at line 282 of file ../../src/media/third_party/chromium_media/media/filters/vp9_parser.h

Records