Pair with our Cinematography & Continuity guides
Combine this post-production finish with Guide 05: Consistent Characters, Product Placement & Brand Assets and verify your finished master using Skill 12: Video QA and Broadcast Delivery Subagent.
SKILL.md Install into .claude/skills/, .cursor/skills/, or .agents/skills/ below whenever you splice footage from two different AI video engines and want them to look filmed on the exact same camera sensor.
Installable SKILL.md rulebook for unifying mismatched AI video clips (Gemini Omni Flash, Kling 4.0, Runway Gen-4 Turbo, Runway Gen-4.5, Wan 2.2) into one cohesive camera look via subtle Rec.709 contrast matching, .cube 3D LUT application, restrained organic 35mm film grain (noise=alls=7:allf=t+u), and strict yuv420p delivery.
Pick Claude Code, Cursor, or Codex below to save the pure raw SKILL.md file.
Run over assembled clips from mixed models (e.g., Gemini Omni Flash + Runway Gen-4 Turbo) with or without a .cube LUT file.
Adds subtle temporal film grain that erases plastic AI smoothness and aligns contrast, black point, and yuv420p color tags.
Pick the app you use below for the exact verified command or config—zero manual guessing.
.claude/skills/ffmpeg-grain-lut-match/SKILL.md. mkdir -p .claude/skills/ffmpeg-grain-lut-match
curl -fsSL https://framesfield.com/raw/skills/ffmpeg-color-grade-and-grain-match-skill -o .claude/skills/ffmpeg-grain-lut-match/SKILL.md .cursor/skills/ directory. mkdir -p .cursor/skills/ffmpeg-grain-lut-match
curl -fsSL https://framesfield.com/raw/skills/ffmpeg-color-grade-and-grain-match-skill -o .cursor/skills/ffmpeg-grain-lut-match/SKILL.md .agents/skills/ for team repos. mkdir -p .agents/skills/ffmpeg-grain-lut-match
curl -fsSL https://framesfield.com/raw/skills/ffmpeg-color-grade-and-grain-match-skill -o .agents/skills/ffmpeg-grain-lut-match/SKILL.md
This is the exact raw file served at /raw/skills/ffmpeg-color-grade-and-grain-match-skill.
---
name: ffmpeg-grain-lut-match
description: Unify AI video clips generated across mixed engines (Gemini Omni Flash, Kling 4.0, Runway, Wan 2.2) using restrained Rec.709 color balance, optional .cube 3D LUTs, organic temporal film grain, and explicit BT.709 yuv420p metadata tags in FFmpeg.
---
# FFmpeg Multi-Model Color Matching & Organic Grain Protocol
When blending shots from different AI video engines, differences in skin smoothing, saturation, and noise floor make cuts feel synthetic. Apply this deterministic finishing pass AFTER concatenation (never add grain twice to the same clip):
## 1. Default Editorial Unifying Pass (No External LUT Required)
Slightly reins in oversaturated AI greens/oranges (`saturation=0.96`), anchors contrast (`1.03`), and overlays subtle uniform temporal 35mm-style grain (`alls=6` to `8`, `allf=t+u`):
```bash
ffmpeg -y -i assembled_master.mp4 \
-vf "eq=contrast=1.03:saturation=0.96:brightness=0.01,noise=alls=7:allf=t+u,format=yuv420p" \
-c:v libx264 -preset slow -crf 18 \
-colorspace bt709 -color_primaries bt709 -color_trc bt709 \
-c:a copy -movflags +faststart \
unified_rec709_master.mp4
```
## 2. Applying a Studio `.cube` 3D LUT at Controlled Strength
Never bake heavy creative LUTs at 100% blind opacity—allow blending with the original footage (e.g., `50%` LUT opacity via `split` + `blend` or restrained neutral LUT) followed by uniform grain:
```bash
ffmpeg -y -i assembled_master.mp4 \
-filter_complex "
[0:v]split=2[orig][tolut];
[tolut]lut3d=file=studio_rec709.cube:interp=tetrahedral[lutted];
[orig][lutted]blend=all_expr='A*0.5+B*0.5',noise=alls=6:allf=t+u,format=yuv420p[vout]
" \
-map "[vout]" -map 0:a? \
-c:v libx264 -preset slow -crf 18 \
-colorspace bt709 -color_primaries bt709 -color_trc bt709 \
-c:a copy -movflags +faststart \
graded_lut_master.mp4
```
## 3. Restraint & Compression Rules
- Keep `noise=alls` strictly between `5` and `9` (`>12` looks noisy and destroys H.264 bitrate efficiency on YouTube/Reels).
- Always set `-crf 17` or `-crf 18` when adding grain so the H.264 encoder preserves fine texture instead of smearing grain into macroblocks.
- Always tag `-colorspace bt709 -color_primaries bt709 -color_trc bt709` so macOS QuickTime and Chrome render identical gamma. "Our 30s spot mixes Gemini Omni Flash talking shots with Runway Gen-4 Turbo B-roll and the B-roll looks slightly too glossy. Unify the assembled master with subtle Rec.709 film grain."
- Applies single finishing pass (`eq=contrast=1.03:saturation=0.96`, `noise=alls=7:allf=t+u`, explicit BT.709 color metadata) at `-crf 18` while stream-copying the already-leveled `-14 LUFS` audio track (`-c:a copy`). - Preserves crisp texture without bitrate macroblocking or QuickTime gamma shift.
ffmpeg and Windows Gyan.FFmpeg).cube 3D LUT file exported from DaVinci ResolveCombine this post-production finish with Guide 05: Consistent Characters, Product Placement & Brand Assets and verify your finished master using Skill 12: Video QA and Broadcast Delivery Subagent.
-colorspace bt709 -color_primaries bt709 -color_trc bt709?