vp9

package
v1.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 20, 2024 License: MIT Imports: 2 Imported by: 17

Documentation

Overview

Package vp9 contains utilities to work with the VP9 codec.

Index

Constants

View Source
const (
	// MaxFrameSize is the maximum size of a frame.
	MaxFrameSize = 2 * 1024 * 1024
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Header struct {
	Profile            uint8
	ShowExistingFrame  bool
	FrameToShowMapIdx  uint8
	NonKeyFrame        bool
	ShowFrame          bool
	ErrorResilientMode bool
	ColorConfig        *Header_ColorConfig
	FrameSize          *Header_FrameSize
}

Header is a VP9 Frame header. Specification: https://storage.googleapis.com/downloads.webmproject.org/docs/vp9/vp9-bitstream-specification-v0.6-20160331-draft.pdf

func (Header) ChromaSubsampling

func (h Header) ChromaSubsampling() uint8

ChromaSubsampling returns the chroma subsampling format, in ISO-BMFF/vpcC format.

func (Header) Height

func (h Header) Height() int

Height returns the video height.

func (*Header) Unmarshal

func (h *Header) Unmarshal(buf []byte) error

Unmarshal decodes a Header.

func (Header) Width

func (h Header) Width() int

Width returns the video width.

type Header_ColorConfig

type Header_ColorConfig struct {
	TenOrTwelveBit bool
	BitDepth       uint8
	ColorSpace     uint8
	ColorRange     bool
	SubsamplingX   bool
	SubsamplingY   bool
}

Header_ColorConfig is the color_config member of an header.

type Header_FrameSize

type Header_FrameSize struct {
	FrameWidthMinus1  uint16
	FrameHeightMinus1 uint16
}

Header_FrameSize is the frame_size member of an header.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL