Commit Graph

111 Commits

Author SHA1 Message Date
7a1d8fa910 Add merge chrome and guard NVENC runtime availability 2025-12-10 11:44:29 -05:00
bdc1afc367 Add 360p/480p/540p resolution presets 2025-12-09 16:14:15 -05:00
894f7ef4f5 Add initial Merge module with chapters and queue support 2025-12-09 16:10:23 -05:00
87fb9eb151 Clean up Logs menu and show log path 2025-12-09 14:34:39 -05:00
e6ec933793 Add 5:3 aspect option 2025-12-09 14:27:38 -05:00
1448c12ac8 Persist convert config and tidy queue UI 2025-12-09 13:24:39 -05:00
9ea55f955e Fix hardware fallback retry to keep build green 2025-12-09 13:13:03 -05:00
6208dcfe8c Handle HW fallback retry return 2025-12-09 12:09:12 -05:00
4b99fe8029 Refine HW fallback: retry convert once in software 2025-12-09 11:50:48 -05:00
075f363872 Retry hardware failures inline with software and avoid UI crash 2025-12-09 11:08:37 -05:00
f60b2a648b Auto-retry convert in software if hardware encoder fails 2025-12-09 02:08:09 -05:00
d333a922ec Force Source aspect unless user changes it; keep configs aligned 2025-12-09 02:06:06 -05:00
57cfcde707 Include FFmpeg stderr in snippet job errors 2025-12-09 01:50:10 -05:00
1e9c7fe0aa Queue snippets and honor user aspect; skip HW accel if unavailable 2025-12-09 01:33:05 -05:00
4515793f5e Force Source aspect default on snippets to prevent 16:9 drift 2025-12-09 01:28:33 -05:00
d6c4f5da29 Do not change aspect on snippets unless user explicitly sets it 2025-12-09 01:16:53 -05:00
d1ba052a6d Apply current convert settings to snippets (scale/aspect/fps/bitrate/preset) 2025-12-09 01:13:21 -05:00
50fe10d9b3 Fix config reload and inspect status ticker build errors 2025-12-09 00:40:52 -05:00
048c906321 Add config load/save, queue/status in inspect, keep aspect default 2025-12-09 00:16:56 -05:00
c9a377e041 Fallback to software when auto hardware accel fails 2025-12-09 00:06:51 -05:00
44795b6951 Show bitrate in kbps/Mbps and expand presets 2025-12-08 23:53:40 -05:00
aff598c8b5 Default hardware accel to auto with helper selection 2025-12-08 23:28:47 -05:00
35a90bdcd6 Add simple bitrate/resolution/aspect controls and cache helper 2025-12-08 23:22:28 -05:00
a35049a6d8 Fallback bitrate uses source bitrate; add size/bitrate delta helpers 2025-12-08 22:26:06 -05:00
9d53f7b795 Remove unused origBytes to fix Windows build 2025-12-08 20:51:29 -05:00
9271f32376 Remove unused origBytes placeholder in compare metadata 2025-12-08 20:48:05 -05:00
d49c75ebf5 Suppress unused variable warning in compare metadata 2025-12-08 20:45:28 -05:00
a61c75d477 Add default bitrate fallback for CBR and format family labeling 2025-12-08 20:36:37 -05:00
14d3959f4e Normalize MP4 format label, improve log readability, and prep reduction display 2025-12-08 18:46:34 -05:00
fed4139183 Shorten queue descriptions and wrap text to keep controls visible 2025-12-08 18:13:18 -05:00
8b75158923 Fix feedback bundler export and use utils.NewFeedbackBundler 2025-12-08 16:06:58 -05:00
e0f5c1fca3 Show app version and diagnostics in build scripts 2025-12-08 16:00:02 -05:00
03137bba29 Fix forward declarations for encoding/quality control helpers 2025-12-08 13:35:49 -05:00
2d0a865bc1 Group main menu by category and add logs access 2025-12-08 12:07:58 -05:00
c7690f7f61 Add log viewer buttons and live log refresh for conversions 2025-12-08 12:02:25 -05:00
8b872672f3 Move conversion logs to logs/ directory and surface logs in queue UI 2025-12-08 11:33:58 -05:00
6684052585 Add per-conversion logs and surface them in queue UI 2025-12-08 11:31:12 -05:00
cd71f39c53 Hide ffmpeg console windows on Windows and fix inspect clear button 2025-12-08 11:26:14 -05:00
c160bb2ea4 Add horizontal/vertical flip and rotation transformations to Convert module
Implements video transformation features:
- Horizontal flip (mirror effect) using hflip filter
- Vertical flip (upside down) using vflip filter
- Rotation support: 90°, 180°, 270° clockwise using transpose filters

UI additions in Advanced mode:
- New "VIDEO TRANSFORMATIONS" section
- Two checkboxes for flip controls with descriptive labels
- Dropdown selector for rotation angles
- Hint text explaining transformation purpose

Filter implementation:
- Applied after aspect ratio conversion, before frame rate conversion
- Works in both queue-based and direct conversion paths
- Uses FFmpeg standard filters: hflip, vflip, transpose

Addresses user request to add flip/rotation capabilities inspired by Jake's script using -vf hflip.
2025-12-06 01:18:38 -05:00
6e6e8f1c74 Add dev14 fixes: progress tracking, AMD AMF support, DVD resolution fix, and Windows build automation
This commit includes three critical bug fixes and Windows build improvements:

**Bug Fixes:**

1. **Queue Conversion Progress Tracking** (main.go:1471-1534)
   - Enhanced executeConvertJob() to parse FPS, speed, and ETA from FFmpeg output
   - Queue jobs now show detailed progress metrics matching direct conversions
   - Stats stored in job.Config for display in the conversion stats bar

2. **AMD AMF Hardware Acceleration** (main.go)
   - Added "amf" to hardware acceleration options
   - Support for h264_amf, hevc_amf, and av1_amf encoders
   - Added AMF-specific error detection in FFmpeg output parsing

3. **DVD Format Resolution Forcing** (main.go:1080-1103, 4504-4517)
   - Removed automatic resolution forcing when DVD format is selected
   - Removed -target parameter usage which was forcing 720×480/720×576
   - Resolution now defaults to "Source" unless explicitly changed
   - DVD compliance maintained through manual bitrate/GOP/codec parameters

**Windows Build Improvements:**

- Updated build.bat to enable CGO (required for Fyne/OpenGL)
- Added automatic GCC/MinGW-w64 detection and installation
- Automated setup via winget for one-command Windows builds
- Improved error messages with fallback manual instructions

**Documentation:**

- Added comprehensive Windows setup guides
- Created platform.go for future platform-specific code
- Updated .gitignore for Windows build artifacts

All changes tested and working. Ready for production use.
2025-12-04 17:11:15 -05:00
3c42edabe2 Add FPS counter, queue improvements, Compare fixes, and comprehensive documentation
Features:
- FPS counter in conversion status showing real-time encoding speed
- Job queue now displays FPS, encoding speed (e.g., "1.2x"), and ETA for running conversions
- Copy Comparison button exports side-by-side metadata comparison report
- Auto-compare checkbox in Convert module - automatically loads Compare view after conversion
- Convert Now properly adds job to queue and displays in Job Queue with live stats
- Module badge colors in job queue now match main menu tile colors
- Fixed fullscreen compare window sizing (reduced player dimensions to prevent overflow)

Bug Fixes:
- Fixed queue state management - only one job runs at a time (prevents multiple jobs showing "running")
- Fixed Compare module slot assignment - single video drops now fill empty slot instead of overwriting
- Fixed job queue scroll rubber banding (no longer jumps back to top)
- Enhanced crop detection validation for WMV/AVI formats with dimension clamping and bounds checking

