Skip to content

About

Native macOS app to inspect and remux MKV/MP4 streams

Resources

Stars

4 stars

Watchers

0 watching

Forks

Latest commit

 

History

2 Commits

Folders and files

Repository files navigation

StreamMuxer

A native macOS desktop app to inspect, remux and transcode media files, powered by FFmpeg/FFprobe.

StreamMuxer

Project Home

StreamMuxer offers FFmpeg's power through a native UI, without requiring the user to write FFmpeg commands:

  • Drag and drop one or more files (.mkv, .mp4, .mov)
  • Inspect all streams grouped by source file
  • Per-stream decision: Copy / Transcode / Discard
  • Quality-oriented video transcoding (H.264 / HEVC / AV1, software or VideoToolbox hardware)
  • Audio transcoding (AAC, Opus, AC-3, E-AC-3, FLAC, ALAC — whatever the local build supports)
  • Keep output ordering as: video -> audio -> subtitles -> other

Features

  • Native SwiftUI macOS app (macOS 13+)
  • FFmpeg/FFprobe detection with startup environment check (version + encoder scan)
  • Dynamic encoder detection: only codecs actually available in the local FFmpeg build are offered (including h264_videotoolbox / hevc_videotoolbox)
  • Stream probing with ffprobe (JSON), including container info, chapters and default/forced disposition
  • Per-stream copy/transcode/discard with quality-based controls (Higher quality / Balanced / Smaller file) and encoder speed presets
  • Container compatibility validation (e.g. PGS subtitles into MP4 are rejected; text subtitles auto-convert to mov_text)
  • MKV / MP4 / MOV output
  • FFmpeg command preview (transparency/debugging) — execution always uses structured Process arguments, never a shell string
  • Structured progress via -progress pipe:1: percentage, processed time, speed, fps and ETA
  • Cancellation of a running export (partial output is cleaned up)
  • Full FFmpeg log accessible from the UI ("Show FFmpeg Log")
  • Per-row expandable stream details (bitrate, profile/level, color metadata, SAR/DAR, refs, B-frames, and more)
  • Default output suggestion based on source file:
    • same folder
    • <original_name>_conf.<selected_extension>

Requirements

  • macOS 13+
  • ffprobe and ffmpeg available either:
    • embedded in app bundle, or
    • installed in system (Homebrew supported)

The app checks common Homebrew paths automatically (/opt/homebrew/bin, /usr/local/bin, etc).

Quick Start

cd StreamMuxer
swift build
swift run StreamMuxer

You can also open the folder in Xcode and run the StreamMuxer target.

To build a double-clickable StreamMuxer.app:

scripts/make-app.sh
open dist/StreamMuxer.app

See Setup and Distribution for details (including embedding ffmpeg in the bundle).

Usage

  1. Add files via drag-and-drop or the file picker.
  2. Wait for stream analysis to complete. All streams default to Copy (nothing is modified unless you say so).
  3. Set each stream to Copy, Transcode (choose codec, encoder and quality) or Discard.
  4. Pick the output container (MKV/MP4/MOV) and review the output path (auto-suggested, editable).
  5. Optionally inspect the generated FFmpeg command.
  6. Export — watch progress/speed/ETA, cancel anytime.

Output Mapping Rules

During export, selected streams are always reordered before muxing:

  1. Video streams
  2. Audio streams
  3. Subtitle streams
  4. Other streams

This guarantees deterministic output stream layout.

Bundling ffmpeg/ffprobe in the app

To distribute StreamMuxer without external runtime dependencies:

  1. Provide ffmpeg and ffprobe binaries.
  2. Embed them in app resources (for example under Resources/bin).
  3. Ensure they are copied to the final .app bundle during build.

If not embedded, the app falls back to system paths.

Project Structure

StreamMuxer/
  Sources/StreamMuxer/
    App/        # app entry + main views/view model
    Models/     # media file/stream models, capabilities, per-stream settings, export session
    Services/   # ffprobe/ffmpeg integration: locator, capability scanner, command builder, runner
    Views/      # UI components
    Resources/  # runtime resources

Documentation

Additional technical docs:

License

No license file has been added yet. Add one before public/commercial redistribution.

About

Native macOS app to inspect and remux MKV/MP4 streams

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages