diff --git a/hevc/hevcdecoderconfigurationrecord.go b/hevc/hevcdecoderconfigurationrecord.go index 9ddf1008..c25c912f 100644 --- a/hevc/hevcdecoderconfigurationrecord.go +++ b/hevc/hevcdecoderconfigurationrecord.go @@ -34,11 +34,13 @@ type HEVCDecConfRec struct { NaluArrays []NaluArray } +// NaluArray - HEVC NALU array including complete bit and type type NaluArray struct { completeAndType byte Nalus [][]byte } +// NewNaluArray - create an HEVC NaluArray func NewNaluArray(complete bool, naluType NaluType, nalus [][]byte) *NaluArray { var completeBit byte if complete { @@ -50,10 +52,12 @@ func NewNaluArray(complete bool, naluType NaluType, nalus [][]byte) *NaluArray { } } +// NaluType - return NaluType for NaluArray func (n *NaluArray) NaluType() NaluType { return NaluType(n.completeAndType & 0x3f) } +// Complete - return 0x1 if complete func (n *NaluArray) Complete() byte { return n.completeAndType >> 7 } diff --git a/mp4/hvcc.go b/mp4/hvcc.go index 4629d955..84cf8566 100644 --- a/mp4/hvcc.go +++ b/mp4/hvcc.go @@ -53,6 +53,7 @@ func (b *HvcCBox) Encode(w io.Writer) error { return b.HEVCDecConfRec.Encode(w) } +// Info - box-specific Info func (b *HvcCBox) Info(w io.Writer, specificBoxLevels, indent, indentStep string) error { bd := newInfoDumper(w, indent, b, -1) hdcr := b.HEVCDecConfRec