Communitygithub.com

SingleGrain-Team/video-skills

构建一个6-8秒的Logo开场动画:品牌标志在折射的液体珠内扭曲至无法辨认,珠子膨胀、静止片刻、破裂成液滴,最终标志与文字标清晰直立显示。输出为1920x1080 H.264 MP4视频和可编辑的HyperFrames项目文件。

video-skills 是什么?

该技能通过WebGL(Three.js)创建物理传输、噪声位移表面和色散的玻璃珠,放置在Logo前方。Logo被强烈折射至无法阅读,随后压力积聚,一切冻结片刻,珠子破裂,15个液滴飞散,标志左滑,文字标从后方擦出。所有帧都是搜索时间的纯函数,因此渲染是确定性的。支持从SVG或PNG(包括纯位图Logo)、文字标字符串和配色板生成品牌开场、片尾、产品发布开场、频道角标等“展示Logo”场景。输出为1920x1080 H.264 MP4以及完整的HyperFrames可编辑项目,无需3D模型、素材或生成模型。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/SingleGrain-Team/video-skills/tree/HEAD/skills/liquid-logo-reveal

在你喜欢的 AI 中提问

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

文档

Liquid logo reveal

一个WebGL(Three.js)玻璃珠,具有物理传输、噪声位移表面和色散效果,位于Logo前方。Logo被强烈折射,无法阅读。压力积聚,一切静止片刻,珠子破裂,15个液滴飞散,标志向左滑动,同时文字标从后方擦出。所有帧都是搜索时间的纯函数,因此渲染是确定性的。

输入

输入备注
Logo标志SVG或PNG。仅标志(符号),接近正方形,透明背景。
文字标字符串,默认使用Inter字体排版。如果品牌有实际文字标图形,请参阅“文字标作为图形”。
配色板三种颜色:强烈的强调色、柔和的淡色调、柔和的中间色。它们成为玻璃后方模糊的色场;玻璃无色,只显示其后的内容。文字标的墨水颜色。
时长默认7秒。锁定后保持静止的部分是可以拉伸的。

仅使用用户提供的或品牌套件中的资源。切勿从网络获取Logo。

纯位图Logo

  • 模板需要带Alpha通道的PNG。如果Logo有不透明背景(JPG、白色方框),先移除背景(npx hyperframes remove-background,或要求用户提供透明文件)。不要将白色方块折射到珠子里。
  • 小PNG(约600px以下)也可以,因为标志静止时显示约250px,但在珠内会放大至约360px。请保持源文件长边至少512px。
  • 裁剪透明边距,使可见标志充满图像;代码设定图像框大小,而非墨水区域。
  • SVG:栅格化为长边约1720px的PNG(无头Chrome截图或rsvg-convert -w 1720),保留Alpha通道,并将data-logo-src指向该PNG。不要重绘或重新着色Logo。
  • 如果品牌Logo是组合锁定图像(标志和文字融合),无法干净拆分。将整个锁定图像作为标志,设置data-wordmark="",并跳过文字标擦除效果(将文字标剪辑始终设为隐藏)。此时标志停靠在中心,而非左侧。

构建流程

  1. 初始化项目:npx --yes hyperframes init <dir> -e blank --non-interactive --skip-skills,然后用该技能的 template/index.html 替换其 index.html,并复制 template/js/、template/assets/logo.png(用品牌标志覆盖)。
  2. 供应商运行时确保渲染不依赖网络。在临时目录中(不要在另一个项目内运行,npm i 会向上查找最近的 package.json)执行 npm i [email protected] [email protected] @fontsource-variable/inter,然后复制到项目中:
    • gsap/dist/gsap.min.js 到 vendor/gsap.min.js
    • three/build/three.module.js 和 three/build/three.core.js 到 vendor/three/build/
    • three/examples/jsm/environments/RoomEnvironment.js 到 vendor/three/examples/jsm/environments/
    • @fontsource-variable/inter/files/inter-latin-wght-normal.woff2 到 assets/fonts/
  3. 在 index.html 的 #root 上使用数据属性配置品牌:data-logo-src、data-wordmark、data-ink、data-fields(三个十六进制颜色)。保持色场在强调色处饱和,其他部分柔和;切勿使珠子中心后方的色场黑暗平坦。
  4. 检查并清理:npx --yes hyperframes lint 然后 npx --yes hyperframes check。两者都必须通过。
  5. 帧审查(如下)。调整。重复。
  6. 渲染:npx --yes hyperframes render --workers 2 --output final.mp4。通过 ffprobe 检查:应报告h264、1920x1080、30fps、预期时长。

