ffmpeg

Convert and optimize audio/video media using FFmpeg toolchain commands.

Updated Jan 7, 2024
One-click install
npx skills add https://github.com/martinjlowm/nixfiles --skill ffmpeg-martinjlowm
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ffmpeg
Source: https://github.com/martinjlowm/nixfiles/tree/main/config/claude/skills/ffmpeg
Command: npx skills add https://github.com/martinjlowm/nixfiles --skill ffmpeg-martinjlowm

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It helps you convert, encode, filter, stream, and inspect audio/video files without manually juggling incompatible tools or guesswork.

Core Features & Use Cases

  • Format conversion & stream copying: Quickly remux or re-encode media (e.g., MKV to MP4, keep streams with -c copy) for playback compatibility.
  • Quality-focused encoding & media optimization: Use CRF and presets to hit your desired size/quality tradeoff for video and audio.
  • Processing pipelines for real tasks: Extract audio, trim segments, batch convert, and apply filters (scale/crop/denoise/overlays) for production-ready outputs.

Quick Start

Use the ffmpeg skill to convert your file by running: ffmpeg -i input.mkv -c:v libx264 -crf 22 -preset medium -c:a aac -b:a 128k output.mp4.

Frequently Asked Questions about ffmpeg

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I convert MKV to MP4 without losing quality?

To convert MKV to MP4 without quality loss, use stream copying with the -c copy flag to remux the container without re-encoding. This preserves the original video and audio streams, ensuring fast processing and no generational quality degradation during format conversion.

What is the best way to balance file size and video quality during transcoding?

The best way to balance video size and quality during transcoding is using the Constant Rate Factor (CRF) and encoding presets. A lower CRF value increases quality and file size, while slower presets compress more efficiently without sacrificing visual fidelity for your output file.

How do I extract audio from a video file and save it as a standalone track?

To extract audio from a video file, map the audio stream and re-encode it using a codec like AAC with a specified bitrate such as 128k. This processing pipeline isolates the audio track, allowing you to save it as a standalone file for playback or further editing.

Can I apply video filters like scaling or cropping during batch media conversion?

Yes, you can apply video filters like scaling, cropping, denoising, or overlays during batch media conversion. By constructing common filter graphs, you can process multiple files sequentially while applying consistent production-ready visual modifications to your output.

How do I inspect media file metadata and stream codecs before streaming?

To inspect media file metadata and stream codecs before streaming, use ffprobe. It analyzes your audio and video files, extracting detailed container information and stream mapping data to ensure compatibility with RTMP, HLS, UDP, or RTP delivery workflows.

Does transcoding require specific codec selection for different streaming protocols?

Yes, transcoding requires specific codec selection for different streaming protocols. Converting media for RTMP, HLS, UDP, or RTP delivery workflows demands compatible video and audio codecs, ensuring proper container mapping and playback across the targeted streaming platform.