Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
DefaultConfig = NewFfmpegConfig("./hls_output", nil)
)
Functions ¶
func ResolutionCmd ¶
Types ¶
type Ffmpeg ¶
type Ffmpeg struct {
// contains filtered or unexported fields
}
func NewFfmpeg ¶
func NewFfmpeg(serviceContext srvctx.ServiceContext) *Ffmpeg
func (*Ffmpeg) NewStream ¶
func (f *Ffmpeg) NewStream(streamId, serverUrl, streamKey string, fps, resolution int) (closeFunc func() error)
NewStream initializes and runs a Ffmpeg process to create an HLS stream with the specified parameters.
func (*Ffmpeg) StopStream ¶
func (*Ffmpeg) WithConfig ¶
func (f *Ffmpeg) WithConfig(config *FfmpegConfig) *Ffmpeg
type FfmpegConfig ¶
type FfmpegConfig struct {
// contains filtered or unexported fields
}
func NewFfmpegConfig ¶
func NewFfmpegConfig(mountFolder string, rd *redis.Client) *FfmpegConfig
type FpsBitRate ¶
type ResolutionInfo ¶
type ResolutionInfo struct {
Width int `json:"width"`
Height int `json:"height"`
Fps map[string]FpsBitRate `json:"fps"`
}
Click to show internal directories.
Click to hide internal directories.