Communitygithub.com

Reel 导出

将任何横向或方形的运动视频转换为 1080 x 1920 的 Instagram Reel 或 TikTok,确保上传后颜色清晰。标题和标志位于安全区内,H.264 编码,yuv420p 色彩空间,有限色彩范围,bt709 标准,无声轨时添加静音音频轨,并在上传前通过 ffprobe 校验。当用户提出相关需求时使用。

Reel 导出 是什么?

该技能专为 AI 代理设计,用于将宽屏或方屏的视频素材转换为符合 Instagram Reel 和 TikTok 平台要求的竖屏视频(1080×1920)。它解决了上传后颜色失真、视频被重新编码等常见痛点,通过严格的编码参数(H.264、yuv420p、有限色彩范围、bt709)确保输出文件兼容并色彩准确。技能还提供了安全区域指南,防止文字和标志被应用的 UI 元素遮挡,并自动插入静音 AAC 音频轨,保留原始音频可选择替换。支持 ffprobe 上传前校验,确保格式正确并避免重新编码。适用于 Cursor、Claude Code 等支持 ffmpeg 的 AI 代理平台,核心工作流程包括:1) 收集视频、标题、标志和背景色;2) 在安全区域内构建带有覆盖层的竖屏视频;3) 通过单条 ffmpeg 命令编码;4) 使用 ffprobe 验证输出。该技能还包含了关于手机录制 HEVC/全范围视频可能导致颜色褪色、标志在浅色帧上难以辨认以及 faststart 元数据重要性等实战经验。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/charlie947/motion-graphics-skills/tree/main/skills/reel-export

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

Reel 导出 是做什么的?

大多数运动视频都是宽屏的。此技能将其转换为竖版文件,顶部带有钩子标题,应用接受后不会让颜色褪色。

开始之前: 如果存在,请阅读 brand.md 和 MOTION.md。如果没有,先运行 brand-intake,或者询问十六进制颜色代码、字体和标志文件。没有这些,永远不要称结果为“符合品牌规范”。

步骤 1:询问四件事,然后等待

  1. 视频。 任何 MP4,任何尺寸。
  2. 标题, 两行短文字,逐字核对。它是人们在静音时阅读的钩子。
  3. 标志, 作为附件提供,如果视频中提到了产品或公司名称。
  4. 视频周围的背景颜色。 默认:近似黑色 #0B0B0F。

步骤 2:安全区域

应用会在 Reel 的边缘绘制自己的按钮、字幕和用户资料。确保每个文字和标志:

  • 位于 y 360 到 y 1420 之间(底部 500px 不要放任何内容)
  • 避开右侧 120px

将标题放在该区域的顶部,视频放在其下方。一个 16:9 的视频缩放至 1080 宽后高度为 608,因此将其放置在 y 660 位置很合适。

步骤 3:构建叠加层,然后编码

在 HTML 中使用标题和任何标志构建一个透明的 1080×1920 的 overlay.png,并截图保存。可自定义样式的文本效果优于 ffmpeg 硬编码的文字。然后:

ffmpeg -y -i in.mp4 -loop 1 -i overlay.png -f lavfi -i anullsrc=r=48000:cl=stereo -filter_complex "color=c=0x0B0B0F:s=1080x1920:r=30[bg];[0:v]fps=30,scale=1080:-2,setsar=1[v];[bg][v]overlay=0:660:shortest=1[o];[o][1:v]overlay=0:0:shortest=1,scale=out_color_matrix=bt709:out_range=tv,format=yuv420p[out]" -map "[out]" -map 2:a -shortest -c:v libx264 -profile:v high -crf 18 -pix_fmt yuv420p -color_range tv -colorspace bt709 -color_primaries bt709 -color_trc bt709 -c:a aac -b:a 128k -movflags +faststart reel.mp4

这会添加一条静音的 AAC 音轨。如果视频本身有声音,将 -map 2:a 替换为 -map 0:a。

步骤 4:上传前检查

ffprobe -v error -show_entries stream=codec_type,codec_name,width,height,pix_fmt,color_range,color_space -of compact reel.mp4

通过条件:视频为 h264,1080×1920,yuv420p,color_range=tv,bt709,外加一条 aac 音频流。如果你看到 hevc 或 color_range=pc,请重新编码。然后抽取中间的一帧,在手机尺寸下查看效果。

