Documentation
¶
Index ¶
- func GetVideoDuration(inputFilePath string) (int64, error)
- func MakeDASH(inputFilePath string, outputFolderPath string, mpdFileName string) error
- func OtherToMP4(input string, output string) error
- type FFProbeCommander
- type FFmpeg
- func (f *FFmpeg) AddGlobalArgs(args ...string) *FFmpeg
- func (f *FFmpeg) AddInputInfo(inputFilePath string, args ...string) *FFmpeg
- func (f *FFmpeg) AddOutputInfo(outputFilePath string, args ...string) *FFmpeg
- func (f FFmpeg) BuildCommand() string
- func (f FFmpeg) Run() error
- func (f FFmpeg) RunCombinedOutput() ([]byte, error)
- func (f *FFmpeg) SetAudioCodec(outputFilePath string, codec string) *FFmpeg
- func (f *FFmpeg) SetCopyCodec(outputFilePath string) *FFmpeg
- func (f *FFmpeg) SetFormatDash(outputFilePath string) *FFmpeg
- func (f *FFmpeg) SetLogLevel(level string) *FFmpeg
- func (f *FFmpeg) SetSegmentTime(outputFilePath string, duration float64) *FFmpeg
- func (f *FFmpeg) SetVideoCodec(outputFilePath string, codec string) *FFmpeg
- func (f *FFmpeg) ShowCommand() *FFmpeg
- type FFmpegCommander
- type FFprobe
- func (f *FFprobe) AddGlobalArgs(args ...string) *FFprobe
- func (f *FFprobe) AddInputInfo(inputFilePath string, args ...string) *FFprobe
- func (f *FFprobe) AddOutputInfo(outputFilePath string, args ...string) *FFprobe
- func (f FFprobe) BuildCommand() string
- func (f FFprobe) Run() error
- func (f FFprobe) RunCombinedOutput() ([]byte, error)
- func (f *FFprobe) SetAudioCodec(outputFilePath string, codec string) *FFprobe
- func (f *FFprobe) SetLogLevel(level string) *FFprobe
- func (f *FFprobe) SetOutputFormat(inputFilePath string, outputFormat string) *FFprobe
- func (f *FFprobe) SetVideoCodec(outputFilePath string, codec string) *FFprobe
- func (f *FFprobe) ShowCommand() *FFprobe
- func (f *FFprobe) ShowEntries(inputFilePath string, entries ...string) *FFprobe
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetVideoDuration ¶
GetVideoDuration gets the duration of the video file. The duration is rounded off to the nearest integer in seconds.
func MakeDASH ¶
MakeDASH creates a DASH stream from an input file and saves it to an output folder. The input file should be .mp4 format. If the input file is not.mp4 format, it will be converted to.mp4 format first. If the fileName is not provided, the output file will be named "output.mpd" automatically.
func OtherToMP4 ¶
OtherToMP4 converts other video format to mp4 format using ffmpeg
Types ¶
type FFProbeCommander ¶
type FFmpeg ¶
type FFmpeg struct {
// contains filtered or unexported fields
}
func (*FFmpeg) AddGlobalArgs ¶
func (*FFmpeg) AddInputInfo ¶
func (*FFmpeg) AddOutputInfo ¶
func (FFmpeg) BuildCommand ¶
func (f FFmpeg) BuildCommand() string
func (FFmpeg) RunCombinedOutput ¶
func (*FFmpeg) SetAudioCodec ¶
func (*FFmpeg) SetCopyCodec ¶
func (*FFmpeg) SetFormatDash ¶
func (*FFmpeg) SetLogLevel ¶
func (*FFmpeg) SetSegmentTime ¶
func (*FFmpeg) SetVideoCodec ¶
func (*FFmpeg) ShowCommand ¶
type FFmpegCommander ¶
type FFprobe ¶
type FFprobe struct {
// contains filtered or unexported fields
}
func NewFFprobe ¶
func NewFFprobe() *FFprobe
func (*FFprobe) AddGlobalArgs ¶
func (*FFprobe) AddInputInfo ¶
func (*FFprobe) AddOutputInfo ¶
func (FFprobe) BuildCommand ¶
func (f FFprobe) BuildCommand() string
func (FFprobe) RunCombinedOutput ¶
func (*FFprobe) SetAudioCodec ¶
func (*FFprobe) SetLogLevel ¶
func (*FFprobe) SetOutputFormat ¶
func (*FFprobe) SetVideoCodec ¶
func (*FFprobe) ShowCommand ¶
Click to show internal directories.
Click to hide internal directories.