运动规则(格式成功的关键)

  • 无法阅读,而非不可见。 在破裂前,观众应看到标志的颜色和扭曲形状,无法辨认。如果某帧标志清晰可辨,提高 thickness / 位移幅度 / 旋转;如果珠子是扁平块状且无标志痕迹,则降低它们。
  • 标志位于玻璃后方,在不透明通道中。 破裂前的平面使用 alphaTest(不透明队列),使Three.js的传输通道可以折射它。使用 transparent: true 的普通平面不会被折射。“揭示”后的副本是透明的,仅在珠壳崩溃后切换显示。
  • 阶段顺序(所有常量定义在 js/liquid-reveal.js 顶部的 T 中):建立(近景到完整珠子,0.7秒),然后液体表演,压力积聚(珠子变宽变平,标志放大1.00至1.06),逗号(0.4秒完全静止:相机、标志、珠子和着色器时钟冻结),破裂(珠壳在0.2秒内以四次方缓动崩溃,液滴径向发射),停靠(标志回弹然后向左滑动到锁定位置,同时文字标从后方擦出),保持。
  • 静止是关键。 破裂前的0.4秒冻结才使破裂效果令人信服。不要有任何呼吸、浮动或循环发光。
  • 着色器时钟受控。 噪声时间仅在设定窗口内推进,在逗号和停靠后冻结。
  • 文字标从标志后方出现,从不弹入。 其剪辑左边缘跟随标志右边缘,因此文字在停靠过程中不会被标志覆盖。
  • 液滴:黄金角固定布局(无 Math.random),径向发射,一个重力项,然后缩小至消失,最终帧干净。
  • 最终画面为静止锁定状态。 标志和文字标直立居中成对,无淡出。如果是用于较长视频的开场,缩短保持时间而非淡出。
  • 确定性:一切从 hf-seek 时间计算得出。无 requestAnimationFrame、Date.now、Math.random。唯一的DOM测量是文字标宽度,在加载时测量一次(使用搭载字体通过 Canvas measureText 测量)。

调节旋钮

期望效果修改项
更长或更短T 常量和 #root 及两个 .clip 元素上的 data-duration(保持相等)
更抽象的珠子提高 thickness(3.2)或位移幅度(0.15);降低则更可读
果冻 vs 液滴外观liquidMaterial() 中的 dispersion、attenuationColor
更大或更小的锁定组合L.markPx、L.fontPx、L.gap
更平静的背景降低背景着色器中三个 * 0.50 / 0.80 / 0.35 的场权重

文字标作为图形

如果品牌提供文字标SVG/PNG,将 #wordmark 文本替换为具有相同位置和宽度逻辑的 <img>:测量其宽高比,设置高度为 L.fontPx * 0.8,并保持相同的 clip-path 逻辑。切勿使用替代字体重新键入风格化的文字标。

验证

  • lint 和 check 必须通过(lint错误会静默禁用布局审计)。
  • 提取帧并查看:npx --yes hyperframes snapshot --at 0.3,1.5,3.3,3.55,3.9,6.5 并打开 snapshots/contact-sheet.jpg,或在渲染上执行 ffmpeg -ss <t> -i final.mp4 -frames:v 1 f.png。验证:(1)早期帧显示珠子中标志无法阅读,(2)破裂后立即的帧文字标不与标志重叠,(3)停靠过程中的文字被标志边缘剪辑,(4)最终帧显示清晰标志和文字标、居中、无液滴、无被剪辑字形。
  • 常见失败:空白画布(importmap路径错误,或WebGL three.core.js 未复制)、文字标不居中(测量前字体未加载)、带白色方框的Logo(不透明PNG)。

交付

交付 final.mp4 和项目文件夹(index.html、js/、assets/、vendor/),以便通过编辑 data-* 属性进行品牌更换。音频可选;破裂时间 T.pop 处的简短破裂音效是片段的唯一声音。通过 media-use 技能使用商业许可音源,否则静音交付。

Individual skills in this repo

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

SingleGrain-Team/video-skills

Make a 30-45 second launch film for a product by staging it inside one persistent, neutral chat window. A user types a request, the assistant answers and calls the product as a connected tool, a progress card runs, a follow-up triggers a second tool action, and the result lands as a count-up headline number before closing on the logo, tagline and call to action. Use when you need a launch, feature or integration announcement video for something that plugs into AI assistants (a skill, MCP server, plugin, connector, CLI). Delivers a rendered 1920x1080 MP4 plus an editable single-file HyperFrames project.

SingleGrain-Team/video-skills

Build a motion graphic where a screen recording plays in a large frame beside a checklist, and each checklist item ticks off at the exact moment that step happens in the recording, ending with every item checked and a short hold. Use when someone has a screen recording (product walkthrough, tutorial, onboarding, install demo) plus a list of steps with timestamps and wants a "watch the steps get done" film. Input is a recording, step labels with timestamps, a title and an optional palette; output is a 1920x1080 H.264 MP4 and the editable HyperFrames project.

SingleGrain-Team/video-skills

Build a 15-20 second product launch film that shows the product's real screen on a laptop built from plain CSS (no 3D model, no generation model) in a dark studio, scrolls the page, zooms into the interface for one key action such as typing a search, and resolves to the logo lockup. Use when someone has a full-page screenshot or screen recording of their product, one action worth showing, and a logo, and wants a short silent-friendly launch teaser rendered as a 1920x1080 MP4 with an editable HyperFrames project.

SingleGrain-Team/video-skills

Make a 20-30 second launch film for a product that is not tied to one interface, such as a CLI, package, plugin or agent skill. The identical prompt or command is typed into four visually different surfaces in turn (a wide terminal, a tall chat card, a floating palette, an editor cell), the film then hard-cuts into a fast reel of real outputs on a beat or fixed tempo grid, and it closes on the command in a large pill. Delivered as a rendered 1920x1080 MP4 plus the editable HyperFrames project. Music is optional - with a track the cuts land on detected beats, without one they land on a 120 bpm grid.

SingleGrain-Team/video-skills

Make a roughly 30-second film that explains a code change (a pull request, release or uncommitted diff) to people who will never read the diff. It opens by showing the real diff scrolling past too fast to follow, cuts to a plain-language summary, fires four capability beats each pinned to a real code snippet, and closes on how to get it (install command and URL). Delivered as a 1920x1080 H.264 MP4 plus the editable HyperFrames project. Use when asked to turn a PR, changelog or release into a launch or explainer video.

SingleGrain-Team/video-skills

Render a 5-6 second motion graphic in which an oversized condensed headline (2-4 words) punches in behind a presenter, using a background-removed cutout of the presenter layered on top of the lettering. A hard cut then removes the presenter while the same headline holds the exact same size and position, and a short supporting line appears for a reading hold. Use it for talking-head intros, chapter openers, launch announcements and social hooks when you have one presenter clip, a headline, a supporting line and a palette. Built on HyperFrames; delivers a 1920x1080 H.264 MP4 plus the editable project.

SingleGrain-Team/video-skills

Builds a 10-14 second product sting out of a short run of UI moments (an entry screen, a single counting metric, a navigation list, one click that opens a menu, then an endcard) cut together so every cut carries the previous motion forward and the piece reads as one continuous camera move. Delivered as a 1920x1080 H.264 MP4 plus an editable single-file HyperFrames project. Use it for app launches, feature teasers, social bumpers and site intros when you have a product's logo, a couple of screenshots, one headline number and its real nav labels, and want polished UI motion without narration.

相关技能