Documentation
¶
Overview ¶
cmd/convert.go
cmd/info.go
cmd/root.go
cmd/util.go
cmd/version.go
Index ¶
- func CheckFFmpeg() error
- func Execute()
- func GetLogger() *logrus.Logger
- func GetOptimalThreads() int
- func GetVideoInfo(videoPath string) (map[string]string, error)
- func HumanizeBytes(bytes int64) string
- func ValidateTimeFormat(timeStr string) bool
- type ConvertOptions
- type ProgressData
- type ProgressUpdate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckFFmpeg ¶
func CheckFFmpeg() error
CheckFFmpeg checks if FFmpeg is installed and returns an error if not
func GetOptimalThreads ¶
func GetOptimalThreads() int
GetOptimalThreads returns the optimal number of threads to use based on CPU cores
func GetVideoInfo ¶
GetVideoInfo uses FFmpeg to extract basic information about a video file
func HumanizeBytes ¶
HumanizeBytes converts bytes to a human-readable format (KB, MB, GB)
func ValidateTimeFormat ¶
ValidateTimeFormat checks if a time string is in the format HH:MM:SS or HH:MM:SS.MS
Types ¶
type ConvertOptions ¶
type ProgressData ¶
type ProgressData struct {
StartTime time.Time
CurrentTime float64
TotalDuration float64
ProcessingRate float64 // Ratio of processing speed to real-time
CurrentSize int64
SizeUnit string
Bitrate float64
BitrateUnit string
FramesProcessed int64
Width int
Height int
AvgProcessRate float64 // Average processing rate relative to real-time
Frames int
}
ProgressData tracks the current state of the conversion
type ProgressUpdate ¶
type ProgressUpdate struct {
CurrentTime float64
TotalDuration float64
ProcessingRate float64 // Speed relative to real-time playback
CurrentSize int64
SizeUnit string
Bitrate float64
BitrateUnit string
FramesProcessed int64
Width int
Height int
}
ProgressUpdate represents a progress update sent through the channel
Click to show internal directories.
Click to hide internal directories.