Skip to content

短片模式 + punch 风格包 + 按手机观看验收(安全区、钩子帧、封面) - #4

Merged
runanshao merged 2 commits into
mainfrom
claude/exciting-johnson-64owsd
Oct 8, 2026
Merged

runanshao merged 2 commits into
mainfrom
claude/exciting-johnson-64owsd

Conversation

@runanshao

Copy link
Copy Markdown
Owner

内容

这个 PR 包含两个提交:

1. 7b0eaed 短片模式、punch 风格包、交付级声音(来自 iterate-punch 分支)

  • 节拍网格 promo/promo.json + src/promo/:没有旁白的 15 秒竖屏短片,cue 写成「小节:拍」,转场在重拍上收住
  • punch 风格包:Slam 砸字、HUD、跑马灯、徽章、卡片轮播、图案填充字、LogoReveal、CTA 条;<Burst> 粒子
  • 声音:score.py / synth.py 按同一网格写配乐,master.py 母带到 -14 LUFS,audio-report.py 分段响度报告;copy_lint.py(广告法绝对化用语);trace-logo.py;WAV 写入 LIST/INFO 块,修复 Windows 上的 kill EBADF

2. e5bbdcd 按观众在手机上看到的样子验收

  • src/core/probe.tsx:在浏览器里测每段可读文字的实际位置(缩放、遮罩、透明度都算进去),超出平台安全区(promo.json 的 safe:状态栏、底部标题区、右侧按钮栏)或被画面边缘切掉就画红框;本来就要出画的装饰用 <Free> / data-copy="free" 标出
  • verify 第 5 关改为「短片在手机上读得到」:抽查第 0 帧(必须有字)、每个 cue 定住后的那一帧、转场中点、封面帧;promo-sheet 用同一套抽帧;promo.mjs 渲染前先跑这项检查,出片后导出 out/<id>-cover.png
  • p1–p7 重新排版:旧版测出 48 处文字在遮挡区,现在 0 处;第一记砸字在第 0 帧就已到位
  • 屏幕上的数量从 PACKS 推出(「十套风格包」「06 OF 10」);新加测试核对 PACKS 与磁盘上的风格包一致,并拦截手写的数量
  • docs/principles.md 新增第 8 条「按观众看到的样子验收,不按画布」;new-promo、review 两个 skill 和 README 同步更新

验证

  • npm run verify 8 关全部通过(类型、24 个测试、3 种画幅渲染、确定性、短片安全区、短片确定性)
  • node tools/promo.mjs:-14.1 LUFS,真峰值 -2.1 dBTP,LRA 2.9

未改动(待定)

  • 结尾 CTA 网址仍为滚动条(已移入安全区,但始终看不全)
  • 开头「讲解片」在第 0 帧已落定,看不到砸下来的过程

🤖 Generated with Claude Code

https://claude.ai/code/session_01Hf6CivwFE1rx9Hf8pbNvaS


Generated by Claude Code

Runan and others added 2 commits October 7, 2026 09:00
Short ads and brand films have no narration, so their clock is the music:
promo/promo.json sets bpm, key and per-scene bars/energy/transition/cues
("bar:beat"); scenes read frames with usePromo(); tools/score.py writes the
score on the same grid. A 15 s 9:16 demo (7 scenes, 128 bpm) promotes the kit.

- core: land()/squash() so hits arrive on their frame, <Burst> ballistic
  particles, shared font loading, SfxMute for frozen transition copies
- punch pack: Slam (RGB split), Hud, Marquee, Badge, CardStrip with motion
  blur, PatternText, Wipe, LogoReveal, CtaBar; works as a Look too
- sound: synth.py instruments + energy-normalized reverb + sidechain;
  master.py measures, applies linear gain and a look-ahead limiter, and checks
  true peak on the AAC-encoded file; mix.py now masters to loudness.target
  (-16, 9x16 -14); audio-report.py prints per-section loudness and draws
  waveform/spectrogram; five new sfx (impact, riser, revcrash, shimmer, rush)
- tools: trace-logo.py (logo image -> vector parts), copy_lint.py (absolute
  claims barred by China's Advertising Law), promo.mjs, promo-sheet.mjs
- verify: two promo stages (every cue renders; determinism)
- fix: WAVs written by Python's wave module (minimal header) crash Remotion
  4.0.532 renders on Windows with "kill EBADF"; every scene WAV is now written
  with a LIST/INFO chunk via wav_bytes(), enforced by a test
- fix: demo s08 coin/levelup sfx were ~3.5 LU hotter than neighbouring scenes
- docs: principle 1 generalized to "one time source: the sound", principle 7
  "measure the sound to delivery spec"; README, CLAUDE.md, new-promo skill

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- src/core/probe.tsx: measures every readable text box on the rendered frame
  (transforms, masks, opacity included) against promo.json "safe" (status bar,
  caption line, button rail); <Free> / data-copy="free" for decoration
- verify stage 5 and promo-sheet probe frame 0 (must carry copy), every cue
  once settled, transition midpoints and the cover; failures outlined in red
- promo.mjs runs the safe-area check before rendering and exports
  out/<id>-cover.png from promo.json "cover"
- relayout p1-p7 so all copy is inside the safe area; the first slam lands
  on frame 0
- pack counts on screen derive from PACKS (now all 10 packs); tests check
  PACKS against the packs on disk and reject hard-coded counts
- principle 8 in docs/principles.md; new-promo/review skills, README

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Hf6CivwFE1rx9Hf8pbNvaS
@runanshao
runanshao merged commit 643e0be into main Oct 8, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants