動画を縦長・正方形に切り抜き/余白追加
Reframe Video to Vertical or Square
横長のローカル動画を縦長・正方形へ。中央や手動の注目位置で切り抜くか、黒い余白を足して画面全体を残します。
できること
横長などのローカル動画を、縦長または正方形のMP4に整えます。中央を基準に切り抜くほか、横・縦それぞれ0〜1の位置指定で注目点を決められます。全体を残したい場合は黒い余白を追加します。出力の高さも指定でき、変更前後の幅・高さ、切り抜き範囲、実行コマンドをJSONに記録します。
使い方
Claude、Codex、Hermes Agent、Cursorに動画と、切り抜きか余白追加かを伝えます。縦長または正方形を選び、必要なら注目点と高さを指定してください。ドライランで寸法を確認した後、新しいフォルダーに書き出します。
必要な環境
Python 3.10以降、FFmpeg、ffprobeが必要です。Pythonの追加パッケージは不要で、映像処理はローカルで行います。映像はH.264、音声がある場合は最初の音声をAACにします。
注意点
顔認識や人物の自動追跡は行いません。注目位置は動画全体で固定です。出力は偶数サイズで最大4096ピクセルに制限し、縦横比には丸め誤差があります。回転情報付きや非正方形ピクセルの入力は事前の正規化が必要です。元動画と既存フォルダーは上書きしません。任意のYouTube URLからのダウンロード機能はなく、利用権限のあるローカル素材専用です。
English description
Reframe local video with a center or manual focal crop, or black padding. Export bounded even-sized video and a before/after geometry manifest.
What it does
Convert local landscape video to approximate 9:16 vertical or 1:1 square framing with a fixed center/manual focal crop, or black padding that retains the whole image. Optionally set an even output height. A geometry manifest includes source dimensions, crop, planned dimensions, command and measured output dimensions.
How to use
Choose crop or pad and vertical or square. Focal x/y fractions range from 0 to 1 and affect crop only. Review a dry run before exporting to a new directory.
Requirements
Python 3.10+, FFmpeg and ffprobe installed separately. No Python packages, uploads or model downloads. FFmpeg must include H.264 and AAC encoding.
Caveats
No AI face detection or tracking; the focal position is fixed throughout. Dimensions are even and capped at 4096 per side; rounding slightly changes aspect ratio. Rotated metadata and non-square pixels are rejected until normalized. Only the first video and optional first audio are retained; captions, global container tags and chapters are dropped. Does not overwrite existing directories or download arbitrary YouTube URLs.
インストール方法
- ダウンロードしたZIPを展開します(中に
video-vertical-reframe/フォルダとSKILL.mdがあります)。 - フォルダごと、使うエージェントのスキル置き場にコピーします。
- Claude:
~/.claude/skills/(プロジェクト単位なら.claude/skills/) - Hermes Agent:
~/.hermes/skills/ - Codex:
~/.agents/skills//Cursor:~/.cursor/skills/ - Claude アプリ(claude.ai):「カスタマイズ → スキル」からZIPをアップロード
- Claude:
- エージェントを再起動し、スキル一覧に表示されることを確認します。
出品者
動画編集の準備から仕上がりの確認まで、毎日の作業を支援するスキルを制作しています。切り出し・字幕づくり・音声調整・文字起こしを、元の素材を残しながら進められるようにします。
出品スキル 10 件