github.com/bluenviron/mediacommon@v1.9.3/pkg/formats/mpegts/codec_h265.go (about)

     1  package mpegts
     2  
     3  import (
     4  	"github.com/asticode/go-astits"
     5  )
     6  
     7  // CodecH265 is a H265 codec.
     8  type CodecH265 struct{}
     9  
    10  // IsVideo implements Codec.
    11  func (CodecH265) IsVideo() bool {
    12  	return true
    13  }
    14  
    15  func (*CodecH265) isCodec() {}
    16  
    17  func (c CodecH265) marshal(pid uint16) (*astits.PMTElementaryStream, error) {
    18  	return &astits.PMTElementaryStream{
    19  		ElementaryPID: pid,
    20  		StreamType:    astits.StreamTypeH265Video,
    21  	}, nil
    22  }