Communitygithub.com

heygen-com/hyperframes

一連串帶斜角的長方體在行進波上移動,形成內容輪播。HyperFrames 區塊,1920×1080,6.666666666666667 秒,40 個變數。

hyperframes 是什麼?

這是一個用於 AI 代理技能 Hyperframes 的 3D 內容輪播區塊,名為「Cuboid Carousel」。它讓一組帶有圓角與斜角裝飾的長方體作為卡片內容的載體,以剛性群組方式從右側飛入,過程中每個長方體會產生錯開的旋轉動畫,接著減速並停留在英雄卡片位置,最後向左側離開。所有長方體之間的間距是根據其尺寸與最大可觸及的 X 軸半徑動態計算,確保彼此永不重疊。此區塊支援 Claude Code、Cursor 和 Codex 等 AI 代理平台的安裝與渲染,並提供高達 40 個可調整變數(如幾何、材質、燈光、陰影、背景、攝影機及每個動畫階段的持續時間與緩動函數)。其運行時依賴 WebGL、GSAP 與 Three.js,並採用純時間函數計算每一幀畫面,保證 seek 安全性,因此非常適合用於動態內容展示,無需擔心播放狀態的同步問題。

相容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/heygen-com/hyperframes/tree/main/registry/blocks/cuboid-carousel

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

長方體輪播

帶有圓角與斜角裝飾的長方體承載卡片內容,以剛性群組方式從右側飛入,飛行時每個長方體產生錯開的旋轉,接著減速並停留在英雄卡片位置,最後向左側離開。間距是根據長方體尺寸與最大可觸及的 X 軸半徑動態計算,確保長方體永不重疊。總共 40 個變數承載原始的 DialKit 結構:幾何、材質、燈光、陰影、背景、攝影機以及每個動畫階段的持續時間與緩動函數。卡片來自內建列表或一個 JSON 變數。

組合 ID:cuboid-carousel。持續時間 6.666666666666667 秒,幀率 30 fps,解析度 1920×1080。

檔案

  • cuboid-carousel.html(38 KB)
  • assets/Three-LICENSE.txt(1 KB)
  • assets/addons/environments/RoomEnvironment.js(5 KB)
  • assets/addons/utils/BufferGeometryUtils.js(36 KB)
  • assets/cuboid-motion.js(593 KB)
  • assets/gsap-3.14.2.min.js(128 KB)
  • assets/GSAP-NOTICE.txt(1 KB)
  • assets/three.core.min.js(554 KB)
  • assets/three.module.min.js(468 KB)

安裝

使用 npx hyperframes add cuboid-carousel 安裝;預設情況下,上述檔案會放在 compositions/cuboid-carousel/ 目錄下。接著在主機的 index.html 中掛載此區塊:

<div
  data-composition-id="cuboid-carousel"
  data-composition-src="compositions/cuboid-carousel/cuboid-carousel.html"
  data-start="0"
  data-duration="6.666666666666667"
  data-track-index="1"
  data-width="1920"
  data-height="1080"
></div>

透過直接指定組合檔案,使用自訂值進行渲染:

npx --yes [email protected] render 'compositions/cuboid-carousel/cuboid-carousel.html' --variables '{"cardsJson":"","heroCard":4}'

變數

在執行時期透過 window.__hyperframes.getVariables() 讀取;在組合根元素上宣告為 data-composition-variables(使用單引號包裹的屬性,純 JSON 格式)。