Documentation:
- VT_Player integration notes with API requirements for keyframing and trim features
- LosslessCut feature analysis for Trim module inspiration
- Video metadata guide covering MP4/MKV custom fields and NFO generation
- Trim module design specification
- Compare fullscreen mode documentation
- Updated VIDEO_PLAYER_FORK.md to mark fork as completed

Technical Changes:
- Added state tracking for FPS, speed, and ETA (main.go:197-199)
- Enhanced queue processJobs() to check for running jobs before starting new ones
- Improved Compare module drag-and-drop logic with smart slot assignment (both code paths)
- Added deferred scroll position restoration to prevent UI jumping
- Job queue Config map now carries conversion stats for display
2025-12-04 07:35:48 -05:00
f9617b717b Add thumbnail generation and Clear All button to Compare
Fixed thumbnails not displaying:
- Added preview frame generation to Compare module
- Thumbnails now load asynchronously when videos are loaded
- Uses capturePreviewFrames() just like Convert module
- Thumbnails appear after brief generation delay

Added Clear All button:
- Positioned to the right of instructions text
- Clears both File 1 and File 2 slots
- Refreshes view to show empty state
- Low importance styling (not highlighted)

Layout improvements:
- Instructions row now uses Border layout
- Clear All button aligned to the right
- Clean, accessible button placement

Both videos now show thumbnails (240x135) automatically
when loaded, providing visual confirmation of loaded content.
2025-12-04 03:39:04 -05:00
542fafc2e1 Fix drag-and-drop to intelligently fill Compare slots
Fixed issue where dragging single videos would overwrite existing data:

Smart slot filling logic:
- Single video dropped: Fills first empty slot (File 1 then File 2)
- If both slots full: Shows dialog asking user to Clear first
- Multiple videos dropped: Fills both slots (replaces existing)

Behavior changes:
1. Drag first video → goes to slot 1
2. Drag second video → goes to slot 2
3. Drag third video → shows "Both Slots Full" message
4. Drag 2+ videos together → replaces both slots

User experience improvements:
- No more accidental overwrites when loading one at a time
- Clear feedback when slots are full
- Can now build comparison by dragging videos individually
- Or drag both at once to start fresh

Main menu drag-and-drop to Compare tile:
- Already working correctly
- Loads both videos sequentially then shows module
- No changes needed to that path

This makes the Compare workflow much more intuitive and prevents
losing loaded video data when adding the second video.
2025-12-04 03:03:19 -05:00
7e946db6a5 Fix Compare module race condition and add action buttons
Fixed critical bug where loading second video would overwrite first:
- Changed parallel goroutines to sequential loading
- Load file 1, then file 2, then refresh UI once
- Prevents race condition from multiple showCompareView() calls
- Both files now display correctly side by side

Added action buttons for each file:
- Copy Metadata button: Copies formatted metadata to clipboard
- Clear button: Removes video from slot and refreshes display
- Buttons arranged horizontally: Load | Copy | Clear
- Low importance styling for secondary actions

Changes to drag-and-drop handlers:
- Within Compare module: sequential loading, single refresh
- From main menu: already sequential, no changes needed
- Both paths now work correctly

This fixes the "second file overwrites first" issue and adds
the requested metadata copy and clear functionality.
2025-12-04 02:57:14 -05:00
63fc5d26a5 Make UI more flexible by reducing rigid minimum sizes
Fixed window resizing issues for better cross-platform behavior:

Convert module video pane:
- Reduced video pane minimum from 460x260 to 320x180
- Removed rigid MinSize on outer container (commented out)
- Removed rigid MinSize on image element
- Set stage minimum to 200x113 (reasonable 16:9 minimum)
- Video pane now scales down allowing smaller windows

Compare module:
- Reduced thumbnail minimum from 320x180 to 240x135
- Reduced metadata scroll minimum from 300x200 to 250x150
- More compact layout allows better window resizing

