ffmpeg-command-syntax
This skill covers FFmpeg's position-sensitive command structure, explaining where global, input, and output options must appear and how their meaning shifts based on placement. It addresses stream specifiers, multi-input/output handling, and the critical behaviors of options like -ss, -t, -r, and -c that work differently before versus after -i.
ffmpeg-command-syntax teaches the position-sensitive rules for placing FFmpeg options correctly before or after inputs.
AI-generated summary based on this skill's SKILL.md
Decision gist · record as of 2026-06-18
ffmpeg-command-syntax teaches the position-sensitive rules for placing FFmpeg options correctly before or after inputs. This skill covers FFmpeg's position-sensitive command structure, explaining where global, input, and output options must appear and how their meaning shifts based on placement. It addresses stream specifiers, multi-input/output handling, and the critical behaviors of options like -ss, -t, -r, and -c that work differently before versus after -i.
Use it when
- ffmpeg-command-syntax clarifies that input options (placed before -i) control how FFmpeg reads and decodes the input file—like -ss.
- ffmpeg-command-syntax identifies common errors: placing output options before -i (they're ignored), using -ss after -i when you need speed.
Verify before relying
Read SKILL.md below before installing (6 files). Open directory: indexed for reading, not audited.
Install
JosiahSiegel/claude-plugin-marketplace/ffmpeg-command-syntax · repository language: Shell
Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.
Frequently asked questions
AI-generated answers based on this skill's SKILL.md and metadata
How to place ffmpeg options correctly in a command?
ffmpeg-command-syntax teaches that option placement is critical: global options come first, then -i input_file, then output options, then output_file. Options before -i apply to input decoding; options after -i apply to output encoding. For example: ffmpeg -ss 10 -i input.mp4 -c:v libx264 output.mp4 seeks 10 seconds during input, while ffmpeg -i input.mp4 -ss 10 output.mp4 seeks after loading the full file. This position-dependent behavior applies to -ss, -t, -r, -c, and many others.
What's the difference between ffmpeg input vs output options?
ffmpeg-command-syntax clarifies that input options (placed before -i) control how FFmpeg reads and decodes the input file—like -ss for seeking, -r for frame rate during input, or -c:v for input codec. Output options (placed after -i) control encoding and writing—like -c:v for output codec, -b:v for bitrate, or -vf for filters. Misplacing them changes behavior: -ss before -i is fast but less accurate; -ss after -i is slow but frame-accurate.
Why is my ffmpeg command not working—what syntax errors occur?
ffmpeg-command-syntax identifies common errors: placing output options before -i (they're ignored), using -ss after -i when you need speed, forgetting stream specifiers like :v or :a for multi-stream files, and mixing -vf (simple filter) with -filter_complex (advanced routing). Check your -i position: it must come after global/input options and before output options. Verify codec and format options match their target (video vs audio). Use -vf for single-input filtering; use -filter_complex for multi-input or complex graphs.
What are ffmpeg stream specifiers and when do you use them?
ffmpeg-command-syntax explains that stream specifiers target specific streams in files with multiple audio, video, or subtitle tracks. Use :v for video, :a for audio, :s for subtitles, or :0:v for stream 0's video. Example: ffmpeg -i input.mp4 -c:v libx264 -c:a aac output.mp4 encodes video with libx264 and audio with aac. Without specifiers, FFmpeg applies options to all matching streams. For multi-input/output, specify which input feeds which output using -map input_index:stream_specifier.
How does ffmpeg -ss placement affect seeking—before or after -i?
ffmpeg-command-syntax emphasizes that -ss before -i seeks during input decoding (fast, keyframe-based, less accurate), while -ss after -i seeks after loading (slow, frame-accurate). Use -ss before -i for rough cuts or live streams; use -ss after -i when precision matters. Combine both for speed and accuracy: ffmpeg -ss 10 -i input.mp4 -ss 0.5 -t 5 output.mp4 fast-seeks to ~10s, then frame-accurate seeks 0.5s more, capturing 5 seconds.
What's the difference between ffmpeg -t vs -to duration options?
ffmpeg-command-syntax distinguishes -t (duration in seconds from start) from -to (absolute end timestamp). Example: ffmpeg -i input.mp4 -t 10 output.mp4 outputs 10 seconds; ffmpeg -i input.mp4 -to 30 output.mp4 outputs up to the 30-second mark. Combine them: ffmpeg -ss 5 -i input.mp4 -t 10 output.mp4 starts at 5s and captures 10 seconds total. Position matters: place both after -i for output control.
SKILL.md
Rendered from the published skill. Quoted content, verbatim.
CRITICAL: FFmpeg Option Ordering Rules
The most common FFmpeg mistake is putting options in the wrong place. Options in FFmpeg are position-sensitive and apply to the NEXT file specified after them.
The Golden Rule
ffmpeg [global_options] {[input_options] -i input}... {[output_options] output}...
Key principle: Options are applied to the next file. They are reset between files.
Option Categories at a Glance
| Category | Where it goes | Notable members
(truncated - see the full file via the links below)
File tree — 6 files
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/SKILL.md
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/references/complete-option-reference.md
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/references/format-specific-options.md
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/references/hardware-device-init.md
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/references/stream-specifiers.md
plugins/ffmpeg-core/skills/ffmpeg-command-syntax/references/timestamps-bitstream-metadata.md
Let your AI agent find skills like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.
wish › “Learn correct FFmpeg option ordering and placement rules”
Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →
Related skills
FFmpeg Patterns provides ready-to-use command examples for video and audio tasks like transcoding to MP4 or WebM, extracting audio tracks, trimming clips, applying filters, merging media, generating thumbnails, and streaming formats. It covers hardware acceleration, batch operations, and practical probing commands.
This skill harnesses FFmpeg to handle video and audio editing tasks—trimming, transcoding, resizing, concatenating, adding subtitles, overlaying graphics, color grading, audio normalization, and green-screen compositing. It supports modern codecs (H.264, H.265, VP9, AV1) and GPU-accelerated encoding via NVIDIA NVENC, Intel QSV, and Apple VideoToolbox, with helper scripts for common workflows.
Clipify turns long-form videos into vertical social clips by identifying clip-worthy moments via transcription, automatically reframing 16:9 footage to 9:16 with motion-based face tracking, and applying word-level captions. It detects punchlines, reversals, and audio peaks to propose 3–5 candidates, then renders with hardware acceleration on macOS.
Video Processing & Editing automates FFmpeg-based workflows for cutting, trimming, concatenating, and exporting video content. It handles audio mixing, subtitle management, and platform-specific optimization without requiring manual editing interfaces. Use it for production pipelines and batch processing; not for real-time UI editing or 3D compositing.
Combine FFmpeg and ImageMagick to handle multimedia workflows—video encoding and transcoding, audio extraction, image resizing and effects, streaming manifest generation, and batch processing. Choose the right tool for each task: FFmpeg excels at video/audio work and live streaming, while ImageMagick specializes in image transformation and composition.
Media Processing harnesses FFmpeg and ImageMagick to handle video, audio, and image workflows—from format conversion and codec selection to streaming manifest generation and batch optimization. Extract audio, generate thumbnails, apply filters, add watermarks, and leverage hardware acceleration for faster encoding.
More skills Ffmpeg Webcli Browser Video Editor (NOASSERTION) · wjs-syncing-multicam (MIT) · ffmpeg-webassembly-workers (MIT)