id類型預設值標籤 / 範圍
cardsJson字串""內容 · 卡片 JSON(可選,請參閱原始碼中的 CARDS)
heroCard數字4內容 · 英雄卡片(從 1 開始)1–12 步長 1
count數字8內容 · 重複卡片數量 1–12 步長 1
gap數字0.01佈局 · 長方體之間的額外間距 0–1.5 步長 0.005
cuboidWidth數字1.7長方體 · 寬度 0.3–5 步長 0.01
cuboidHeight數字2.4長方體 · 高度 0.3–6 步長 0.01
cuboidDepth數字0.14長方體 · 厚度(深度)0.02–2 步長 0.01
cornerRadius數字0.105長方體 · 圓角半徑 0–0.6 步長 0.005
bevelSize數字0.03長方體 · 斜角大小(邊緣倒角)0–0.3 步長 0.001
bevelThickness數字0.04長方體 · 斜角厚度 0–0.3 步長 0.001
smoothness數字32長方體 · 平滑度(分段數)1–32 步長 1
bodyColor顏色"#242424"長方體 · 本體顏色
roughness數字0.6長方體 · 粗糙度 0–1 步長 0.01
metalness數字0.4長方體 · 金屬感 0–1 步長 0.01
heroScale數字1英雄 · 獨立縮放 1–1.6 步長 0.01
heroFillIntensity數字0.55英雄 · 面部光強度 0–2 步長 0.05
heroExitX數字288英雄 · 退出 X 旋轉角度 -720–720 步長 1
heroExitY數字-234英雄 · 退出 Y 旋轉角度 -720–720 步長 1
heroExitZ數字198英雄 · 退出 Z 旋轉角度 -720–720 步長 1
ambientIntensity數字0.35燈光 · 環境光強度 0–4 步長 0.01
ambientColor顏色"#ffffff"燈光 · 環境光顏色
topIntensity數字3.1燈光 · 上方燈組強度 0–12 步長 0.05
topColor顏色"#ffffff"燈光 · 上方燈組顏色
bottomIntensity數字2.15燈光 · 下方燈組強度 0–12 步長 0.05
bottomColor顏色"#ffcaad"燈光 · 下方燈組顏色
keyIntensity數字5燈光 · 主燈組強度 0–12 步長 0.05
keyColor顏色"#ffe9d6"燈光 · 主燈組顏色
shadowRadius數字44.5陰影 · 柔和度(貼圖尺寸 2048)0–50 步長 0.5
shadowMapSize數字2048陰影 · 貼圖尺寸 512–4096 步長 256
backdrop顏色"#0b0d13"背景 · 顏色
cameraFov數字11攝影機 · 初始視野 10–90 步長 0.5
cameraX數字-1.65攝影機 · 初始 X 座標 -20–20 步長 0.05
cameraY數字8.5攝影機 · 初始 Y 座標 -20–20 步長 0.05
cameraZ數字-8.508708攝影機 · 初始 Z 座標(距離)-20–50 步長 0.1
cameraSettleFrame數字70攝影機 · 穩定畫面(30 fps)20–90 步長 1
handheldStrength數字1攝影機 · 手持穩定強度 0–1 步長 0.05
cameraTargetFov數字34攝影機目標 · 視野 10–90 步長 0.5
cameraTargetX數字-7.25攝影機目標 · X 座標 -20–20 步長 0.05
cameraTargetY數字1.15攝影機目標 · Y 座標 -20–20 步長 0.05
cameraTargetZ數字6.2攝影機目標 · Z 座標 2–50 步長 0.1

執行時期合約

  • 一條暫停的 GSAP 時間軸註冊為 window.__timelines["cuboid-carousel"]。
  • 在 hf-seek 自訂事件發生時重新同步;每一幀畫面都是一個基於時間的封閉式函數(僅使用種子偽隨機數產生器,沒有 rAF 迴圈,沒有 Date.now)。
  • 渲染器:WebGL、GSAP、Canvas 2D、PMREM、陰影貼圖。每個實例預算約 350 MB;一次只執行一個。
  • 外部執行時期依賴:./assets/three.module.min.js、./assets/addons/。
  • 來自 Google Fonts 的網頁字型:Inter。

編輯規則(來自原始專案)

  1. 保持 data-composition-variables 為單引號包裹的屬性,內部為純 " JSON。切勿透過 Studio 的設計面板儲存它。
  2. 不要在靜態標記中放置 <canvas>;應在執行時期建立。
  3. 保持每個視覺狀態為 t 的函數;seek 安全性是讓此區塊可渲染的關鍵。

Individual skills in this repo

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

general-video

>

heygen-com/animejs

Anime.js adapter patterns for HyperFrames. Use when writing Anime.js animations or timelines inside HyperFrames compositions, registering animations on window.__hfAnime, making Anime.js seek-driven and deterministic, or translating Anime.js examples into render-safe HyperFrames HTML.

heygen-com/claude-design-hyperframes

Use when running inside Claude Design specifically. Produces a valid, brand-accurate HyperFrames video draft using pre-valid skeletons. For Claude Code / Cursor / Codex, use the `hyperframes` skill instead.

heygen-com/contribute-catalog

Author a new HyperFrames registry block (caption style, VFX block, transition, lower third) or component (text effect, overlay, snippet) and ship it as an upstream PR to the hyperframes repo. Use ONLY when the user wants to CONTRIBUTE to the public catalog — for in-project caption/transition authoring use the `hyperframes` skill, for installing existing registry items use the `hyperframes-registry` skill.

heygen-com/css-animations

CSS animation adapter patterns for HyperFrames. Use when authoring CSS keyframes, animation-delay based timing, animation-fill-mode, animation-play-state, or CSS-only motion that HyperFrames must seek deterministically during preview and rendering.

heygen-com/gsap

GSAP animation reference for HyperFrames. Covers gsap.to(), from(), fromTo(), easing, stagger, defaults, timelines (gsap.timeline(), position parameter, labels, nesting, playback), and performance (transforms, will-change, quickTo). Use when writing GSAP animations in HyperFrames compositions.

heygen-com/hyperframes

Leaves sweep through the frame and part to reveal the headline. HyperFrames block, 1920×1080, 12s, 11 variables.

heygen-com/hyperframes

