Documentation ¶
Index ¶
- type Exec
- func (e *Exec) ExecCtx(ctx context.Context, args ...string) error
- func (e *Exec) ExecCtxValue(ctx context.Context, loglevel Loglevel, args ...string) (string, error)
- func (e *Exec) GenerateVideoPreviewImg(ctx context.Context, videoFilePath, outputFilePath string) error
- func (e *Exec) GetResolution(ctx context.Context, input string) (image.Point, error)
- func (e *Exec) MergeImg2Video(ctx context.Context, imgDir, audioFile, outputFile string) error
- func (e *Exec) Overlay(ctx context.Context, isVideo bool, outputFile string, elementFile ...string) error
- func (e *Exec) Scale(ctx context.Context, input string, w, h int, output string) error
- func (e *Exec) VideoFrameExtraction(ctx context.Context, videoFile, outputDir string) error
- type Loglevel
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Exec ¶
type Exec struct { Loglevel Loglevel // contains filtered or unexported fields }
func (*Exec) ExecCtxValue ¶
func (*Exec) GenerateVideoPreviewImg ¶
func (e *Exec) GenerateVideoPreviewImg(ctx context.Context, videoFilePath, outputFilePath string) error
GenerateVideoPreviewImg 视频预览图
func (*Exec) GetResolution ¶
GetResolution 获取分辨率
func (*Exec) MergeImg2Video ¶
MergeImg2Video 合并图片成视频
func (*Exec) Overlay ¶
func (e *Exec) Overlay(ctx context.Context, isVideo bool, outputFile string, elementFile ...string) error
Overlay 视频叠加
type Loglevel ¶
type Loglevel int
const ( // LogLevelQuiet Show nothing at all; be silent. LogLevelQuiet Loglevel = -8 // LogLevelPanic Only show fatal errors which could lead the process to crash, such as an assertion failure. This is not currently used for anything. LogLevelPanic Loglevel = 0 // LogLevelFatal Only show fatal errors. These are errors after which the process absolutely cannot continue. LogLevelFatal Loglevel = 8 // LogLevelError Show all errors, including ones which can be recovered from. LogLevelError Loglevel = 16 // LogLevelWarning Show all warnings and errors. Any message related to possibly incorrect or unexpected events will be shown. LogLevelWarning Loglevel = 24 // LogLevelInfo Show informative messages during processing. This is in addition to warnings and errors. This is the default value. LogLevelInfo Loglevel = 32 // LogLevelVerbose Same as info, except more verbose. LogLevelVerbose Loglevel = 40 // LogLevelDebug Show everything, including debugging information. LogLevelDebug Loglevel = 48 LogLevelTrace Loglevel = 56 )
Click to show internal directories.
Click to hide internal directories.