我踩过的坑

  • 手机录制的视频通常是 HEVC 和全范围。 直接上传可能导致颜色褪色或重新编码后效果变差。务必导出全新的 H.264 有限范围文件,包括在任何编辑之后。
  • 覆盖在画面上的标志在浅色帧上会消失。 将每个标志(及其标签)放在自己的深色圆角瓦片背景上。
  • faststart 很重要。 没有 -movflags +faststart,文件在完全加载之前无法开始播放。
  • 钩子标题保持两行以内。 我的标题足够短,一秒钟就能读完:“此 Mac 发布” / “100% 代码实现”。

Individual skills in this repo

This repo contains 14 individual skills — each has its own dedicated page.

animated-chart

Make a looping animated chart for LinkedIn or a newsletter in code with Claude Code. Bars that become a line, a number that counts up, a before and after. Every value stays exactly as given. Use when someone says

apple-launch-film

Rebuild an Apple-style Mac launch film entirely in code with Claude Code. A thin menu bar, the black notch growing into widgets one scene at a time, full-screen gradient wallpapers and one short caption per scene. No screen recording, no After Effects. Use when someone says

brand-intake

The setup step every other skill in this pack reads. A short interview plus 3 to 5 reference frames becomes two files in your project, brand.md (who you are, what you sell, your assets) and MOTION.md (your colours, type, timing and motion rules), plus a rule in CLAUDE.md so Claude reads them before it animates anything. Use at the start of any motion project, or when someone says

launch-video

Make a 30-45 second product launch video in code with Claude Code, the kind SaaS companies post on launch day. One sentence split across scenes, real product screens with slow camera moves, a typed prompt, a proof beat and a clear call to action. Use when someone says

loop-cover

Turn a newsletter or blog cover into a seamless looping GIF at 896 x 640, 180 frames at 20fps. Only the one element you name moves, the loop is rotated so frame 1 shows the finished picture, and the seam is measured, not eyeballed. Use when someone says

milestone-reveal

Make a 12-second looping milestone clip in code with Claude Code. Thousands of tiny points drift like a night sky, pull together into your real number (followers, subscribers, revenue, customers), a line draws underneath and the label settles in. Premium, not a party. Use when someone says

model-showdown

Give the same motion brief to three AI models, keep each first try, render all three the same way and stack them into one comparison video with model names and logos. Makes a 16:9 side-by-side for a newsletter and a 1080 x 1920 stacked reel for Instagram and TikTok. Use when someone says

motion-brief-writer

Turns a rough idea for an animated graphic into a precise build brief for Claude Code, in your own brand. Asks for anything essential first (exact numbers, size, length, brand), keeps real results apart from sample data, and never invents a figure. Use when someone says

motion-effects

Build any of 16 premium motion effects from scratch in your own brand, as one 8-second looping HTML file with window.seek(seconds) so it exports frame-exact to MP4 or GIF. Interfaces (button to player, search to results, card to workspace, tabs to panels), data (chart morph, dashboard zoom, spring stack, magnetic dock), type (masked type, elastic type, text to layout, image reveal) and systems (perspective shift, glass focus, flowing paths, particle logo). Use when someone says

motion-prompt-writer

Write a complete 8-part Claude Motion prompt (The bar, Format, The one rule, Look, Motion, Never, Before you finish, The scene) for one short looping motion graphic, in your own brand. Takes your brand (a website screenshot, a logo, hex codes, or nothing for the Apple-style default) and one moment you want to show, in plain words. Use when someone says

newsletter-promo

Turn a newsletter edition into a 12-20 second promo clip for LinkedIn, Instagram or X that drives people to read and subscribe. Hook question, three proof frames from the edition, then the newsletter name and where to read it. Use when someone says

reference-to-motion

Turn references you admire into a scene-by-scene Claude Motion prompt for your own topic and brand. Takes a video for the moves (screenshots, frames or a contact sheet of a reel or ad) and, optionally, a look reference for the style (a website, a brand, a moodboard). Use when someone says

title-sequence-3d

Make a cinematic 3D title sequence (8-15 seconds) in code with Claude Code and Three.js. A camera moves through a lit scene, such as a rainy street at night with brand names as neon signs, then a big question or title lands. Use when someone wants a scroll-stopping opener, a film-style intro,

vox-explainer

Make a short Vox-style documentary explainer (30-60 seconds) entirely in code with Claude Code. Torn paper, halftone texture, bold condensed type, motion on twos. Use when someone says

相关技能