Documentation
¶
Index ¶
- Constants
- Variables
- func Backends() []string
- type DeblockMode
- type Decoder
- type DecoderConfig
- type DecoderLimits
- type DirectMode
- type Encoder
- func (e *Encoder) Backend() string
- func (e *Encoder) Close() error
- func (e *Encoder) Encode(i420 []byte) ([]byte, error)
- func (e *Encoder) EncodeFrame(f *Frame, changed []image.Rectangle, regions []Region) ([]byte, error)
- func (e *Encoder) EncodeWithHints(i420 []byte, changed []image.Rectangle, regions []Region) ([]byte, error)
- func (e *Encoder) Flush() ([]byte, error)
- func (e *Encoder) ForceKeyFrame()
- type EncoderConfig
- type Frame
- type ModeDecision
- type MotionSearch
- type Region
- type RegionKind
- type ScalingMatrix
- type WeightedPrediction
Constants ¶
View Source
const ( DeblockingOn = encoder.DeblockingOn DeblockingOff = encoder.DeblockingOff DeblockingNotAcrossSlices = encoder.DeblockingNotAcrossSlices )
View Source
const ( ScalingMatrixFlat = encoder.ScalingMatrixFlat ScalingMatrixJVT = encoder.ScalingMatrixJVT )
View Source
const ( MotionSearchFull = encoder.MotionSearchFull MotionSearchZero = encoder.MotionSearchZero )
View Source
const ( WeightedPredictionOff = encoder.WeightedPredictionOff WeightedPredictionExplicit = encoder.WeightedPredictionExplicit WeightedPredictionImplicit = encoder.WeightedPredictionImplicit )
View Source
const ( DirectSpatial = encoder.DirectSpatial DirectTemporal = encoder.DirectTemporal )
View Source
const ( ModeDecisionFast = encoder.ModeDecisionFast ModeDecisionExhaustive = encoder.ModeDecisionExhaustive )
View Source
const ( RegionUnknown = encoder.RegionUnknown RegionFill = encoder.RegionFill RegionText = encoder.RegionText RegionImage = encoder.RegionImage )
Variables ¶
View Source
var ErrClosed = errors.New("go264: use of a closed codec")
View Source
var ErrOverLimit = decoder.ErrOverLimit
Functions ¶
Types ¶
type DeblockMode ¶ added in v1.2.0
type DeblockMode = encoder.DeblockMode
type Decoder ¶
type Decoder struct {
// contains filtered or unexported fields
}
func NewDecoder ¶
func NewDecoder() *Decoder
func NewDecoderWithConfig ¶
func NewDecoderWithConfig(cfg DecoderConfig) *Decoder
type DecoderConfig ¶
type DecoderConfig struct {
ForceSoftware bool
Width int
Height int
Limits DecoderLimits
}
type DecoderLimits ¶ added in v1.6.0
type DirectMode ¶ added in v1.3.0
type DirectMode = encoder.DirectMode
type Encoder ¶
type Encoder struct {
// contains filtered or unexported fields
}
func NewEncoder ¶
func NewEncoder(cfg EncoderConfig) (*Encoder, error)
func (*Encoder) EncodeFrame ¶ added in v1.1.0
func (*Encoder) EncodeWithHints ¶ added in v1.2.0
func (*Encoder) ForceKeyFrame ¶ added in v1.1.0
func (e *Encoder) ForceKeyFrame()
type EncoderConfig ¶
type EncoderConfig struct {
Width int
Height int
FPSNum int
FPSDen int
GOPSize int
QP int
BitrateKbps int
RefFrames int
BFrames int
LongTermReferences int
CABAC bool
MotionSearch MotionSearch
ModeDecision ModeDecision
Slices int
Transform8x8 bool
ScalingMatrix ScalingMatrix
Trellis bool
ForceSoftware bool
WeightedPrediction WeightedPrediction
DirectMode DirectMode
IntraRefresh int
RepeatParameterSets bool
Deblocking DeblockMode
DeblockAlphaOffset int
DeblockBetaOffset int
VBVBufferKbits int
VBVMaxrateKbps int
CBR bool
}
type Frame ¶
func (*Frame) AppendI420 ¶
type ModeDecision ¶ added in v1.2.0
type ModeDecision = encoder.ModeDecision
type MotionSearch ¶ added in v1.1.0
type MotionSearch = encoder.MotionSearch
type RegionKind ¶ added in v1.1.0
type RegionKind = encoder.RegionKind
type ScalingMatrix ¶ added in v1.2.0
type ScalingMatrix = encoder.ScalingMatrix
type WeightedPrediction ¶ added in v1.3.0
type WeightedPrediction = encoder.WeightedPrediction
Click to show internal directories.
Click to hide internal directories.