Benefits:
- Window can now shrink to fit smaller screens
- Better behavior on tiling window managers
- More flexible for cross-platform (Windows, macOS, Linux)
- Content scales intelligently instead of forcing window size

Note: Double-click titlebar maximize is a Fyne framework limitation.
Maximize via window controls or OS shortcuts (F11, Super+Up) works.
2025-12-04 01:48:22 -05:00
85a308b899 Center window on screen at startup
Added window centering to improve initial presentation:

- Call w.CenterOnScreen() after setting window size
- Window now opens centered rather than at OS default position
- Maintains existing resizing and maximization support

The window is already maximizable via SetFixedSize(false).
Users can maximize using OS window controls (double-click
titlebar, maximize button, or OS shortcuts like F11/Super+Up).
2025-12-04 01:42:31 -05:00
613328d17f Add smart filename truncation in Compare module
Prevents long filenames from manipulating window size:

- Truncate filenames longer than 35 characters
- Smart truncation preserves file extension
- Format: "long-filename-na...mp4" instead of wrapping
- Falls back to simple truncation for very long extensions
- Removed text wrapping from labels (no longer needed)

Examples:
- "my-very-long-video-filename.mp4" → "my-very-long-video-fi....mp4"
- "short.mp4" → "short.mp4" (unchanged)
- "filename.mkv" → kept as-is if under 35 chars

This ensures the Compare module labels stay compact and
predictable regardless of filename length.
2025-12-04 01:41:46 -05:00
1008b8a9df Fix Compare module layout to properly utilize window space
Resolved UI framing issues where metadata was crushed and not
taking available vertical space:

Layout improvements:
- Used container.NewBorder to make metadata areas expand properly
- Set minimum sizes for scroll containers (300x200)
- Removed outer VScroll - individual metadata areas now scroll
- Grid columns now properly fill available vertical space
- Instructions fixed at top, metadata expands to fill remaining space

Text wrapping fixes:
- Added fyne.TextWrapBreak to file labels
- Prevents long filenames from stretching the window horizontally
- Labels now wrap to multiple lines as needed

Architecture changes:
- Separated file headers (label + button) from content
- Each column uses Border layout: header at top, metadata fills center
- Metadata scroll containers have explicit minimum sizes
- Two-column grid properly distributes horizontal space

The layout now feels more modern with better space utilization
and smooth scrolling within the metadata panels.
2025-12-04 01:40:23 -05:00
00f328e010 Refactor Compare module with auto-loading and thumbnails
Major improvements to Compare module user experience:

- Auto-populate metadata when files are loaded (no Compare button needed)
- Show video thumbnails for both files (320x180)
- Support drag-and-drop onto Compare tile from main menu
- Load up to 2 videos when dropped on Compare tile
- Show dialog if more than 2 videos dropped
- Files loaded via drag show immediately with metadata

Changes to handleModuleDrop:
- Added special handling for Compare module
- Loads videos into compareFile1 and compareFile2 state
- Shows module with files already populated

Changes to buildCompareView:
- Added thumbnail display with dark background placeholders
- Created helper functions: formatMetadata(), loadThumbnail(), updateFile1(), updateFile2()
- Initialize view with any preloaded files
- Removed manual Compare button - metadata shows automatically
- Button handlers now call update functions to refresh display
- Cleaner, more intuitive workflow

This addresses the user feedback that dragging videos onto Compare
didn't load the module, and adds the requested thumbnail previews.
2025-12-04 01:39:32 -05:00
21719a9b89 Add colored header and footer bars to Compare module
The Compare module now has colored bars at the top and bottom matching
its pink visual identity from the main menu. This creates visual
consistency with the Convert module and strengthens the app's
overall design language.

Changes:
- Added top bar with back button using ui.TintedBar
- Added bottom bar with module color
- Restructured layout to use container.NewBorder
- Made content area scrollable

The colored bars use the module's color (#FF44AA pink) as defined
in modulesList and retrieved via moduleColor().
2025-12-04 01:03:11 -05:00