From 373efac4af948f8f1ba932ee2beee62ebec63776 Mon Sep 17 00:00:00 2001 From: Claude Toupin Date: Sun, 1 Nov 2026 16:58:18 -0500 Subject: [PATCH] Fix Get-Frame.ps1 parameter forwarding to use preference variable splatting instead of manual array building, preventing positional binding issues, update Get-FramesRange.ps1 to add -y flag for automatic overwrite of existing PNG files, fix Create-ShortClip.ps1 to skip clearing default Frames directory when -Render is used (frames are input not output) and add null checks before Test-Path in cleanup logic, and update documentation in Create-FullSubtitle.ps1 and Create-ShortClip.ps1 to clarify existing --- SKILL.md | 162 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 162 insertions(+) create mode 100644 SKILL.md diff --git a/SKILL.md b/SKILL.md new file mode 100644 index 0000000..68bcf1f --- /dev/null +++ b/SKILL.md @@ -0,0 +1,162 @@ +--- +name: video-processing-scripts +description: Operates a collection of PowerShell 7 scripts that process video and image files with ffmpeg, ffprobe, rife-ncnn-vulkan and upscayl-bin. Covers clipping frame ranges, scene-based clip extraction, frame extraction to PNG, frame counts and video metadata, cropping and resizing to standard, LTX-2, Kling and Wan resolutions, pillar-boxing, side-by-side comparison, turnaround sheets, subtitle merging, audio extraction, AI image upscaling and RIFE frame interpolation. Use this skill when the user asks about video clipping, frame extraction, scene detection, cropping, upscaling, frame interpolation, subtitles, ffmpeg or RIFE workflows, the PowerShell video scripts, or preparing clips for Wan2GP or LTX models. +--- + +# Video Processing PowerShell Scripts + +A collection of PowerShell 7 scripts that wrap ffmpeg and ffprobe for video and image processing. Some scripts also call rife-ncnn-vulkan (frame interpolation) and upscayl-bin (AI upscaling). Each script has its own page in this documentation, linked from the catalog below. + +## Prerequisites + +- **PowerShell 7+** (`pwsh`). Required by every script. +- **ffmpeg** and **ffprobe** on `PATH`. Required by every video script. +- **rife-ncnn-vulkan** on `PATH`, with `RIFE_HOME` set. Required by [Stitch-InBetween.ps1](Stitch-InBetween.md). See [RIFE installation guide](RIFE.md). +- **upscayl-bin** on `PATH`, with `UPSCAYL_HOME` set. Required by [Clone-Image.ps1](Clone-Image.md) when `-Upscale` is used. See [Upscalers installation guide](Upscalers.md). + +## Environment Variables + +| Variable | Purpose | Accepted values | Required by | +| --- | --- | --- | --- | +| `RIFE_HOME` | Install folder of rife-ncnn-vulkan (the same folder as its `PATH` entry). Models are read from `%RIFE_HOME%\rife-v4.26`. | Folder path, e.g. `C:\tools\rife-ncnn-vulkan\` | [Stitch-InBetween.ps1](Stitch-InBetween.md) | +| `UPSCAYL_HOME` | Install folder of upscayl-bin (the same folder as its `PATH` entry). Models are read from `%UPSCAYL_HOME%\models`. | Folder path | [Clone-Image.ps1](Clone-Image.md) with `-Upscale` | +| `NCNN_GPU_ID` | GPU device passed to the `-g` flag of rife-ncnn-vulkan and upscayl-bin. | `0`, `1`, `2`... (GPU index), `-1` (CPU only) | [Stitch-InBetween.ps1](Stitch-InBetween.md), [Clone-Image.ps1](Clone-Image.md) with `-Upscale` | + +These must be persistent user or system variables. An agent shell may not inherit variables set only in an interactive session. + +## Check the Environment + +Run these once before the first use in a session: + +```powershell +pwsh --version +ffmpeg -version +ffprobe -version +Get-Command rife-ncnn-vulkan +Get-Command upscayl-bin +"RIFE_HOME=$env:RIFE_HOME" +"UPSCAYL_HOME=$env:UPSCAYL_HOME" +"NCNN_GPU_ID=$env:NCNN_GPU_ID" +``` + +If anything is missing or empty, **stop**. Tell the user exactly what is missing and point to [index.md](index.md) (prerequisites), [RIFE.md](RIFE.md) or [Upscalers.md](Upscalers.md). Do not install software or change environment variables without the user's approval. + +## Installation and Location + +- Git: `git clone https://git.gurusushi.dyndns.org/guru/Video-Processing-Scripts.git` (repository `guru/Video-Processing-Scripts`). +- SVN: `public-svn`, project `Video Processing Scripts`. +- The script folder must be on `PATH` so scripts can be called from any directory. +- `Update-Video-Processing-Scripts.cmd` updates a Git copy to the latest version. Run it only with the user's approval. + +## How to Run the Scripts + +- Always call a script as `pwsh -NoProfile -File