Improve command preview button and reorganize format options
Command Preview Button: - Disabled when no video source is loaded - Shows "Show Preview" when preview is hidden - Shows "Hide Preview" when preview is visible - Makes it clear when and why the button can be used Format Options Reorganization: - Grouped formats by codec family for better readability - Order: H.264 → H.265 → AV1 → VP9 → ProRes → MPEG-2 - Added comments explaining each codec family - Makes it easier to find and compare similar codecs This improves discoverability and reduces user confusion about when the command preview is available and which format to choose.
This commit is contained in:
parent
82d4b19f94
commit
f209cc37ed
27
main.go
27
main.go
|
|
@ -417,16 +417,22 @@ type formatOption struct {
|
|||
}
|
||||
|
||||
var formatOptions = []formatOption{
|
||||
// H.264 - Widely compatible, older standard
|
||||
{"MP4 (H.264)", ".mp4", "libx264"},
|
||||
{"MP4 (H.265)", ".mp4", "libx265"},
|
||||
{"MP4 (AV1)", ".mp4", "libaom-av1"},
|
||||
{"MKV (H.265)", ".mkv", "libx265"},
|
||||
{"MKV (AV1)", ".mkv", "libaom-av1"},
|
||||
{"WebM (VP9)", ".webm", "libvpx-vp9"},
|
||||
{"WebM (AV1)", ".webm", "libaom-av1"},
|
||||
{"MOV (H.264)", ".mov", "libx264"},
|
||||
// H.265/HEVC - Better compression than H.264
|
||||
{"MP4 (H.265)", ".mp4", "libx265"},
|
||||
{"MKV (H.265)", ".mkv", "libx265"},
|
||||
{"MOV (H.265)", ".mov", "libx265"},
|
||||
// AV1 - Best compression, slower encode
|
||||
{"MP4 (AV1)", ".mp4", "libaom-av1"},
|
||||
{"MKV (AV1)", ".mkv", "libaom-av1"},
|
||||
{"WebM (AV1)", ".webm", "libaom-av1"},
|
||||
// VP9 - Google codec, good for web
|
||||
{"WebM (VP9)", ".webm", "libvpx-vp9"},
|
||||
// ProRes - Professional/editing codec
|
||||
{"MOV (ProRes)", ".mov", "prores_ks"},
|
||||
// MPEG-2 - DVD standard
|
||||
{"DVD-NTSC (MPEG-2)", ".mpg", "mpeg2video"},
|
||||
{"DVD-PAL (MPEG-2)", ".mpg", "mpeg2video"},
|
||||
}
|
||||
|
|
@ -5073,6 +5079,15 @@ func buildConvertView(state *appState, src *videoSource) fyne.CanvasObject {
|
|||
})
|
||||
cmdPreviewBtn.Importance = widget.LowImportance
|
||||
|
||||
// Update button text and state based on preview visibility and source
|
||||
if src == nil {
|
||||
cmdPreviewBtn.Disable()
|
||||
} else if state.convertCommandPreviewShow {
|
||||
cmdPreviewBtn.SetText("Hide Preview")
|
||||
} else {
|
||||
cmdPreviewBtn.SetText("Show Preview")
|
||||
}
|
||||
|
||||
backBar := ui.TintedBar(convertColor, container.NewHBox(back, layout.NewSpacer(), navButtons, layout.NewSpacer(), cmdPreviewBtn, queueBtn))
|
||||
|
||||
var updateCover func(string)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user