Commit Graph

78 Commits

Author SHA1 Message Date
4e8486a5da fix(ui): Prevent queue items from jumping during updates
- Changed text wrapping from TextWrapWord to TextTruncate on desc/status labels
- Set fixed minimum height (140px) for job item cards
- Prevents height fluctuations when status text changes
- Resolves janky jumping behavior in job queue

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 02:31:57 -05:00
e0fc69ab97 feat(ui): Add distinct color for Remux format
- Added ColorRemux (#06B6D4 cyan-glow) to semantic color system
- Remux formats now display with distinct color from regular MKV
- buildFormatBadge checks for "Remux" in label and applies special color
- Differentiates lossless remux from transcoded formats

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 02:29:54 -05:00
62425537c1 Add semantic color system for containers and codecs
Implements professional color taxonomy based on NLE/broadcast conventions:
- Container colors (MKV teal, MP4 blue, MOV indigo, etc.)
- Video codec colors (AV1 emerald, HEVC lime, H.264 sky blue, etc.)
- Audio codec colors (Opus violet, AAC purple, FLAC magenta, etc.)
- Pixel format colors (yuv420p slate, HDR cyan, etc.)

Helper functions to retrieve colors by format/codec name.
Foundation for color-coded UI badges in Convert module.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 01:34:06 -05:00
da49a1dd7b fix(queue): Prevent massive goroutine leak from StripedProgress animations
Critical Fix:
- Goroutine dump showed hundreds of leaked animation goroutines
- Each queue refresh created NEW progress bars without stopping old ones
- Animation goroutines continued running forever, consuming resources

Root Cause:
- BuildQueueView() creates new StripedProgress widgets on every refresh
- StartAnimation() spawned goroutines for running jobs
- Old widgets were discarded but goroutines never stopped
- Fyne's Destroy() method not reliably called when rebuilding view

Solution:
- Track all active StripedProgress widgets in appState.queueActiveProgress
- Stop ALL animations before rebuilding queue view
- Stop ALL animations when leaving queue view (stopQueueAutoRefresh)
- BuildQueueView now returns list of active progress bars
- Prevents hundreds of leaked goroutines from accumulating

Implementation:
- Added queueActiveProgress []*ui.StripedProgress to appState
- Modified BuildQueueView signature to return progress list
- Stop old animations in refreshQueueView() before calling BuildQueueView
- Stop all animations in stopQueueAutoRefresh() when navigating away
- Track running job progress bars and append to activeProgress slice

Files Changed:
- main.go: appState field, refreshQueueView(), stopQueueAutoRefresh()
- internal/ui/queueview.go: BuildQueueView(), buildJobItem()

Impact:
- Eliminates goroutine leak that caused resource exhaustion
- Clean shutdown of animation goroutines on refresh and navigation
- Should dramatically reduce memory usage and CPU overhead

Reported-by: User (goroutine dump showing 900+ leaked goroutines)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-28 19:24:17 -05:00
b3e448f2fe feat(ui): Rebalance color palette to proper rainbow distribution
Rainbow Distribution (ROYGBIV - 2 modules per color):
- RED (2): Inspect (#F44336), Compare (#E91E63 Pink)
- ORANGE (2): Author (#FF5722), Rip (#FF9800)
- YELLOW (2): Audio (#FFC107 Amber), Trim (#FFEB3B)
- GREEN (2): Merge (#4CAF50), Subtitles (#8BC34A Light Green)
- CYAN (2): Filters (#00BCD4), Thumb (#00ACC1 Dark Cyan)
- BLUE (2): Blu-Ray (#2196F3), Player (#3F51B5 Indigo)
- PURPLE (2): Convert (#673AB7 Deep Purple), Upscale (#9C27B0)

Fixed Issues:
- Previous Memphis palette had 9 blue-ish modules (too much blue)
- User requested balanced rainbow spectrum across all modules
- Perfect distribution: 14 modules ÷ 7 colors = 2 per color
- Convert module back to deep purple (user preference)

Files Updated:
- main.go: Module color definitions
- internal/ui/queueview.go: Queue job type colors
- internal/ui/components.go: Badge colors

Tested: Build successful (v0.1.0-dev20)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-28 18:29:55 -05:00
1546b5f5d1 feat(ui): Implement Memphis Style color palette with section navigation
Memphis Color Palette:
- Complete redesign of 14 module colors inspired by Memphis design
- Eliminated orange overload (4 modules → 1 amber, distributed palette)
- Balanced color wheel distribution: Turquoise, Purple, Blue, Cyan, Green, Yellow, Pink, Red
- All colors WCAG compliant for light text contrast
- Memphis aesthetic: bold, vibrant, geometric, highly navigable

New Colors:
- Convert: #00CED1 Turquoise (Memphis primary)
- Upscale: #A855F7 Purple (AI/tech, was harsh lime green)
- Audio: #FBBF24 Warm Yellow (was too bright)
- Author: #EC4899 Hot Pink (Memphis creative)
- Rip: #F59E0B Amber (distinct from Author)
- Merge: #4ECDC4 Medium Turquoise
- Trim: #5DADE2 Sky Blue
- Filters: #8B5CF6 Vivid Violet
- Blu-Ray: #3B82F6 Royal Blue
- Subtitles: #10B981 Emerald Green
- Thumb: #06B6D4 Cyan
- Compare: #F43F5E Rose Red
- Inspect: #EF4444 Red
- Player: #6366F1 Indigo

Section Navigation Components (Jake's usability feedback):
- Add SectionHeader() with color-coded accent bars
- Add SectionSpacer() for visual breathing room (12px)
- Add ColoredDivider() for geometric separation
- Fixes issue where settings sections blend together

Files Updated:
- main.go: Module color definitions
- internal/ui/queueview.go: Queue job type colors
- internal/ui/components.go: Section helpers + badge colors

Reported-by: Jake (usability - sections too similar)
Reported-by: Stu (color visibility issues)
Inspired-by: Memphis interior design reference

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-28 16:43:48 -05:00
c4db2f9c56 fix(ui): Improve module color contrast for better text visibility
Color Changes (Module Buttons & Queue):
- Upscale: #AAFF44 → #7AB800 (darker green for better contrast)
- Audio: #FFD744 → #FFB700 (darker amber for better contrast)
- Author: #FFAA44 → #FF9944 (consolidated with existing orange palette)
- Rip: #FF9944 → #FF8844 (adjusted to differentiate from Author)
- Thumb: #FF8844 → #FF7733 (darker orange for better contrast)

Issue: Bright lime green (#AAFF44) and bright yellow (#FFD744) had
poor contrast with light text (#E1EEFF), making them hard to read,
especially on the Upscale module.

Solution: Darkened problematic colors while maintaining visual
distinction between modules. New colors meet WCAG contrast guidelines
for better accessibility.

Files Updated:
- main.go: Module color definitions
- internal/ui/queueview.go: Queue job type colors
- internal/ui/components.go: Badge colors for consistency

Reported-by: Stu
Tested-on: Linux

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-28 16:31:17 -05:00
02c2e389e0 perf(queue): Fix Windows button lag and optimize UI performance
Queue View Improvements:
- Fix Windows-specific button lag after conversion completion
- Remove redundant refreshQueueView() calls in button handlers
- Queue onChange callback now handles all refreshes automatically
- Add stopQueueAutoRefresh() before navigation to prevent conflicts
- Reduce auto-refresh interval from 500ms to 1000ms
- Result: Instant button response (was 1-3 second lag on Windows)

Main Menu Performance:
- Implement 300ms throttling for main menu rebuilds
- Cache jobQueue.List() to eliminate multiple expensive copies
- Smart conditional refresh: only update when history actually changes
- Add refreshMainMenuThrottled() and refreshMainMenuSidebar()
- Result: 3-5x improvement in responsiveness, especially on Windows

Queue Position Display:
- Fix confusing priority labeling in queue view
- Change from internal priority (3,2,1) to user-friendly positions (1,2,3)
- Display "Queue Position: 1" for first job, "Position: 2" for second, etc.
- Apply to both Pending and Paused jobs

Remux Safety System:
- Add comprehensive codec compatibility validation before remux
- Validate container/codec compatibility (MP4, MKV, WebM, MOV)
- Auto-detect and block incompatible combinations (VP9→MP4, etc.)
- Automatic fallback to re-encoding for WMV/ASF and legacy FLV
- Auto-fix timestamp issues for AVI, MPEG-TS, VOB with genpts
- Add enhanced FFmpeg safety flags for all remux operations:
  * -fflags +genpts (regenerate timestamps)
  * -avoid_negative_ts make_zero (fix negative timestamps)
  * -map 0 (preserve all streams)
  * -map_chapters 0 (preserve chapters)
- Add codec name normalization for accurate validation
- Result: Fool-proof remuxing with zero risk of corruption

Technical Changes:
- Add validateRemuxCompatibility() function
- Add normalizeCodecName() function
- Add mainMenuLastRefresh throttling field
- Optimize queue list caching in showMainMenu()
- Windows-optimized rendering pipeline

Reported-by: Jake (Windows button lag)
Reported-by: Stu (main menu lag)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-28 06:31:16 -05:00
49e01f5817 Fix DVD authoring SCR errors and queue animation persistence
DVD Authoring Fix:
- Add remultiplex step after MPEG encoding for DVD compliance
- Use ffmpeg -fflags +genpts -c copy -f dvd to fix timestamps
- Resolves "ERR: SCR moves backwards" error from dvdauthor
- FFmpeg direct encoding doesn't always create DVD-compliant streams
- Remux regenerates presentation timestamps correctly

Queue Animation Fix:
- Stop stripe animation on completed jobs
- Bug: Refresh() was always incrementing offset regardless of state
- Now only increments offset when animStop != nil (animation running)
- Completed/failed/cancelled jobs no longer show animated stripes

Testing:
- DVD authoring should now succeed on AVI files
- Completed queue jobs should show static progress bar

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-25 21:20:14 -05:00
834d6b5517 Stop queue animation on completion 2025-12-24 02:57:54 -05:00
e896fd086d Fix merge badge color 2025-12-24 01:42:57 -05:00
30bc747f0c Make main menu vertically resizable 2025-12-24 00:30:18 -05:00
a7bffb63ee Group DVD modules and add responsive menu 2025-12-24 00:08:56 -05:00
01af1b8cf2 Fix build blockers and continue refactoring
- Fixed Fyne API issue: app.Driver() → fyne.CurrentApp().Driver()
- Fixed unused import: removed strconv from upscale_module.go
- Build now passes successfully 
- Ready to continue module extraction

Current progress:
 filters_module.go (257 lines)
 thumb_module.go (406 lines)
 upscale_module.go partial (173 lines + showUpscaleView + AI helpers)
📊 main.go reduced by ~800+ lines
2025-12-23 23:50:51 -05:00
c8bcaf476c Fix queue UI refresh 2025-12-23 22:42:45 -05:00
e5dcde953b Commit incremental progress
- Current state: 3 modules partially/fully extracted
- upscale_module.go: showUpscaleView + AI helpers migrated successfully
- Build syntax:  Clean
- Build failing due to unrelated Fyne API issue in internal/ui/queueview.go
- Ready for next incremental extraction steps
2025-12-23 22:39:33 -05:00
cf9422ad6b Format cleanup and minor fixes
- Apply go formatting across internal packages
- Clean up imports and code style
2025-12-23 21:56:47 -05:00
a42b353aea Label author/rip jobs in queue 2025-12-23 21:30:56 -05:00
4d031a4dae Polish menu header and Windows DVDStyler download 2025-12-23 18:30:35 -05:00
93ec8c7b15 Fix queue buttons, log viewer hang, and Windows console flashing
Queue UI:
- Fix pending job button labels - now shows "Remove" instead of "Cancel"
- Running/paused jobs still correctly show "Cancel" button

Log Viewer:
- Fix app hanging when viewing large conversion logs
- Make file reads asynchronous to prevent blocking UI thread
- Show "Loading log file..." message while reading
- Auto-scroll to bottom when log opens

Windows Console Flashing:
- Add ApplyNoWindow to all missing exec.Command calls
- Fixes command prompt windows flashing during module operations
- Applied to: hwaccel detection, encoder checks, Python backend detection
- Prevents console windows from appearing during upscale module usage

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-21 15:59:30 -05:00
c1ccb38062 Improve preset UX and finalize 800x600 UI scaling
UI Scaling Improvements:
- Reduce module tiles from 160x80 to 150x65
- Reduce title from 20 to 18
- Reduce queue tile from 140x50 to 120x40
- Reduce category labels to 12px
- Reduce padding from 8 to 4px
- Remove scrolling, everything fits in 800x600

Preset UX Improvements:
- Move "Manual" to bottom of all preset dropdowns
- Default bitrate preset: "2.5 Mbps - Medium Quality"
- Default target size: "100MB"
- Manual input fields hidden by default
- Show manual fields only when "Manual" selected

Encoding Preset Order:
- Reverse order: veryslow first, ultrafast last
- Better quality options now appear first
- Applied to both simple and advanced mode

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-20 15:23:14 -05:00
67b838e9ad Scale UI for 800x600 window compatibility and improve layout
UI Scaling:
- Reduce module tiles from 220x110 to 160x80
- Reduce title size from 28 to 20
- Reduce queue tile from 160x60 to 140x50 with smaller text
- Reduce section padding from 14 to 8 pixels
- Remove extra padding wrapper around tiles

Header Layout Improvements:
- Use border layout with title on left, controls on right
- Compact button labels: "☰ History" → "☰", "Run Benchmark" → "Benchmark"
- Eliminates wasted space in header

Queue Behavior Fix:
- "Clear Completed" always returns to main menu (not last module)
- "Clear All" always returns to main menu
- Prevents unwanted navigation to convert module after clearing

All changes work together to fit app within 800x600 default window

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-20 14:50:45 -05:00
9af3ca0c1a Make main menu vertically scrollable for 800x600 windows
- Wrap module sections in NewVScroll container
- Use border layout with fixed header and scrollable content
- Allows all modules to be accessible within 800x600 window
- Header and controls remain visible while content scrolls

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-20 14:37:33 -05:00
d24fd7c281 Fix main menu layout alignment issue
- Replace layout.NewHBoxLayout() with container.NewHBox() for header
- Replace layout.NewVBoxLayout() with container.NewVBox() for body
- Prevents unwanted stretching and improves alignment with rest of UI
- Elements now use natural sizing instead of filling available space

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-20 14:32:04 -05:00
faf8d42e2a Fix Fyne threading errors in stats bar Layout()
- Remove Show()/Hide() calls from Layout() method
- These methods must only be called from main UI thread
- Layout() can be called from any thread during resize/redraw
- Show/Hide logic remains in Refresh() which uses DoFromGoroutine

Fixes threading warnings from Fyne when stats bar updates

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-20 14:20:05 -05:00
2761d35ed6 Fix stats bar UI thread updates 2025-12-20 14:14:42 -05:00
19f2922366 Add subtitles module placeholder and benchmark UI flag 2025-12-20 14:03:14 -05:00
5b76da0fdf Improve benchmark results sorting and cancel flow 2025-12-20 12:05:19 -05:00
86d2f2b835 Add progress bars to In Progress tab and fix lossless quality compatibility
In Progress Tab Enhancements:
- Added animated striped progress bars to in-progress jobs
- Exported ModuleColor function for reuse across modules
- Shows real-time progress (0-100%) with module-specific colors
- Progress updates automatically as jobs run
- Maintains consistent visual style with queue view

Lossless Quality Preset Improvements:
- H.265 and AV1 now support all bitrate modes with lossless quality
- Lossless with Target Size mode now works for H.265/AV1
- H.264 and MPEG-2 no longer show "Lossless" option (codec limitation)
- Dynamic quality dropdown updates based on selected codec
- Automatic fallback to "Near-Lossless" when switching from lossless-capable
  codec to non-lossless codec

Quality Options Logic:
- Base options: Draft, Standard, Balanced, High, Near-Lossless
- "Lossless" only appears for H.265 and AV1
- codecSupportsLossless() helper function checks compatibility
- updateQualityOptions() refreshes dropdown when codec changes

Lossless + Bitrate Mode Combinations:
- Lossless + CRF: Forces CRF 0 for perfect quality
- Lossless + CBR: Constant bitrate with lossless quality
- Lossless + VBR: Variable bitrate with lossless quality
- Lossless + Target Size: Calculates bitrate for exact file size with
  best possible quality (now allowed for H.265/AV1)

Technical Implementation:
- Added Progress field to ui.HistoryEntry struct
- Exported StripedProgress widget and ModuleColor function
- updateQualityOptions() function dynamically filters quality presets
- updateEncodingControls() handles lossless modes per codec
- Descriptive hints explain each lossless+bitrate combination

This allows professional workflows where lossless quality is desired
but file size constraints still need to be met using Target Size mode.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 18:27:24 -05:00
12b2b221b9 Add 'In Progress' tab to history sidebar
Features:
- New "In Progress" tab shows running/pending jobs
- Displays active jobs without opening full queue
- Tab positioned first for quick visibility
- Shows "Running..." or "Pending" status
- No delete button on active jobs (only completed/failed)

Implementation:
- Updated BuildHistorySidebar to accept activeJobs parameter
- Converts queue.Job to ui.HistoryEntry for display
- Filters running/pending jobs from queue
- Conditional delete button (nil check)
- Dynamic status text based on job state

UX Improvements:
- Quick glance at current activity without queue view
- Three-tab layout: In Progress → Completed → Failed
- Consistent styling with existing history entries
- Tappable entries to view full job details

This allows users to monitor active conversions directly
from the history sidebar, reducing the need to constantly
check the full job queue view.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 18:02:03 -05:00
5b544b8484 Add history entry delete button and fix Convert module crash
Features:
- Add "×" delete button to each history entry in sidebar
- Click to remove individual entries from history
- Automatically saves and refreshes sidebar after deletion

Bug Fixes:
- Fix nil pointer crash when opening Convert module
- Fixed widget initialization order: bitrateContainer now created
  AFTER bitratePresetSelect is initialized
- Prevented "invalid memory address" panic in tabs layout

Technical Details:
- Added deleteHistoryEntry() method to remove entries by ID
- Updated BuildHistorySidebar signature to accept onEntryDelete callback
- Moved bitrateContainer creation from line 5742 to 5794
- All Select widgets now properly initialized before container creation

The crash was caused by bitrateContainer containing a nil
bitratePresetSelect widget, which crashed when Fyne's layout system
called .Visible() during tab initialization.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 11:51:26 -05:00
d7389a25bc Phase 5: Integrate sidebar into main menu
Integrated history sidebar into main menu with toggle button and split
view layout. Added history details dialog with FFmpeg command copy.

Changes:
- internal/ui/mainmenu.go:
  * Updated BuildMainMenu() signature to accept sidebar parameters
  * Added "☰ History" toggle button to header
  * Implemented HSplit layout (20% sidebar, 80% main) when sidebar visible

- main.go:
  * Added "sort" import for showHistoryDetails
  * Added showHistoryDetails() method to display job details dialog
  * Shows timestamps, config, error messages, FFmpeg command
  * "Show in Folder" button (only if output file exists)
  * "View Log" button (only if log file exists)
  * Updated showMainMenu() to build and pass sidebar
  * Implemented sidebar toggle that refreshes main menu

The sidebar can be toggled on/off from the main menu, shows history
entries with filtering by status (Completed vs Failed/Cancelled), and
clicking an entry opens a detailed view with all job information and
the ability to copy the FFmpeg command for manual execution.

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-17 19:36:39 -05:00
385c6f736d Phase 4: Create sidebar UI components
Added history sidebar UI with tabs for completed and failed jobs.
Created reusable UI components and helpers for displaying history entries.

Changes:
- internal/ui/mainmenu.go:
  * Added HistoryEntry type definition
  * Added BuildHistorySidebar() for main sidebar UI with tabs
  * Added buildHistoryList() and buildHistoryItem() helpers
  * Added imports for queue and utils packages

- internal/ui/components.go:
  * Moved GetStatusColor() and BuildModuleBadge() here as shared functions
  * Added queue and utils imports for shared helpers

- internal/ui/queueview.go:
  * Updated to use shared GetStatusColor() and BuildModuleBadge()
  * Removed duplicate function definitions

- main.go:
  * Updated to use ui.HistoryEntry type throughout
  * Updated historyConfig, appState, and all methods to use ui.HistoryEntry

The sidebar displays history entries with:
- Status-colored indicators (green/red/orange)
- Module type badges with colors
- Shortened titles and formatted timestamps
- Separate tabs for "Completed" and "Failed" (includes cancelled)
- Empty state messages when no entries exist

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-17 19:34:22 -05:00
bccacf9ea2 Phase 2B: Add Copy Command button to queue view for running/pending jobs
Added "Copy Command" button to queue view for running and pending jobs,
allowing users to copy the FFmpeg command to clipboard for manual execution.

Changes:
- internal/ui/queueview.go: Add onCopyCommand parameter and buttons
- main.go: Implement onCopyCommand handler in showQueue()

The handler retrieves the job, generates the FFmpeg command with
INPUT/OUTPUT placeholders using buildFFmpegCommandFromJob(), and copies
it to the clipboard with a confirmation dialog.

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-17 19:25:38 -05:00
5903b15c67 Add missing dialog/layout imports for FFmpeg command widget 2025-12-17 19:11:34 -05:00
42af533627 Phase 1: Add FFmpeg command copy infrastructure
Implemented the foundation for FFmpeg command copy functionality:

1. Created FFmpegCommandWidget (components.go):
   - Displays FFmpeg commands in scrollable monospace text
   - Includes "Copy Command" button with clipboard integration
   - Shows confirmation dialog when copied
   - Reusable widget for consistent UI across modules

2. Created buildFFmpegCommandFromJob() function (main.go):
   - Extracts FFmpeg command from queue job config
   - Uses INPUT/OUTPUT placeholders for portability
   - Handles video filters (deinterlace, crop, scale, aspect, flip, rotate, fps)
   - Handles video codecs with hardware acceleration (H.264, H.265, AV1, VP9)
   - Handles quality modes (CRF, CBR, VBR)
   - Handles audio codecs and settings
   - Covers ~90% of convert job scenarios

This infrastructure enables users to copy the exact FFmpeg command
being used for conversions, making it easy to reproduce VideoTools'
output in external tools like Topaz or command-line ffmpeg.

Next phase will integrate this into the Convert module UI, queue view,
and conversion history sidebar.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-17 19:09:43 -05:00
4c737d5280 Fix fyne hover interface import for status bar 2025-12-17 14:52:27 -05:00
b826c02660 Improve snippet progress reporting and speed up striped bars 2025-12-17 14:47:37 -05:00
589330cc0b Restore tap handling on status bar 2025-12-17 14:33:11 -05:00
27e038e1a1 Fix queue stats to properly distinguish cancelled from failed jobs
The queue Stats() method was grouping cancelled and failed jobs together,
causing cancelled jobs to be displayed as "failed" in the status bar.
Updated Stats() to return a separate cancelled count and modified all
callers (updateStatsBar, queueProgressCounts, showMainMenu) to handle
the new return value. Also updated ConversionStatsBar to display
cancelled jobs separately in the status bar.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-17 14:25:18 -05:00
6e4eda93d2 Improve progress bar visibility and thickness
- Increase striped progress bar contrast (light: 90→60, dark: 140→200)
- Increase fill opacity (180→200) for better visibility
- Increase progress bar height from 14px to 20px across both striped and standard bars
- Makes progress bars more visible and easier to read at a glance

The striped gradient now has much clearer distinction between light and dark
stripes, and the increased thickness makes progress easier to track visually.
2025-12-17 13:36:56 -05:00
f021bcc26c Use unified status bar helper across modules 2025-12-17 05:06:25 -05:00
f2ac544d75 Make stats bar overlay use module tint and lighter text 2025-12-17 03:03:45 -05:00
320f522d85 Fix queue progress calc type 2025-12-17 02:38:55 -05:00
73e5c4940f Animate striped progress bars in queue 2025-12-17 02:25:00 -05:00
530418f3e5 Improve queue progress UI and upscale progress reporting 2025-12-17 02:21:55 -05:00
b01e83b97c Fix benchmark progress bar percentage calculation
The progress bar was configured with Max=100 but we were setting
values in the 0.0-1.0 range, causing it to always show ~0%.

Fixed by multiplying the percentage by 100 before setting the value,
so 4/22 = 0.18 becomes 18% instead of 0.18%.

Also fixed SetComplete() to set 100.0 instead of 1.0.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-13 14:04:20 -05:00
1447e1478f Fix Fyne threading errors in benchmark progress updates
All UI updates from the benchmark goroutine were causing threading
errors because they weren't wrapped in DoFromGoroutine. Fixed:

- UpdateProgress: progress bar and label updates
- AddResult: adding result cards to the display
- SetComplete: final status updates

These methods are called from background goroutines running the
benchmark tests, so all UI updates must be dispatched to the main
thread using fyne.CurrentApp().Driver().DoFromGoroutine().

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-13 13:33:18 -05:00
4d99f6ec78 Add benchmark history tracking and results browser
Extended the benchmark system to maintain a complete history of all
benchmark runs (up to last 10) with full results for each encoder/preset
combination tested.

Features:
- Stores complete benchmark run data including all test results
- History browser UI to view past benchmark runs
- Click any run to see detailed results for all encoders tested
- Compare performance across different presets and encoders
- Apply recommendations from past benchmarks
- Automatic history limit (keeps last 10 runs)

UI Changes:
- Renamed "Benchmark" button to "Run Benchmark"
- Added "View Results" button to main menu
- New benchmark history view showing all past runs
- Each run displays timestamp, recommended encoder, and test count
- Clicking a run shows full results with all encoder/preset combinations

Data Structure:
- benchmarkRun: stores single test run with all results
- benchmarkConfig: maintains array of benchmark runs
- Saves to ~/.config/VideoTools/benchmark.json

This allows users to review past benchmark results and make informed
decisions about which encoder settings to use by comparing FPS across
all available options on their hardware.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-13 13:07:51 -05:00
87c2d28e9f Add comprehensive hardware encoder benchmarking system
Implemented a full benchmark system that automatically detects available
hardware encoders, tests them with different presets, measures FPS
performance, and recommends optimal settings for the user's system.

Features:
- Automatic test video generation (30s 1080p test pattern)
- Hardware encoder detection (NVENC, QSV, AMF, VideoToolbox)
- Comprehensive encoder testing across multiple presets
- Real-time progress UI with live results
- Performance scoring based on FPS metrics
- Top 10 results display with recommendation
- Config persistence for benchmark results
- One-click apply to use recommended settings

UI Components:
- Benchmark button in main menu header
- Progress view showing current test and results
- Final results view with ranked encoders
- Apply/Close actions for recommendation

Integration:
- Added to main menu between "Benchmark" and "Logs" buttons
- Saves results to ~/.config/VideoTools/benchmark.json
- Comprehensive debug logging for troubleshooting

This allows users to optimize their encoding settings based on their
specific hardware capabilities rather than guessing which encoder
will work best.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-13 09:16:36 -05:00