Run gofmt on main.go for consistent formatting
Applied gofmt to fix code alignment and formatting consistency. Changes are purely cosmetic (whitespace/alignment).
This commit is contained in:
parent
d704604a99
commit
fd77671c5f
132
main.go
132
main.go
|
|
@ -82,18 +82,18 @@ var (
|
||||||
nvencRuntimeOK bool
|
nvencRuntimeOK bool
|
||||||
|
|
||||||
modulesList = []Module{
|
modulesList = []Module{
|
||||||
{"convert", "Convert", utils.MustHex("#8B44FF"), "Convert", modules.HandleConvert}, // Violet
|
{"convert", "Convert", utils.MustHex("#8B44FF"), "Convert", modules.HandleConvert}, // Violet
|
||||||
{"merge", "Merge", utils.MustHex("#4488FF"), "Convert", modules.HandleMerge}, // Blue
|
{"merge", "Merge", utils.MustHex("#4488FF"), "Convert", modules.HandleMerge}, // Blue
|
||||||
{"trim", "Trim", utils.MustHex("#44DDFF"), "Convert", modules.HandleTrim}, // Cyan
|
{"trim", "Trim", utils.MustHex("#44DDFF"), "Convert", modules.HandleTrim}, // Cyan
|
||||||
{"filters", "Filters", utils.MustHex("#44FF88"), "Convert", modules.HandleFilters}, // Green
|
{"filters", "Filters", utils.MustHex("#44FF88"), "Convert", modules.HandleFilters}, // Green
|
||||||
{"upscale", "Upscale", utils.MustHex("#AAFF44"), "Advanced", modules.HandleUpscale}, // Yellow-Green
|
{"upscale", "Upscale", utils.MustHex("#AAFF44"), "Advanced", modules.HandleUpscale}, // Yellow-Green
|
||||||
{"audio", "Audio", utils.MustHex("#FFD744"), "Convert", modules.HandleAudio}, // Yellow
|
{"audio", "Audio", utils.MustHex("#FFD744"), "Convert", modules.HandleAudio}, // Yellow
|
||||||
{"dvd-author", "DVD Author", utils.MustHex("#FFAA44"), "Convert", modules.HandleDVDAuthor}, // Orange
|
{"dvd-author", "DVD Author", utils.MustHex("#FFAA44"), "Convert", modules.HandleDVDAuthor}, // Orange
|
||||||
{"subtitles", "Subtitles", utils.MustHex("#44A6FF"), "Convert", modules.HandleSubtitles}, // Azure
|
{"subtitles", "Subtitles", utils.MustHex("#44A6FF"), "Convert", modules.HandleSubtitles}, // Azure
|
||||||
{"thumb", "Thumb", utils.MustHex("#FF8844"), "Screenshots", modules.HandleThumb}, // Orange
|
{"thumb", "Thumb", utils.MustHex("#FF8844"), "Screenshots", modules.HandleThumb}, // Orange
|
||||||
{"compare", "Compare", utils.MustHex("#FF44AA"), "Inspect", modules.HandleCompare}, // Pink
|
{"compare", "Compare", utils.MustHex("#FF44AA"), "Inspect", modules.HandleCompare}, // Pink
|
||||||
{"inspect", "Inspect", utils.MustHex("#FF4444"), "Inspect", modules.HandleInspect}, // Red
|
{"inspect", "Inspect", utils.MustHex("#FF4444"), "Inspect", modules.HandleInspect}, // Red
|
||||||
{"player", "Player", utils.MustHex("#44FFDD"), "Playback", modules.HandlePlayer}, // Teal
|
{"player", "Player", utils.MustHex("#44FFDD"), "Playback", modules.HandlePlayer}, // Teal
|
||||||
}
|
}
|
||||||
|
|
||||||
// Platform-specific configuration
|
// Platform-specific configuration
|
||||||
|
|
@ -488,7 +488,7 @@ type convertConfig struct {
|
||||||
CoverArtPath string
|
CoverArtPath string
|
||||||
AspectHandling string
|
AspectHandling string
|
||||||
OutputAspect string
|
OutputAspect string
|
||||||
AspectUserSet bool // Tracks if user explicitly set OutputAspect
|
AspectUserSet bool // Tracks if user explicitly set OutputAspect
|
||||||
TempDir string // Optional temp/cache directory override
|
TempDir string // Optional temp/cache directory override
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -790,17 +790,17 @@ type appState struct {
|
||||||
playerFile *videoSource
|
playerFile *videoSource
|
||||||
|
|
||||||
// Filters module state
|
// Filters module state
|
||||||
filtersFile *videoSource
|
filtersFile *videoSource
|
||||||
filterBrightness float64
|
filterBrightness float64
|
||||||
filterContrast float64
|
filterContrast float64
|
||||||
filterSaturation float64
|
filterSaturation float64
|
||||||
filterSharpness float64
|
filterSharpness float64
|
||||||
filterDenoise float64
|
filterDenoise float64
|
||||||
filterRotation int // 0, 90, 180, 270
|
filterRotation int // 0, 90, 180, 270
|
||||||
filterFlipH bool
|
filterFlipH bool
|
||||||
filterFlipV bool
|
filterFlipV bool
|
||||||
filterGrayscale bool
|
filterGrayscale bool
|
||||||
filterActiveChain []string // Active filter chain
|
filterActiveChain []string // Active filter chain
|
||||||
filterInterpEnabled bool
|
filterInterpEnabled bool
|
||||||
filterInterpPreset string
|
filterInterpPreset string
|
||||||
filterInterpFPS string
|
filterInterpFPS string
|
||||||
|
|
@ -1431,7 +1431,7 @@ func (s *appState) showMainMenu() {
|
||||||
Label: m.Label,
|
Label: m.Label,
|
||||||
Color: m.Color,
|
Color: m.Color,
|
||||||
Category: m.Category,
|
Category: m.Category,
|
||||||
Enabled: m.ID == "convert" || m.ID == "compare" || m.ID == "inspect" || m.ID == "merge" || m.ID == "thumb" || m.ID == "player" || m.ID == "filters" || m.ID == "upscale", // Enabled modules (authoring/subtitles placeholders stay disabled)
|
Enabled: m.ID == "convert" || m.ID == "compare" || m.ID == "inspect" || m.ID == "merge" || m.ID == "thumb" || m.ID == "player" || m.ID == "filters" || m.ID == "upscale", // Enabled modules (authoring/subtitles placeholders stay disabled)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11218,24 +11218,24 @@ func capturePreviewFrames(path string, duration float64) ([]string, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type videoSource struct {
|
type videoSource struct {
|
||||||
Path string
|
Path string
|
||||||
DisplayName string
|
DisplayName string
|
||||||
Format string
|
Format string
|
||||||
Width int
|
Width int
|
||||||
Height int
|
Height int
|
||||||
Duration float64
|
Duration float64
|
||||||
VideoCodec string
|
VideoCodec string
|
||||||
AudioCodec string
|
AudioCodec string
|
||||||
Bitrate int // Video bitrate in bits per second
|
Bitrate int // Video bitrate in bits per second
|
||||||
AudioBitrate int // Audio bitrate in bits per second
|
AudioBitrate int // Audio bitrate in bits per second
|
||||||
AudioBitrateEstimated bool
|
AudioBitrateEstimated bool
|
||||||
FrameRate float64
|
FrameRate float64
|
||||||
PixelFormat string
|
PixelFormat string
|
||||||
AudioRate int
|
AudioRate int
|
||||||
Channels int
|
Channels int
|
||||||
FieldOrder string
|
FieldOrder string
|
||||||
PreviewFrames []string
|
PreviewFrames []string
|
||||||
EmbeddedCoverArt string // Path to extracted embedded cover art, if any
|
EmbeddedCoverArt string // Path to extracted embedded cover art, if any
|
||||||
|
|
||||||
// Advanced metadata
|
// Advanced metadata
|
||||||
SampleAspectRatio string // Pixel Aspect Ratio (SAR) - e.g., "1:1", "40:33"
|
SampleAspectRatio string // Pixel Aspect Ratio (SAR) - e.g., "1:1", "40:33"
|
||||||
|
|
@ -11331,18 +11331,18 @@ func probeVideo(path string) (*videoSource, error) {
|
||||||
Tags map[string]interface{} `json:"tags"`
|
Tags map[string]interface{} `json:"tags"`
|
||||||
} `json:"format"`
|
} `json:"format"`
|
||||||
Streams []struct {
|
Streams []struct {
|
||||||
Index int `json:"index"`
|
Index int `json:"index"`
|
||||||
CodecType string `json:"codec_type"`
|
CodecType string `json:"codec_type"`
|
||||||
CodecName string `json:"codec_name"`
|
CodecName string `json:"codec_name"`
|
||||||
Width int `json:"width"`
|
Width int `json:"width"`
|
||||||
Height int `json:"height"`
|
Height int `json:"height"`
|
||||||
Duration string `json:"duration"`
|
Duration string `json:"duration"`
|
||||||
BitRate string `json:"bit_rate"`
|
BitRate string `json:"bit_rate"`
|
||||||
PixFmt string `json:"pix_fmt"`
|
PixFmt string `json:"pix_fmt"`
|
||||||
SampleRate string `json:"sample_rate"`
|
SampleRate string `json:"sample_rate"`
|
||||||
Channels int `json:"channels"`
|
Channels int `json:"channels"`
|
||||||
AvgFrameRate string `json:"avg_frame_rate"`
|
AvgFrameRate string `json:"avg_frame_rate"`
|
||||||
FieldOrder string `json:"field_order"`
|
FieldOrder string `json:"field_order"`
|
||||||
Tags map[string]interface{} `json:"tags"`
|
Tags map[string]interface{} `json:"tags"`
|
||||||
Disposition struct {
|
Disposition struct {
|
||||||
AttachedPic int `json:"attached_pic"`
|
AttachedPic int `json:"attached_pic"`
|
||||||
|
|
@ -13638,22 +13638,22 @@ func buildUpscaleView(state *appState) fyne.CanvasObject {
|
||||||
"aiBackend": state.upscaleAIBackend,
|
"aiBackend": state.upscaleAIBackend,
|
||||||
"aiPreset": state.upscaleAIPreset,
|
"aiPreset": state.upscaleAIPreset,
|
||||||
"aiScale": state.upscaleAIScale,
|
"aiScale": state.upscaleAIScale,
|
||||||
"aiScaleUseTarget": state.upscaleAIScaleUseTarget,
|
"aiScaleUseTarget": state.upscaleAIScaleUseTarget,
|
||||||
"aiOutputAdjust": state.upscaleAIOutputAdjust,
|
"aiOutputAdjust": state.upscaleAIOutputAdjust,
|
||||||
"aiFaceEnhance": state.upscaleAIFaceEnhance,
|
"aiFaceEnhance": state.upscaleAIFaceEnhance,
|
||||||
"aiDenoise": state.upscaleAIDenoise,
|
"aiDenoise": state.upscaleAIDenoise,
|
||||||
"aiTile": float64(state.upscaleAITile),
|
"aiTile": float64(state.upscaleAITile),
|
||||||
"aiGPU": float64(state.upscaleAIGPU),
|
"aiGPU": float64(state.upscaleAIGPU),
|
||||||
"aiGPUAuto": state.upscaleAIGPUAuto,
|
"aiGPUAuto": state.upscaleAIGPUAuto,
|
||||||
"aiThreadsLoad": float64(state.upscaleAIThreadsLoad),
|
"aiThreadsLoad": float64(state.upscaleAIThreadsLoad),
|
||||||
"aiThreadsProc": float64(state.upscaleAIThreadsProc),
|
"aiThreadsProc": float64(state.upscaleAIThreadsProc),
|
||||||
"aiThreadsSave": float64(state.upscaleAIThreadsSave),
|
"aiThreadsSave": float64(state.upscaleAIThreadsSave),
|
||||||
"aiTTA": state.upscaleAITTA,
|
"aiTTA": state.upscaleAITTA,
|
||||||
"aiOutputFormat": state.upscaleAIOutputFormat,
|
"aiOutputFormat": state.upscaleAIOutputFormat,
|
||||||
"applyFilters": state.upscaleApplyFilters,
|
"applyFilters": state.upscaleApplyFilters,
|
||||||
"filterChain": state.upscaleFilterChain,
|
"filterChain": state.upscaleFilterChain,
|
||||||
"duration": state.upscaleFile.Duration,
|
"duration": state.upscaleFile.Duration,
|
||||||
"sourceFrameRate": state.upscaleFile.FrameRate,
|
"sourceFrameRate": state.upscaleFile.FrameRate,
|
||||||
"frameRate": state.upscaleFrameRate,
|
"frameRate": state.upscaleFrameRate,
|
||||||
"useMotionInterpolation": state.upscaleMotionInterpolation,
|
"useMotionInterpolation": state.upscaleMotionInterpolation,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user