Render-correctness doctrine for scene-to-scene seams in HyperFrames launch videos — the prerequisites that make transitions composite correctly on the master timeline. Load when assembling the master timeline / index.html, when a white flash appears at a cut or crossfade seam (especially on dark films), when reasoning about why a transition opacity dip shows through, or when verifying the render-side mechanics of how overlapping scene wrappers blend. Covers the opaque stage-ground (#root background) white-flash guard and how the injector overlaps wrappers, holds final frames, ping-pongs tracks, and stamps lint-clean template code onto the master timeline. Does NOT contain the per-transition catalog — see the transition registry for individual transition entries.

heygen-com/hyperframes

The technique catalog: five velocity-matched SEAMS (zoom-through, INVERSE zoom-through, cut-the-curve, waterfall cut, rack-focus blur-cut) plus the two in-scene techniques — waterfall ENTRY (staggered arrival cascades for title cards / segment openers) and the nudge curve (slow-fast-slow three-phase group slides). Covers partial-travel (~12% of frame) velocity matching via mirrored power4 eases, the Z scale-sign rule, size-scaled blur (10px text / 18-20px full-frame), word-by-word staggered cuts, cascade pacing by element weight, and the 10/65/25 slide ratio. Read before authoring any transition, text-beat handoff, kinetic text entry, or group reposition. [depth, zoom, inverse-zoom, scale-sign, mirrored-zoom, rack-focus, pacing, velocity, cut-the-curve, waterfall, stagger, cascade, kinetic-text, title-card, segment-opener, nudge, slide, easing, group-motion, z-depth, motion-graphics, cinematic, transition, blur, directional-continuity]

heygen-com/hyperframes

A single feature card orbits a dot sphere on approved Blender camera motion. HyperFrames block, 1920×1080, 10s, 4 variables.

heygen-com/hyperframes

A wireframe portal bursts open, the title comes through, then its letters swap into a second phrase. HyperFrames block, 1920×1080, 8s, 9 variables.

heygen-com/hyperframes

Glass shards fly in through fog and tile themselves into the headline. HyperFrames block, 1920×1080, 12.16s, 19 variables.

heygen-com/hyperframes

House-style oversized macOS cursor technique for HyperFrames launch videos. Load whenever a scene involves cursors or a pointer-led action, when kicking off a UI scene, when igniting a morph/transition/typing run with a click, or when a scene reads as static, dead, or stale and needs a cheap high-yield source of motion to carry the viewer's eye and segment them out of the stale state. Covers cursor size/look (incl. brand-motif cursors), the off-screen entry law, tip-targeting and the click tap, click-ignites-the-next-beat, and exit / cross-scene handoff.

heygen-com/hyperframes

An orbiting camera follows an ice logo as it breaks apart, reforms into two text moments, and fades. HyperFrames block, 1920×1080, 22.5s, 216 variables.

heygen-com/hyperframes

name: embedded-captions

heygen-com/hyperframes

A tiled headline surface flips cell by cell under a sweeping depth field to reveal the rear headline. HyperFrames block, 1920×1080, 8s, 18 variables.

heygen-com/hyperframes

Turn arbitrary text — an article, notes, a topic, a brief — into a faceless explainer video: there is no site or footage to capture, so the visuals are invented per scene (typography, abstract graphics, diagrams, data-viz). Use for topic explainers, concept breakdowns, how-tos, listicles. Not a video built from a website (/product-launch-video — promo or tour). Unclear → /hyperframes.

heygen-com/hyperframes

Import Figma content into a HyperFrames composition — rendered assets, brand tokens, components, storyboard sections → reconstructed motion (frames read as states, not slides) (REST/CLI), connector-assisted motion when available, and shaders from a connector or native export. Use when the user pastes a figma.com link or asks to bring a Figma design, frame, logo, brand, or animation into a video/composition.

heygen-com/hyperframes

GATEWAY — load FIRST before composing any HyperFrames animation or video. The high-level motion law that makes a multi-scene video feel like ONE continuous camera move instead of a stack of independently-animated slides. Covers the vector law (how you exit determines how you enter, incl. the Z scale-sign rule), the film's current, carrier elements, causal motion, the Seam Gate (build-gate enforcement), the ban on idle wobble (motion must PERFORM, not breathe), stillness-before-climax, and the sustained-motion routes. Routes to the low-level technique skills (cut-the-curve — the full catalog incl. waterfall entry + nudge curve, oversized-cursor, seam-craft). These rules SUPERSEDE generic / upstream motion guidance. [continuity, direction, vector, momentum, seam, transition, ease, performance, idle-motion, narrative-motion, film-grammar]

heygen-com/hyperframes

Turn a weekly changelog .md into a finished branded changelog video (square 1080, ~45-60s, Annie VO, animated brand background, mock-UI visualizations, lowkey captions). Use when the user provides a changelog/digest markdown and wants the weekly video, or says "changelog video". Self-contained — fonts, background, lexicon, and scripts ship in this skill.

相關技能