Documentation
¶
Index ¶
- Constants
- type AdaptationSetXML
- type AudioChannelConfigurationXML
- type DASHConfig
- type DASHService
- func (dashService *DASHService) Add(name string, src *DASHSource) (err error)
- func (dashService *DASHService) Del(name, id string)
- func (dashService *DASHService) GetType() string
- func (dashService *DASHService) HandleTask(task wssapi.Task) (err error)
- func (dashService *DASHService) Init(msg *wssapi.Msg) (err error)
- func (dashService *DASHService) ProcessMessage(msg *wssapi.Msg) (err error)
- func (dashService *DASHService) ServeHTTP(w http.ResponseWriter, req *http.Request)
- func (dashService *DASHService) Start(msg *wssapi.Msg) (err error)
- func (dashService *DASHService) Stop(msg *wssapi.Msg) (err error)
- type DASHSource
- func (dashSource *DASHSource) GetType() string
- func (dashSource *DASHSource) HandleTask(task wssapi.Task) (err error)
- func (dashSource *DASHSource) Init(msg *wssapi.Msg) (err error)
- func (dashSource *DASHSource) ProcessMessage(msg *wssapi.Msg) (err error)
- func (dashSource *DASHSource) Start(msg *wssapi.Msg) (err error)
- func (dashSource *DASHSource) Stop(msg *wssapi.Msg) (err error)
- type FMP4Cache
- func (fmp4Cache *FMP4Cache) AudioHeaderGenerated(audioHeader []byte)
- func (fmp4Cache *FMP4Cache) AudioSegmentGenerated(audioSegment []byte, timestamp int64, duration int)
- func (fmp4Cache *FMP4Cache) GetAudioHeader() (data []byte, err error)
- func (fmp4Cache *FMP4Cache) GetAudioSegment(timestamp int64) (seg []byte, err error)
- func (fmp4Cache *FMP4Cache) GetVideoHeader() (data []byte, err error)
- func (fmp4Cache *FMP4Cache) GetVideoSegment(timestamp int64) (seg []byte, err error)
- func (fmp4Cache *FMP4Cache) VideoHeaderGenerated(videoHeader []byte)
- func (fmp4Cache *FMP4Cache) VideoSegmentGenerated(videoSegment []byte, timestamp int64, duration int)
- type MPD
- type PeriodXML
- type RepresentationXML
- type SegmentTemplateXML
- type SegmentTimelineDesc
- type SegmentTimelineXML
Constants ¶
View Source
const ( MpdPREFIX = "mpd" VideoPREFIX = "video" AudioPREFIX = "audio" )
http://addr/DASH/streamName/req
View Source
const ( ProfileFull = "urn:mpeg:dash:profile:full:2011" ProfileISOOnDemand = "urn:mpeg:dash:profile:isoff-on-demand:2011" ProfileISOMain = "urn:mpeg:dash:profile:isoff-main:2011" ProfileISOLive = "urn:mpeg:dash:profile:isoff-live:2011" ProfileTSMain = "urn:mpeg:dash:profile:mp2t-main:2011" ProfileTSSimple = "urn:mpeg:dash:profile:mp2t-simple:2011" MPDXMLNS = "urn:mpeg:dash:schema:mpd:2011" SchemeIdUri = "urn:mpeg:dash:23003:3:audio_channel_configuration:2011" )
const string for media description
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdaptationSetXML ¶
type AdaptationSetXML struct { Lang string `xml:"lang,attr,omitempty"` MimeType string `xml:"mimeType,attr"` Codecs string `xml:"codecs,attr,omitempty"` AudioChannelConfiguration *AudioChannelConfigurationXML `xml:"AudioChannelConfiguration,omitempty"` SegmentTemplate SegmentTemplateXML `xml:"SegmentTemplate"` Representation []RepresentationXML `xml:"Representation,omitempty"` }
type AudioChannelConfigurationXML ¶
type AudioChannelConfigurationXML struct { SchemeIdUri string `xml:"schemeIdUri,attr"` Value int `xml:"value,attr"` }
AudioChannelConfigurationXML file
type DASHConfig ¶
DASHConfig struc
type DASHService ¶
type DASHService struct {
// contains filtered or unexported fields
}
DASHService struct
func (*DASHService) Add ¶
func (dashService *DASHService) Add(name string, src *DASHSource) (err error)
func (*DASHService) Del ¶
func (dashService *DASHService) Del(name, id string)
func (*DASHService) GetType ¶
func (dashService *DASHService) GetType() string
func (*DASHService) HandleTask ¶
func (dashService *DASHService) HandleTask(task wssapi.Task) (err error)
func (*DASHService) ProcessMessage ¶
func (dashService *DASHService) ProcessMessage(msg *wssapi.Msg) (err error)
func (*DASHService) ServeHTTP ¶
func (dashService *DASHService) ServeHTTP(w http.ResponseWriter, req *http.Request)
type DASHSource ¶
type DASHSource struct {
// contains filtered or unexported fields
}
DASHSource description
func (*DASHSource) GetType ¶
func (dashSource *DASHSource) GetType() string
func (*DASHSource) HandleTask ¶
func (dashSource *DASHSource) HandleTask(task wssapi.Task) (err error)
func (*DASHSource) ProcessMessage ¶
func (dashSource *DASHSource) ProcessMessage(msg *wssapi.Msg) (err error)
type FMP4Cache ¶
type FMP4Cache struct {
// contains filtered or unexported fields
}
FMP4Cache description Struct
func NewFMP4Cache ¶
NewFMP4Cache to create new Cache
func (*FMP4Cache) AudioHeaderGenerated ¶
func (*FMP4Cache) AudioSegmentGenerated ¶
func (*FMP4Cache) GetAudioHeader ¶
func (*FMP4Cache) GetAudioSegment ¶
func (*FMP4Cache) GetVideoHeader ¶
func (*FMP4Cache) GetVideoSegment ¶
func (*FMP4Cache) VideoHeaderGenerated ¶
type MPD ¶
type MPD struct { ID string `xml:"id,attr"` Profiles string `xml:"profiles,attr"` Type string `xml:"type,attr"` AvailabilityStartTime string `xml:"availabilityStartTime,attr"` PublishTime string `xml:"publishTime,attr"` MediaPresentationDuration string `xml:"mediaPresentationDuration,attr,omitempty"` MinimumUpdatePeriod string `xml:"minimumUpdatePeriod,attr,omitempty"` MinBufferTime string `xml:"minBufferTime,attr"` Xmlns string `xml:"xmlns,attr"` Period []PeriodXML `xml:"Period"` }
MPD Struct
type PeriodXML ¶
type PeriodXML struct { ID string `xml:"id,attr"` AdaptationSet []AdaptationSetXML `xml:"AdaptationSet"` }
type RepresentationXML ¶
type RepresentationXML struct { ID string `xml:"id,attr"` Bandwidth string `xml:"bandwidth,attr"` Width string `xml:"width,attr,omitempty"` Height string `xml:"height,attr,omitempty"` FrameRate string `xml:"frameRate,attr,omitempty"` AudioSamplingRate string `xml:"audioSamplingRate,attr,omitempty"` }
RepresentationXML file
type SegmentTemplateXML ¶
type SegmentTemplateXML struct { Media string `xml:"media,attr"` Initialization string `xml:"initialization,attr"` Duration *int `xml:"duration,attr,omitempty"` StartNumber string `xml:"startNumber,attr"` TimeScale string `xml:"timescale,attr"` SegmentTimeline *SegmentTimelineXML `xml:"SegmentTimeline,omitempty"` }
type SegmentTimelineDesc ¶
type SegmentTimelineDesc struct { T string `xml:"t,attr,omitempty"` //time D string `xml:"d,attr"` //duration R string `xml:"r,attr,omitempty"` //repreat count default 0 }
SegmentTimelineDesc from file
type SegmentTimelineXML ¶
type SegmentTimelineXML struct {
S []SegmentTimelineDesc `xml:"S"`
}
SegmentTimelineXML from file
Click to show internal directories.
Click to hide internal directories.