@biunow/agent-biuart 0.0.0-stage → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (377) hide show
  1. package/bin/server.mjs +575 -0
  2. package/data/styles.json +533 -0
  3. package/engine/audit_clip.py +46 -0
  4. package/engine/clip.html +24 -0
  5. package/engine/clip.js +104 -0
  6. package/engine/clip_schema.json +19 -0
  7. package/engine/clips/t1_3b1b.js +203 -0
  8. package/engine/clips/t2_keynote_ui.js +347 -0
  9. package/engine/clips/t3_finance_chart.js +206 -0
  10. package/engine/clips/y1_kurzgesagt.js +183 -0
  11. package/engine/clips/y2_vox.js +150 -0
  12. package/engine/clips/y3_whiteboard.js +209 -0
  13. package/engine/clips/y4_storytime.js +194 -0
  14. package/engine/clips/y5_kinetic_type.js +134 -0
  15. package/engine/compare.py +19 -0
  16. package/engine/demos/_shared/hero/c1_0.png +0 -0
  17. package/engine/demos/_shared/hero/c1_1.png +0 -0
  18. package/engine/demos/_shared/hero/c1_2.png +0 -0
  19. package/engine/demos/_shared/hero/c3_line.png +0 -0
  20. package/engine/demos/_shared/hero.js +96 -0
  21. package/engine/demos/long_scroll/eras.js +23 -0
  22. package/engine/demos/long_scroll/frames/8bit_act/01.png +0 -0
  23. package/engine/demos/long_scroll/frames/8bit_act/02.png +0 -0
  24. package/engine/demos/long_scroll/frames/8bit_act/03.png +0 -0
  25. package/engine/demos/long_scroll/frames/8bit_act/04.png +0 -0
  26. package/engine/demos/long_scroll/frames/8bit_act/05.png +0 -0
  27. package/engine/demos/long_scroll/frames/8bit_act/06.png +0 -0
  28. package/engine/demos/long_scroll/frames/8bit_act/07.png +0 -0
  29. package/engine/demos/long_scroll/frames/8bit_act/08.png +0 -0
  30. package/engine/demos/long_scroll/frames/8bit_act/meta.json +69 -0
  31. package/engine/demos/long_scroll/frames/8bit_walk/01.png +0 -0
  32. package/engine/demos/long_scroll/frames/8bit_walk/02.png +0 -0
  33. package/engine/demos/long_scroll/frames/8bit_walk/03.png +0 -0
  34. package/engine/demos/long_scroll/frames/8bit_walk/04.png +0 -0
  35. package/engine/demos/long_scroll/frames/8bit_walk/05.png +0 -0
  36. package/engine/demos/long_scroll/frames/8bit_walk/06.png +0 -0
  37. package/engine/demos/long_scroll/frames/8bit_walk/07.png +0 -0
  38. package/engine/demos/long_scroll/frames/8bit_walk/08.png +0 -0
  39. package/engine/demos/long_scroll/frames/8bit_walk/meta.json +69 -0
  40. package/engine/demos/long_scroll/frames/egypt_dodge/01.png +0 -0
  41. package/engine/demos/long_scroll/frames/egypt_dodge/02.png +0 -0
  42. package/engine/demos/long_scroll/frames/egypt_dodge/03.png +0 -0
  43. package/engine/demos/long_scroll/frames/egypt_dodge/04.png +0 -0
  44. package/engine/demos/long_scroll/frames/egypt_dodge/05.png +0 -0
  45. package/engine/demos/long_scroll/frames/egypt_dodge/06.png +0 -0
  46. package/engine/demos/long_scroll/frames/egypt_dodge/07.png +0 -0
  47. package/engine/demos/long_scroll/frames/egypt_dodge/08.png +0 -0
  48. package/engine/demos/long_scroll/frames/egypt_dodge/meta.json +69 -0
  49. package/engine/demos/long_scroll/frames/egypt_walk8/01.png +0 -0
  50. package/engine/demos/long_scroll/frames/egypt_walk8/02.png +0 -0
  51. package/engine/demos/long_scroll/frames/egypt_walk8/03.png +0 -0
  52. package/engine/demos/long_scroll/frames/egypt_walk8/04.png +0 -0
  53. package/engine/demos/long_scroll/frames/egypt_walk8/05.png +0 -0
  54. package/engine/demos/long_scroll/frames/egypt_walk8/06.png +0 -0
  55. package/engine/demos/long_scroll/frames/egypt_walk8/07.png +0 -0
  56. package/engine/demos/long_scroll/frames/egypt_walk8/08.png +0 -0
  57. package/engine/demos/long_scroll/frames/egypt_walk8/meta.json +69 -0
  58. package/engine/demos/long_scroll/frames/monet_throw/01.png +0 -0
  59. package/engine/demos/long_scroll/frames/monet_throw/02.png +0 -0
  60. package/engine/demos/long_scroll/frames/monet_throw/03.png +0 -0
  61. package/engine/demos/long_scroll/frames/monet_throw/04.png +0 -0
  62. package/engine/demos/long_scroll/frames/monet_throw/05.png +0 -0
  63. package/engine/demos/long_scroll/frames/monet_throw/06.png +0 -0
  64. package/engine/demos/long_scroll/frames/monet_throw/07.png +0 -0
  65. package/engine/demos/long_scroll/frames/monet_throw/08.png +0 -0
  66. package/engine/demos/long_scroll/frames/monet_throw/meta.json +71 -0
  67. package/engine/demos/long_scroll/frames/monet_walk/01.png +0 -0
  68. package/engine/demos/long_scroll/frames/monet_walk/02.png +0 -0
  69. package/engine/demos/long_scroll/frames/monet_walk/03.png +0 -0
  70. package/engine/demos/long_scroll/frames/monet_walk/04.png +0 -0
  71. package/engine/demos/long_scroll/frames/monet_walk/05.png +0 -0
  72. package/engine/demos/long_scroll/frames/monet_walk/06.png +0 -0
  73. package/engine/demos/long_scroll/frames/monet_walk/07.png +0 -0
  74. package/engine/demos/long_scroll/frames/monet_walk/08.png +0 -0
  75. package/engine/demos/long_scroll/frames/monet_walk/meta.json +71 -0
  76. package/engine/demos/long_scroll/lib/acts.js +87 -0
  77. package/engine/demos/long_scroll/lib/crossing.js +463 -0
  78. package/engine/demos/long_scroll/lib/world.js +143 -0
  79. package/engine/demos/long_scroll/lib/xing2_ding.js +42 -0
  80. package/engine/demos/long_scroll/lib/xing2_jia.js +114 -0
  81. package/engine/demos/long_scroll/lib/xing2_yi.js +133 -0
  82. package/engine/demos/long_scroll/segments/02_egypt.js +234 -0
  83. package/engine/demos/long_scroll/segments/14_8bit.js +118 -0
  84. package/engine/demos/long_scroll/segments/28_monet.js +86 -0
  85. package/engine/demos/t1_3b1b/eras.js +11 -0
  86. package/engine/demos/t1_3b1b/t1_s1.js +101 -0
  87. package/engine/demos/t1_3b1b/t1_s2.js +74 -0
  88. package/engine/demos/t1_3b1b/t1_s3.js +65 -0
  89. package/engine/demos/t2_keynote_ui/eras.js +10 -0
  90. package/engine/demos/t2_keynote_ui/t2_s1.js +57 -0
  91. package/engine/demos/t2_keynote_ui/t2_s2.js +70 -0
  92. package/engine/demos/t2_keynote_ui/t2_s3.js +61 -0
  93. package/engine/demos/t3_finance_chart/eras.js +11 -0
  94. package/engine/demos/t3_finance_chart/t3_s1.js +48 -0
  95. package/engine/demos/t3_finance_chart/t3_s2.js +42 -0
  96. package/engine/demos/t3_finance_chart/t3_s3.js +51 -0
  97. package/engine/demos/y1_kurzgesagt/eras.js +10 -0
  98. package/engine/demos/y1_kurzgesagt/kurzgesagt.js +347 -0
  99. package/engine/demos/y2_vox/eras.js +10 -0
  100. package/engine/demos/y2_vox/vox.js +240 -0
  101. package/engine/demos/y3_whiteboard/eras.js +10 -0
  102. package/engine/demos/y3_whiteboard/whiteboard.js +162 -0
  103. package/engine/demos/y4_storytime/eras.js +14 -0
  104. package/engine/demos/y4_storytime/s1_desk.js +18 -0
  105. package/engine/demos/y4_storytime/s2_screen.js +82 -0
  106. package/engine/demos/y4_storytime/s3_react.js +39 -0
  107. package/engine/demos/y4_storytime/s4_wide.js +16 -0
  108. package/engine/demos/y4_storytime/s5_close.js +18 -0
  109. package/engine/demos/y4_storytime/story.js +25 -0
  110. package/engine/demos/y4_storytime/vo_env.js +2 -0
  111. package/engine/demos/y4_storytime/world.js +73 -0
  112. package/engine/demos/y5_kinetic_type/eras.js +16 -0
  113. package/engine/demos/y5_kinetic_type/k1_title.js +38 -0
  114. package/engine/demos/y5_kinetic_type/k2_complete.js +55 -0
  115. package/engine/demos/y5_kinetic_type/k3_chat.js +47 -0
  116. package/engine/demos/y5_kinetic_type/k4_agent.js +49 -0
  117. package/engine/demos/y5_kinetic_type/kinetic.js +52 -0
  118. package/engine/engine.js +277 -0
  119. package/engine/eras.js +60 -0
  120. package/engine/eras_gallery.js +115 -0
  121. package/engine/eras_style_studies.js +20 -0
  122. package/engine/examples/assets/K/347/272/277/345/233/276_/346/250/252/345/261/217.png +0 -0
  123. package/engine/examples/assets//347/273/210/347/253/257_for/345/276/252/347/216/257/346/261/202/345/222/214.png +0 -0
  124. package/engine/examples/assets//347/273/210/347/253/257_sum/346/261/202/345/222/214.png +0 -0
  125. package/engine/examples/assets//350/220/245/346/224/266/345/233/276_/347/253/226/345/261/217.png +0 -0
  126. package/engine/examples/assets//350/264/242/347/273/217/345/233/276/350/241/250_/346/250/252/345/261/217.png +0 -0
  127. package/engine/examples/t1_3b1b.json +19 -0
  128. package/engine/examples/t2_fullbleed_pulse.json +15 -0
  129. package/engine/examples/t2_keynote_ui.json +15 -0
  130. package/engine/examples/t3_finance_chart.json +29 -0
  131. package/engine/examples/y1_kurzgesagt.json +16 -0
  132. package/engine/examples/y2_vox.json +14 -0
  133. package/engine/examples/y3_whiteboard.json +17 -0
  134. package/engine/examples/y4_storytime.json +52 -0
  135. package/engine/examples/y5_kinetic_type.json +14 -0
  136. package/engine/index.html +42 -0
  137. package/engine/lib/THREE_LICENSE.txt +21 -0
  138. package/engine/lib/brush.js +149 -0
  139. package/engine/lib/camera.js +99 -0
  140. package/engine/lib/chart.js +152 -0
  141. package/engine/lib/collage.js +97 -0
  142. package/engine/lib/diagram.js +264 -0
  143. package/engine/lib/finish.js +70 -0
  144. package/engine/lib/fonts/AlfaSlabOne-400.woff +0 -0
  145. package/engine/lib/fonts/Anton-400.woff +0 -0
  146. package/engine/lib/fonts/ArchivoBlack-400.woff +0 -0
  147. package/engine/lib/fonts/Bangers-400.woff +0 -0
  148. package/engine/lib/fonts/Caveat-600.woff +0 -0
  149. package/engine/lib/fonts/Cinzel-400.woff +0 -0
  150. package/engine/lib/fonts/Cinzel-700.woff +0 -0
  151. package/engine/lib/fonts/CormorantGaramond-500.woff +0 -0
  152. package/engine/lib/fonts/CormorantGaramond-500i.woff +0 -0
  153. package/engine/lib/fonts/CormorantGaramond-700.woff +0 -0
  154. package/engine/lib/fonts/EBGaramond-400.woff +0 -0
  155. package/engine/lib/fonts/EBGaramond-400i.woff +0 -0
  156. package/engine/lib/fonts/EBGaramond-600.woff +0 -0
  157. package/engine/lib/fonts/Exo2-800i.woff +0 -0
  158. package/engine/lib/fonts/GochiHand-400.woff +0 -0
  159. package/engine/lib/fonts/IMFellEnglish-400.woff +0 -0
  160. package/engine/lib/fonts/IMFellEnglish-400i.woff +0 -0
  161. package/engine/lib/fonts/Inter-var.woff +0 -0
  162. package/engine/lib/fonts/JosefinSans-700.woff +0 -0
  163. package/engine/lib/fonts/Kalam-700.woff +0 -0
  164. package/engine/lib/fonts/LICENSES.md +40 -0
  165. package/engine/lib/fonts/LXGWWenKai-500.woff +0 -0
  166. package/engine/lib/fonts/LibreBaskerville-400.woff +0 -0
  167. package/engine/lib/fonts/LibreBaskerville-700.woff +0 -0
  168. package/engine/lib/fonts/LilitaOne-400.woff +0 -0
  169. package/engine/lib/fonts/Marcellus-400.woff +0 -0
  170. package/engine/lib/fonts/NotoSansSC-500.woff +0 -0
  171. package/engine/lib/fonts/NotoSansSC-700.woff +0 -0
  172. package/engine/lib/fonts/NotoSansSC-800.woff +0 -0
  173. package/engine/lib/fonts/NotoSansSC-900.woff +0 -0
  174. package/engine/lib/fonts/NotoSansSC-sub.woff +0 -0
  175. package/engine/lib/fonts/NotoSerifJP-600.woff +0 -0
  176. package/engine/lib/fonts/NotoSerifSC-sub.woff +0 -0
  177. package/engine/lib/fonts/OFL.txt +94 -0
  178. package/engine/lib/fonts/PlayfairDisplay-400i.woff +0 -0
  179. package/engine/lib/fonts/PlayfairDisplay-700.woff +0 -0
  180. package/engine/lib/fonts/PlayfairDisplay-700i.woff +0 -0
  181. package/engine/lib/fonts/Poppins-600.woff +0 -0
  182. package/engine/lib/fonts/Poppins-700.woff +0 -0
  183. package/engine/lib/fonts/Poppins-800.woff +0 -0
  184. package/engine/lib/fonts/PressStart2P-400.woff +0 -0
  185. package/engine/lib/fonts/Righteous-400.woff +0 -0
  186. package/engine/lib/fonts/RobotoCondensed-var.woff +0 -0
  187. package/engine/lib/fonts/Rye-400.woff +0 -0
  188. package/engine/lib/fonts/UnifrakturMaguntia-400.woff +0 -0
  189. package/engine/lib/fonts/cmunrm.woff +0 -0
  190. package/engine/lib/fonts/cmunti.woff +0 -0
  191. package/engine/lib/fonts/index.json +1 -0
  192. package/engine/lib/fonts.js +56 -0
  193. package/engine/lib/kit.js +91 -0
  194. package/engine/lib/media.js +118 -0
  195. package/engine/lib/medium.js +258 -0
  196. package/engine/lib/motion.js +111 -0
  197. package/engine/lib/paint.js +200 -0
  198. package/engine/lib/palettes.js +57 -0
  199. package/engine/lib/post.js +108 -0
  200. package/engine/lib/render.js +189 -0
  201. package/engine/lib/rig.js +390 -0
  202. package/engine/lib/rig_huashu.js +171 -0
  203. package/engine/lib/three.min.js +7 -0
  204. package/engine/lib/toon.js +186 -0
  205. package/engine/lib/typo.js +136 -0
  206. package/engine/lib/ui.js +141 -0
  207. package/engine/lib/util.js +92 -0
  208. package/engine/render.py +157 -0
  209. package/engine/scenes/01_cave.js +364 -0
  210. package/engine/scenes/02_egypt.js +524 -0
  211. package/engine/scenes/03_greek.js +448 -0
  212. package/engine/scenes/04_roman.js +555 -0
  213. package/engine/scenes/05_gothic.js +522 -0
  214. package/engine/scenes/06_renaissance.js +338 -0
  215. package/engine/scenes/08_impressionism.js +206 -0
  216. package/engine/scenes/09_postimp.js +183 -0
  217. package/engine/scenes/10_nouveau.js +334 -0
  218. package/engine/scenes/11_cubism.js +265 -0
  219. package/engine/scenes/12_bauhaus.js +214 -0
  220. package/engine/scenes/13_pop.js +269 -0
  221. package/engine/scenes/14_8bit.js +238 -0
  222. package/engine/scenes/15_raytrace.js +300 -0
  223. package/engine/scenes/16_2026.js +565 -0
  224. package/engine/scenes/17_ink.js +273 -0
  225. package/engine/scenes/18_klimt.js +227 -0
  226. package/engine/scenes/19_munch.js +153 -0
  227. package/engine/scenes/20_dunhuang.js +215 -0
  228. package/engine/scenes/21_kusama.js +124 -0
  229. package/engine/scenes/22_constructivism.js +205 -0
  230. package/engine/scenes/23_dali.js +221 -0
  231. package/engine/scenes/24_hopper.js +150 -0
  232. package/engine/scenes/25_ghibli.js +251 -0
  233. package/engine/scenes/26_vaporwave.js +191 -0
  234. package/engine/scenes/27_kirby.js +255 -0
  235. package/engine/scenes/28_monet.js +176 -0
  236. package/engine/scenes/29_seurat.js +104 -0
  237. package/engine/scenes/30_matisse.js +151 -0
  238. package/engine/scenes/31_haring.js +109 -0
  239. package/engine/scenes/32_rembrandt.js +217 -0
  240. package/engine/scenes/33_rubberhose.js +219 -0
  241. package/engine/scenes/34_shadowpuppet.js +195 -0
  242. package/engine/scenes/35_shinkai.js +197 -0
  243. package/engine/scenes/36_picasso_blue.js +123 -0
  244. package/engine/scenes/38_giotto.js +133 -0
  245. package/engine/scenes/39_piero.js +53 -0
  246. package/engine/scenes/40_raphael.js +96 -0
  247. package/engine/scenes/41_michelangelo.js +112 -0
  248. package/engine/scenes/42_guardi.js +70 -0
  249. package/engine/scenes/43_lorenzetti.js +145 -0
  250. package/engine/scenes/44_cortona.js +86 -0
  251. package/engine/scenes/45_renoir.js +86 -0
  252. package/engine/scenes/46_pissarro.js +82 -0
  253. package/engine/scenes/47_sisley.js +94 -0
  254. package/engine/scenes/48_gauguin.js +107 -0
  255. package/engine/scenes/49_chagall.js +60 -0
  256. package/engine/scenes/50_ma_yuan.js +131 -0
  257. package/engine/scenes/51_persian_miniature.js +149 -0
  258. package/engine/scenes/52_south_park.js +105 -0
  259. package/engine/scenes/53_pixar.js +60 -0
  260. package/engine/scenes/54_ghibli_lab.js +68 -0
  261. package/engine/scenes/55_dunhuang.js +161 -0
  262. package/engine/scenes/index.js +28 -0
  263. package/engine/spec_assets.py +76 -0
  264. package/engine/transitions.js +929 -0
  265. package/engine//346/227/266/344/273/243/344/275/234/350/200/205/350/247/204/350/214/203.md +49 -0
  266. package/lib/host.mjs +754 -0
  267. package/lib/render-bridge.mjs +543 -0
  268. package/lib/render-cli.mjs +98 -0
  269. package/lib/storyboard-lint.mjs +54 -0
  270. package/manifest.json +52 -0
  271. package/package.json +8 -4
  272. package/runtime/package.json +8 -0
  273. package/skills/biuart/SKILL.md +154 -0
  274. package/skills/biuart/references/01-/346/213/206/350/247/243.md +55 -0
  275. package/skills/biuart/references/02-/346/234/272/345/210/266.md +41 -0
  276. package/skills/biuart/references/03-/344/270/200/345/270/247/345/205/210/350/241/214/345/233/233/346/235/241/350/267/257/347/272/277.md +39 -0
  277. package/skills/biuart/references/04-/347/272/257/344/273/243/347/240/201/347/273/230/345/210/266.md +92 -0
  278. package/skills/biuart/references/05-/350/212/202/345/245/217/344/270/216/351/205/215/344/271/220.md +19 -0
  279. package/skills/biuart/references/06-/345/217/243/346/222/255/351/251/261/345/212/250/347/232/204/350/211/272/346/234/257/347/237/255/347/211/207.md +31 -0
  280. package/skills/biuart/references/07-/346/255/243/351/235/242/347/273/217/351/252/214.md +196 -0
  281. package/skills/biuart/references/08-/351/243/216/346/240/274/344/275/234/350/200/205/350/247/204/350/214/203.md +61 -0
  282. package/skills/biuart/references/09-/350/247/206/351/242/221/345/212/250/347/224/273/350/257/255/346/263/225.md +382 -0
  283. package/skills/biuart/references/10-/350/247/222/350/211/262.md +34 -0
  284. package/skills/biuart/references/11-/351/225/277/345/215/267/347/251/277/350/266/212/347/211/207.md +43 -0
  285. package/skills/biuart/references/12-/345/217/243/346/222/255/346/225/264/347/211/207/344/270/216/347/273/217/351/252/214/345/233/236/346/265/201.md +25 -0
  286. package/skills/biuart/references/13-/345/217/243/346/222/255/344/270/216/350/257/255/351/237/263/345/244/215/345/210/273.md +7 -0
  287. package/skills/biuart/references/15-/350/267/250/345/234/272/346/231/257/351/243/216/346/240/274/346/217/220/347/202/274.md +48 -0
  288. package/skills/biuart/references/16-/351/243/216/346/240/274/346/274/224/347/244/27295/345/210/206/345/215/217/350/256/256.md +103 -0
  289. package/skills/biuart/references/about-author.md +99 -0
  290. package/skills/biuart/references/capabilities.md +91 -0
  291. package/skills/biuart/references/compatibility.md +34 -0
  292. package/skills/biuart/references/images.md +97 -0
  293. package/skills/biuart/references/voice-model-review.md +18 -0
  294. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/t1_3b1b.md +122 -0
  295. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/t2_keynote_ui.md +117 -0
  296. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/t3_finance_chart.md +116 -0
  297. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y1_kurzgesagt.md +193 -0
  298. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y2_vox.md +195 -0
  299. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y3_whiteboard.md +190 -0
  300. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y4_storytime.md +166 -0
  301. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y5_kinetic_type.md +158 -0
  302. package/skills/biuart/references//345/212/250/347/224/273/350/257/255/346/263/225/y6_presenter_explainer.md +24 -0
  303. package/skills/biuart/references//345/217/243/346/222/255API.md +125 -0
  304. package/skills/biuart/references//350/211/262/346/235/277.md +38 -0
  305. package/skills/biuart/references//350/247/222/350/211/262/347/262/276/347/273/206/345/272/246.md +61 -0
  306. package/skills/biuart/references//351/225/234/345/244/264/350/241/250/346/250/241/346/235/277.md +80 -0
  307. package/skills/biuart/references//351/225/234/345/244/264/350/257/255/350/250/200.md +73 -0
  308. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/01_cave.md +46 -0
  309. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/02_egypt.md +64 -0
  310. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/03_greek.md +50 -0
  311. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/04_roman.md +99 -0
  312. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/05_gothic.md +32 -0
  313. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/06_renaissance.md +41 -0
  314. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/08_impressionism.md +34 -0
  315. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/09_postimp.md +17 -0
  316. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/10_nouveau.md +31 -0
  317. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/11_cubism.md +30 -0
  318. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/12_bauhaus.md +30 -0
  319. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/13_pop.md +29 -0
  320. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/14_8bit.md +27 -0
  321. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/15_raytrace.md +32 -0
  322. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/16_2026.md +55 -0
  323. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/17_ink.md +50 -0
  324. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/18_klimt.md +37 -0
  325. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/19_munch.md +42 -0
  326. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/20_dunhuang.md +49 -0
  327. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/21_kusama.md +32 -0
  328. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/22_constructivism.md +35 -0
  329. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/23_dali.md +29 -0
  330. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/24_hopper.md +30 -0
  331. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/25_ghibli.md +55 -0
  332. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/26_vaporwave.md +27 -0
  333. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/27_kirby.md +30 -0
  334. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/28_monet.md +39 -0
  335. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/29_seurat.md +31 -0
  336. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/30_matisse.md +26 -0
  337. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/31_haring.md +22 -0
  338. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/32_rembrandt.md +29 -0
  339. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/33_rubberhose.md +31 -0
  340. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/34_shadowpuppet.md +40 -0
  341. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/35_shinkai.md +34 -0
  342. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/36_picasso_blue.md +25 -0
  343. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/37_rick_morty.md +48 -0
  344. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/38_giotto.md +67 -0
  345. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/39_piero.md +59 -0
  346. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/40_raphael.md +65 -0
  347. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/41_michelangelo.md +65 -0
  348. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/42_guardi.md +65 -0
  349. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/43_lorenzetti.md +69 -0
  350. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/44_cortona.md +66 -0
  351. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/45_renoir.md +66 -0
  352. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/46_pissarro.md +66 -0
  353. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/47_sisley.md +67 -0
  354. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/48_gauguin.md +66 -0
  355. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/49_chagall.md +59 -0
  356. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/50_ma_yuan.md +68 -0
  357. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/51_persian_miniature.md +66 -0
  358. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/52_south_park.md +65 -0
  359. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/53_pixar.md +61 -0
  360. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/55_dunhuang.md +41 -0
  361. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/INDEX.md +89 -0
  362. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/_/350/275/254/345/234/272_/350/277/201/347/247/273/346/265/213/350/257/225.md +53 -0
  363. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/_/351/207/215/345/201/232/350/277/233/345/272/246.md +37 -0
  364. package/skills/biuart/references//351/243/216/346/240/274/351/205/215/346/226/271/_/351/237/263/350/275/250_/350/211/272/346/234/257/345/217/262/351/200/237/351/200/232.md +135 -0
  365. package/studio/app.js +380 -0
  366. package/studio/assert-panel-permit.mjs +67 -0
  367. package/studio/composer.css +465 -0
  368. package/studio/composer.js +480 -0
  369. package/studio/index.html +97 -0
  370. package/studio/optimize-prompt.mjs +84 -0
  371. package/studio/optimize-prompt.test.mjs +47 -0
  372. package/studio/recipes.mjs +87 -0
  373. package/studio/select-menu.js +450 -0
  374. package/studio/styles.css +71 -0
  375. package/studio/to-english-prompt.mjs +149 -0
  376. package/studio/to-english-prompt.test.mjs +72 -0
  377. package/README.md +0 -3
Binary file
Binary file
@@ -0,0 +1,40 @@
1
+ # 字体许可 · Font licenses
2
+
3
+ 本目录的字体都不属于本仓库的 MIT 授权,各自沿用原许可。全部是 SIL Open Font License 1.1(全文见同目录 `OFL.txt`),可以随软件再分发、可商用,但不能单独售卖字体文件。部分文件是按 GB2312 或按用字抽出的子集(`scripts/font_subset.py`),转成了 woff。
4
+
5
+ The fonts in this directory are NOT covered by the repository's MIT license. Each keeps its own license; all of them are SIL Open Font License 1.1 (full text in `OFL.txt`). Some files are subsets converted to WOFF.
6
+
7
+ | 文件 | 字体 | 版权 | 来源 |
8
+ |---|---|---|---|
9
+ | `AlfaSlabOne-400.woff` | Alfa Slab One | © 2016 The Alfa Slab One Project Authors,Reserved Font Name "Alfa Slab" | Google Fonts |
10
+ | `Anton-400.woff` | Anton | © 2020 The Anton Project Authors | Google Fonts |
11
+ | `ArchivoBlack-400.woff` | Archivo Black | © 2017 The Archivo Black Project Authors | Google Fonts |
12
+ | `Bangers-400.woff` | Bangers | © 2010 The Bangers Project Authors | Google Fonts |
13
+ | `Caveat-600.woff` | Caveat | © 2014 The Caveat Project Authors | Google Fonts |
14
+ | `Cinzel-400.woff` `Cinzel-700.woff` | Cinzel | © 2020 The Cinzel Project Authors | Google Fonts |
15
+ | `CormorantGaramond-500.woff` `-500i` `-700` | Cormorant Garamond | © 2015 The Cormorant Project Authors | Google Fonts |
16
+ | `EBGaramond-400.woff` `-400i` `-600` | EB Garamond | © 2017 The EB Garamond Project Authors | Google Fonts |
17
+ | `Exo2-800i.woff` | Exo 2 | © 2013 The Exo 2 Project Authors | Google Fonts |
18
+ | `GochiHand-400.woff` | Gochi Hand | © 2011 Huerta Tipográfica,Reserved Font Names "Gochi" and "Gochi Hand" | Google Fonts |
19
+ | `IMFellEnglish-400.woff` `-400i` | IM FELL English | © 2007 Igino Marini,Reserved Font Names "IM FELL English Roman/Italic" | Google Fonts |
20
+ | `Inter-var.woff` | Inter | © 2016 The Inter Project Authors | github.com/rsms/inter |
21
+ | `JosefinSans-700.woff` | Josefin Sans | © 2010 The Josefin Sans Project Authors,Reserved Font Name "Josefin Sans" | Google Fonts |
22
+ | `Kalam-700.woff` | Kalam | © 2014 Indian Type Foundry | Google Fonts |
23
+ | `LibreBaskerville-400.woff` `-700` | Libre Baskerville | © 2012 The Libre Baskerville Project Authors | Google Fonts |
24
+ | `LilitaOne-400.woff` | Lilita One | © 2011 Juan Montoreano,Reserved Font Name "Lilita One" | Google Fonts |
25
+ | `Marcellus-400.woff` | Marcellus | © 2012 Brian J. Bonislawsky (Astigmatic),Reserved Font Name "Marcellus" | Google Fonts |
26
+ | `PlayfairDisplay-400i.woff` `-700` `-700i` | Playfair Display | © 2017 The Playfair Display Project Authors,Reserved Font Name "Playfair Display" | Google Fonts |
27
+ | `Poppins-600.woff` `-700` `-800` | Poppins | © 2020 The Poppins Project Authors | Google Fonts |
28
+ | `PressStart2P-400.woff` | Press Start 2P | © 2012 The Press Start 2P Project Authors,Reserved Font Name "Press Start 2P" | Google Fonts |
29
+ | `Righteous-400.woff` | Righteous | © 2011 Brian J. Bonislawsky (Astigmatic),Reserved Font Name "Righteous" | Google Fonts |
30
+ | `RobotoCondensed-var.woff` | Roboto Condensed | © 2011 The Roboto Project Authors | Google Fonts |
31
+ | `Rye-400.woff` | Rye | © 2010 Sorkin Type Co,Reserved Font Name "Rye" | Google Fonts |
32
+ | `UnifrakturMaguntia-400.woff` | UnifrakturMaguntia | © 2010 j. 'mach' wust,© 2009 Peter Wiegel,Reserved Font Name "UnifrakturMaguntia" | Google Fonts |
33
+ | `cmunrm.woff` `cmunti.woff` | CMU Serif(Computer Modern Unicode) | Andrey V. Panov,部分字形来自 AMS Blue Sky fonts | CTAN cm-unicode |
34
+ | `LXGWWenKai-500.woff` | 霞鹜文楷 LXGW WenKai(子集) | © 2021-2025 LXGW;© 2020 The Klee Project Authors | github.com/lxgw/LxgwWenKai |
35
+ | `NotoSansSC-500/700/800/900.woff` | 思源黑体 Noto Sans SC(按字重实例化后的 GB2312 子集;代码里 family 名叫 `PuHui-*`) | © 2014-2021 Adobe,Reserved Font Name "Source" | Google Fonts |
36
+ | `NotoSansSC-sub.woff` | 思源黑体 Noto Sans SC(按用字子集) | © 2014-2021 Adobe,Reserved Font Name "Source" | Google Fonts |
37
+ | `NotoSerifSC-sub.woff` | 思源宋体 Noto Serif SC(按用字子集) | © 2017-2024 Adobe | Google Fonts |
38
+ | `NotoSerifJP-600.woff` | Noto Serif JP | © 2017-2024 Adobe | Google Fonts |
39
+
40
+ 带 Reserved Font Name 的字体,改动过的版本不能沿用保留名。本目录里带保留名的这几款(拉丁字体)内部字体名都是原名(按 Google Fonts 发行的 woff 使用);如果你要对它们抽子集或改字形,请同时改掉 family 名。
@@ -0,0 +1,94 @@
1
+ Copyright notices for each font file in this directory are listed in LICENSES.md
2
+ (and are embedded in each font's name table).
3
+
4
+ This Font Software is licensed under the SIL Open Font License, Version 1.1.
5
+ This license is copied below, and is also available with a FAQ at:
6
+ http://scripts.sil.org/OFL
7
+
8
+
9
+ -----------------------------------------------------------
10
+ SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
11
+ -----------------------------------------------------------
12
+
13
+ PREAMBLE
14
+ The goals of the Open Font License (OFL) are to stimulate worldwide
15
+ development of collaborative font projects, to support the font creation
16
+ efforts of academic and linguistic communities, and to provide a free and
17
+ open framework in which fonts may be shared and improved in partnership
18
+ with others.
19
+
20
+ The OFL allows the licensed fonts to be used, studied, modified and
21
+ redistributed freely as long as they are not sold by themselves. The
22
+ fonts, including any derivative works, can be bundled, embedded,
23
+ redistributed and/or sold with any software provided that any reserved
24
+ names are not used by derivative works. The fonts and derivatives,
25
+ however, cannot be released under any other type of license. The
26
+ requirement for fonts to remain under this license does not apply
27
+ to any document created using the fonts or their derivatives.
28
+
29
+ DEFINITIONS
30
+ "Font Software" refers to the set of files released by the Copyright
31
+ Holder(s) under this license and clearly marked as such. This may
32
+ include source files, build scripts and documentation.
33
+
34
+ "Reserved Font Name" refers to any names specified as such after the
35
+ copyright statement(s).
36
+
37
+ "Original Version" refers to the collection of Font Software components as
38
+ distributed by the Copyright Holder(s).
39
+
40
+ "Modified Version" refers to any derivative made by adding to, deleting,
41
+ or substituting -- in part or in whole -- any of the components of the
42
+ Original Version, by changing formats or by porting the Font Software to a
43
+ new environment.
44
+
45
+ "Author" refers to any designer, engineer, programmer, technical
46
+ writer or other person who contributed to the Font Software.
47
+
48
+ PERMISSION & CONDITIONS
49
+ Permission is hereby granted, free of charge, to any person obtaining
50
+ a copy of the Font Software, to use, study, copy, merge, embed, modify,
51
+ redistribute, and sell modified and unmodified copies of the Font
52
+ Software, subject to the following conditions:
53
+
54
+ 1) Neither the Font Software nor any of its individual components,
55
+ in Original or Modified Versions, may be sold by itself.
56
+
57
+ 2) Original or Modified Versions of the Font Software may be bundled,
58
+ redistributed and/or sold with any software, provided that each copy
59
+ contains the above copyright notice and this license. These can be
60
+ included either as stand-alone text files, human-readable headers or
61
+ in the appropriate machine-readable metadata fields within text or
62
+ binary files as long as those fields can be easily viewed by the user.
63
+
64
+ 3) No Modified Version of the Font Software may use the Reserved Font
65
+ Name(s) unless explicit written permission is granted by the corresponding
66
+ Copyright Holder. This restriction only applies to the primary font name as
67
+ presented to the users.
68
+
69
+ 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
70
+ Software shall not be used to promote, endorse or advertise any
71
+ Modified Version, except to acknowledge the contribution(s) of the
72
+ Copyright Holder(s) and the Author(s) or with their explicit written
73
+ permission.
74
+
75
+ 5) The Font Software, modified or unmodified, in part or in whole,
76
+ must be distributed entirely under this license, and must not be
77
+ distributed under any other license. The requirement for fonts to
78
+ remain under this license does not apply to any document created
79
+ using the Font Software.
80
+
81
+ TERMINATION
82
+ This license becomes null and void if any of the above conditions are
83
+ not met.
84
+
85
+ DISCLAIMER
86
+ THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
87
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
88
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
89
+ OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
90
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
91
+ INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
92
+ DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
93
+ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
94
+ OTHER DEALINGS IN THE FONT SOFTWARE.
Binary file
Binary file
Binary file
@@ -0,0 +1 @@
1
+ [["Cinzel-400.woff", "Cinzel", "normal", "400"], ["Cinzel-700.woff", "Cinzel", "normal", "700"], ["CormorantGaramond-500i.woff", "Cormorant Garamond", "italic", "500"], ["CormorantGaramond-500.woff", "Cormorant Garamond", "normal", "500"], ["CormorantGaramond-700.woff", "Cormorant Garamond", "normal", "700"], ["EBGaramond-400i.woff", "EB Garamond", "italic", "400"], ["EBGaramond-400.woff", "EB Garamond", "normal", "400"], ["EBGaramond-600.woff", "EB Garamond", "normal", "600"], ["IMFellEnglish-400i.woff", "IM Fell English", "italic", "400"], ["IMFellEnglish-400.woff", "IM Fell English", "normal", "400"], ["PlayfairDisplay-400i.woff", "Playfair Display", "italic", "400"], ["PlayfairDisplay-700i.woff", "Playfair Display", "italic", "700"], ["PlayfairDisplay-700.woff", "Playfair Display", "normal", "700"], ["PressStart2P-400.woff", "Press Start 2P", "normal", "400"], ["Poppins-600.woff", "Poppins", "normal", "600"], ["Poppins-700.woff", "Poppins", "normal", "700"], ["Poppins-800.woff", "Poppins", "normal", "800"], ["JosefinSans-700.woff", "Josefin Sans", "normal", "700"], ["Bangers-400.woff", "Bangers", "normal", "400"], ["GochiHand-400.woff", "Gochi Hand", "normal", "400"], ["Caveat-600.woff", "Caveat", "normal", "600"], ["LilitaOne-400.woff", "Lilita One", "normal", "400"], ["NotoSerifJP-600.woff", "Noto Serif JP", "normal", "600"], ["Exo2-800i.woff", "Exo 2", "italic", "800"], ["ArchivoBlack-400.woff", "Archivo Black", "normal", "400"], ["Kalam-700.woff", "Kalam", "normal", "700"], ["UnifrakturMaguntia-400.woff", "UnifrakturMaguntia", "normal", "400"], ["Marcellus-400.woff", "Marcellus", "normal", "400"], ["Righteous-400.woff", "Righteous", "normal", "400"], ["Anton-400.woff", "Anton", "normal", "400"], ["AlfaSlabOne-400.woff", "Alfa Slab One", "normal", "400"], ["Rye-400.woff", "Rye", "normal", "400"], ["LibreBaskerville-400.woff", "Libre Baskerville", "normal", "400"], ["LibreBaskerville-700.woff", "Libre Baskerville", "normal", "700"]]
@@ -0,0 +1,56 @@
1
+ // 每个字体文件注册成独立 family(文件名去扩展名),用法:ctx.font = '96px "Cinzel-700"'
2
+ window.FONT_FACES = [
3
+ {family:'Cinzel-400', url:'lib/fonts/Cinzel-400.woff'},
4
+ {family:'Cinzel-700', url:'lib/fonts/Cinzel-700.woff'},
5
+ {family:'CormorantGaramond-500i', url:'lib/fonts/CormorantGaramond-500i.woff'},
6
+ {family:'CormorantGaramond-500', url:'lib/fonts/CormorantGaramond-500.woff'},
7
+ {family:'CormorantGaramond-700', url:'lib/fonts/CormorantGaramond-700.woff'},
8
+ {family:'EBGaramond-400i', url:'lib/fonts/EBGaramond-400i.woff'},
9
+ {family:'EBGaramond-400', url:'lib/fonts/EBGaramond-400.woff'},
10
+ {family:'EBGaramond-600', url:'lib/fonts/EBGaramond-600.woff'},
11
+ {family:'IMFellEnglish-400i', url:'lib/fonts/IMFellEnglish-400i.woff'},
12
+ {family:'IMFellEnglish-400', url:'lib/fonts/IMFellEnglish-400.woff'},
13
+ {family:'PlayfairDisplay-400i', url:'lib/fonts/PlayfairDisplay-400i.woff'},
14
+ {family:'PlayfairDisplay-700i', url:'lib/fonts/PlayfairDisplay-700i.woff'},
15
+ {family:'PlayfairDisplay-700', url:'lib/fonts/PlayfairDisplay-700.woff'},
16
+ {family:'PressStart2P-400', url:'lib/fonts/PressStart2P-400.woff'},
17
+ {family:'Poppins-600', url:'lib/fonts/Poppins-600.woff'},
18
+ {family:'Poppins-700', url:'lib/fonts/Poppins-700.woff'},
19
+ {family:'Poppins-800', url:'lib/fonts/Poppins-800.woff'},
20
+ {family:'JosefinSans-700', url:'lib/fonts/JosefinSans-700.woff'},
21
+ {family:'Bangers-400', url:'lib/fonts/Bangers-400.woff'},
22
+ {family:'GochiHand-400', url:'lib/fonts/GochiHand-400.woff'},
23
+ {family:'Caveat-600', url:'lib/fonts/Caveat-600.woff'},
24
+ {family:'LilitaOne-400', url:'lib/fonts/LilitaOne-400.woff'},
25
+ {family:'NotoSerifJP-600', url:'lib/fonts/NotoSerifJP-600.woff'},
26
+ {family:'Exo2-800i', url:'lib/fonts/Exo2-800i.woff'},
27
+ {family:'ArchivoBlack-400', url:'lib/fonts/ArchivoBlack-400.woff'},
28
+ {family:'Kalam-700', url:'lib/fonts/Kalam-700.woff'},
29
+ {family:'UnifrakturMaguntia-400', url:'lib/fonts/UnifrakturMaguntia-400.woff'},
30
+ {family:'Marcellus-400', url:'lib/fonts/Marcellus-400.woff'},
31
+ {family:'Righteous-400', url:'lib/fonts/Righteous-400.woff'},
32
+ {family:'Anton-400', url:'lib/fonts/Anton-400.woff'},
33
+ {family:'AlfaSlabOne-400', url:'lib/fonts/AlfaSlabOne-400.woff'},
34
+ {family:'Rye-400', url:'lib/fonts/Rye-400.woff'},
35
+ {family:'LibreBaskerville-400', url:'lib/fonts/LibreBaskerville-400.woff'},
36
+ {family:'LibreBaskerville-700', url:'lib/fonts/LibreBaskerville-700.woff'},
37
+ // 中文:霞鹜文楷 Medium 子集(OFL 1.1)。GB2312 全部汉字+预置字+skill 里用到的字(font_subset.py --gb2312),生僻字用 scripts/font_subset.py --text 补;NotoSerifJP 是日文子集,简体字不全(「戏」「蓝」都没有)
38
+ {family:'LXGWWenKai-500', url:'lib/fonts/LXGWWenKai-500.woff'},
39
+ // ---- YouTube 解说语法(references/09)----
40
+ // 中文黑体:family 名沿用 PuHui-*(代码里 97 处引用不用改),开源版文件是思源黑体 Noto Sans SC(OFL 1.1)500/700/800/900 四个字重的 GB2312 子集
41
+ // (scripts/font_subset.py --gb2312,单字重约 1.4MB)。作者原用阿里巴巴普惠体 3.0,其许可不允许转换、拆分后再分发,所以不随仓库附带;
42
+ // 你自己装了普惠体想换回去:按 font_subset.py 说明生成 PuHui-*.woff,把下面四行的 url 改回去即可。
43
+ {family:'PuHui-Medium', url:'lib/fonts/NotoSansSC-500.woff'},
44
+ {family:'PuHui-Bold', url:'lib/fonts/NotoSansSC-700.woff'},
45
+ {family:'PuHui-Heavy', url:'lib/fonts/NotoSansSC-800.woff'},
46
+ {family:'PuHui-Black', url:'lib/fonts/NotoSansSC-900.woff'},
47
+ // 3b1b 公式:CMU(LaTeX Computer Modern)正体/斜体
48
+ {family:'CMU-rm', url:'lib/fonts/cmunrm.woff'},
49
+ {family:'CMU-it', url:'lib/fonts/cmunti.woff'},
50
+ // 发布会 Inter(SF Pro 最接近的开源字)、财经 Roboto Condensed:可变字重,用 '600 220px "Inter"' 选字重
51
+ {family:'Inter', url:'lib/fonts/Inter-var.woff', desc:{weight:'100 900'}},
52
+ {family:'RobotoCondensed', url:'lib/fonts/RobotoCondensed-var.woff', desc:{weight:'100 900'}},
53
+ // 思源黑/宋(可变字重):只含 3b1b/发布会/财经三支示范片用到的字(源文件未随仓库附带,换题目缺字时改用 PuHui-*,或下 Google Fonts 的 NotoSansSC[wght].ttf 重做子集)
54
+ {family:'NotoSansSC', url:'lib/fonts/NotoSansSC-sub.woff', desc:{weight:'100 900'}},
55
+ {family:'NotoSerifSC', url:'lib/fonts/NotoSerifSC-sub.woff', desc:{weight:'200 900'}},
56
+ ];
@@ -0,0 +1,91 @@
1
+ // 跨场景共用的小工具:点列加密/等弧长重采样、可变线宽路径 ribbon、整幅行/列扭曲、手绘不规则圆、全片连续编舞、近侧手臂补盖、角标。
2
+ // 渲染器在 lib/brush.js(笔与水)、lib/render.js(网点/点彩/赛璐珞/光影/皮影)、lib/post.js(VHS/胶片/泛光/纹理叠角色)。
3
+ (() => {
4
+ let W = 1920, H = 1080; U.onStage((w, h) => { W = w; H = h; }); // 画布尺寸跟 U.setStage 走(默认 1920×1080)
5
+ const { clamp, lerp, rng } = U;
6
+ const K = window.KIT = {};
7
+
8
+ // Catmull-Rom 加密点列(开放)
9
+ K.densify = (pts, per = 6) => {
10
+ const out = [], n = pts.length, P_ = i => pts[Math.max(0, Math.min(n - 1, i))];
11
+ for (let i = 0; i < n - 1; i++) {
12
+ const p0 = P_(i - 1), p1 = P_(i), p2 = P_(i + 1), p3 = P_(i + 2);
13
+ for (let k = 0; k < per; k++) {
14
+ const t = k / per, t2 = t * t, t3 = t2 * t;
15
+ out.push([0.5 * (2 * p1[0] + (-p0[0] + p2[0]) * t + (2 * p0[0] - 5 * p1[0] + 4 * p2[0] - p3[0]) * t2 + (-p0[0] + 3 * p1[0] - 3 * p2[0] + p3[0]) * t3),
16
+ 0.5 * (2 * p1[1] + (-p0[1] + p2[1]) * t + (2 * p0[1] - 5 * p1[1] + 4 * p2[1] - p3[1]) * t2 + (-p0[1] + 3 * p1[1] - 3 * p2[1] + p3[1]) * t3)]);
17
+ }
18
+ }
19
+ out.push(pts[n - 1]); return out;
20
+ };
21
+ // 按弧长等距重采样(让噪声、飞白、行波的频率与笔画长短无关)
22
+ K.resample = (pts, step = 4) => {
23
+ const out = [pts[0]]; let acc = 0;
24
+ for (let i = 1; i < pts.length; i++) { const a = pts[i - 1], b = pts[i], L = Math.hypot(b[0] - a[0], b[1] - a[1]); let d = step - acc;
25
+ while (d <= L) { const q = d / L; out.push([a[0] + (b[0] - a[0]) * q, a[1] + (b[1] - a[1]) * q]); d += step; } acc = L - (d - step); }
26
+ out.push(pts[pts.length - 1]); return out;
27
+ };
28
+ // 可变线宽路径:点列两侧按 w(q) 偏移成闭合多边形(书法线、飘带、表现主义长笔)
29
+ K.ribbon = (pts, w) => {
30
+ const n = pts.length, L = [], R = [];
31
+ for (let i = 0; i < n; i++) {
32
+ const a = pts[Math.max(0, i - 1)], b = pts[Math.min(n - 1, i + 1)];
33
+ let dx = b[0] - a[0], dy = b[1] - a[1]; const d = Math.hypot(dx, dy) || 1; dx /= d; dy /= d;
34
+ const hw = (typeof w === 'function' ? w(i / (n - 1), i) : w) / 2;
35
+ L.push([pts[i][0] - dy * hw, pts[i][1] + dx * hw]); R.push([pts[i][0] + dy * hw, pts[i][1] - dx * hw]);
36
+ }
37
+ const p = new Path2D(); L.forEach((q, i) => i ? p.lineTo(q[0], q[1]) : p.moveTo(q[0], q[1]));
38
+ for (let i = n - 1; i >= 0; i--) p.lineTo(R[i][0], R[i][1]); p.closePath(); return p;
39
+ };
40
+ // 少女部件按画序列出(远→近),给「不调 drawGirl、自己逐部件上色」的风格用
41
+ K.girlOrder = ['farSleeve', 'farHand', 'farCuff', 'hairDown', 'skirt', 'shoe', 'torso', 'neck', 'hairBack', 'bun', 'face', 'bangs', 'upperArm', 'foreArm', 'cuff', 'hand']; // 完整画序(含五官、杯、钩子插槽名)见 RIG.GIRL_ORDER
42
+
43
+ // 把 src 按「水平条带位移」画到 dst:fx(y) 返回该行的 x 位移(蒙克式整个世界在流动)
44
+ // margin:每行横向多拉伸 2·margin 像素,位移后左右不露缝(margin ≥ 最大位移)
45
+ K.warpRows = (dst, src, fx, band = 6, margin = 0) => {
46
+ for (let y = 0; y < H; y += band) { const dx = fx(y + band / 2); dst.drawImage(src, 0, y, W, band, dx - margin, y, W + 2 * margin, band); }
47
+ };
48
+ K.warpCols = (dst, src, fy, band = 6, margin = 0) => {
49
+ for (let x = 0; x < W; x += band) { const dy = fy(x + band / 2); dst.drawImage(src, x, 0, band, H, x, dy - margin, band, H + 2 * margin); }
50
+ };
51
+
52
+ // n 角星(剪纸星、爆炸框、闪光):外半径 r0、内半径 r1
53
+ K.star = (cx, cy, r0, r1, n, rot = 0) => { const pts = []; for (let i = 0; i < n * 2; i++) { const a = rot + i / (n * 2) * Math.PI * 2 - Math.PI / 2, r = i % 2 ? r1 : r0; pts.push([cx + Math.cos(a) * r, cy + Math.sin(a) * r]); } return U.poly(pts); };
54
+ // 手绘不规则圆(草间的点不是完美圆):n 个顶点、半径按种子起伏
55
+ K.blob = (c, x, y, r, seed, wob = 0.08, n = 14) => {
56
+ const rr = rng(seed); const off = []; for (let i = 0; i < n; i++) off.push(1 + (rr() - .5) * 2 * wob);
57
+ const pts = []; for (let i = 0; i < n; i++) { const a = i / n * Math.PI * 2; pts.push([x + Math.cos(a) * r * off[i], y + Math.sin(a) * r * off[i]]); }
58
+ c.moveTo((pts[0][0] + pts[n - 1][0]) / 2, (pts[0][1] + pts[n - 1][1]) / 2);
59
+ for (let i = 0; i < n; i++) { const p = pts[i], q = pts[(i + 1) % n]; c.quadraticCurveTo(p[0], p[1], (p[0] + q[0]) / 2, (p[1] + q[1]) / 2); }
60
+ c.closePath();
61
+ };
62
+
63
+ // 全片连续的编舞:端杯按全局时间走(周期 = 两段 = 2.34s,在嘴边和桌上各停一会儿),
64
+ // 换风格时姿势不重置——速通看的是「同一瞬间换了画风」,而不是每段重喝一次。转场正好落在杯子停住的时刻。
65
+ K.choreo = (lt, t) => {
66
+ const ch = PAINT.choreo(lt, t), k = 0.5 - 0.5 * Math.cos(2 * Math.PI * t / 2.34375);
67
+ let q = clamp((k - 0.15) / 0.7); q = q * q * (3 - 2 * q);
68
+ ch.cup = q; ch.sip = Math.max(0, Math.sin(t * 6)) * 0.15 * q; return ch;
69
+ };
70
+ // drawGirl(mode:'line') 会把被近侧手臂挡住的躯干线画穿:线稿画完后,把近侧手臂、袖口、手、杯重新盖一遍
71
+ K.nearArm = (c, G, { fill, line = '#111', lw = 3, skin, cuff, cupBody, cupRim, pattern } = {}) => {
72
+ const arm = new Path2D(); arm.addPath(G.upperArm); arm.addPath(G.foreArm);
73
+ c.save(); c.lineJoin = 'round'; c.fillStyle = fill; c.fill(arm); if (pattern) { c.save(); c.clip(arm); pattern(c); c.restore(); }
74
+ c.strokeStyle = line; c.lineWidth = lw; c.stroke(G.upperArm); c.stroke(G.foreArm);
75
+ if (cuff) { c.fillStyle = cuff; c.fill(G.cuff); c.stroke(G.cuff); }
76
+ c.fillStyle = skin; c.fill(G.hand); c.lineWidth = lw * 0.8; c.stroke(G.hand);
77
+ RIG.drawCup(c, G.cup, { body: cupBody, rim: cupRim, line, lw: lw * 0.8, hw: 7 });
78
+ c.fillStyle = skin; c.beginPath(); c.arc(G.thumb[0], G.thumb[1], 7, 0, Math.PI * 2); c.fill(); c.lineWidth = lw * 0.7; c.stroke();
79
+ c.restore();
80
+ };
81
+ // 右上角角标:标题(中文)+副标题;入场 0.18s 由各风格的 reveal(c,p) 决定怎么出现
82
+ K.label = (c, { title, sub, tFont, sFont, tCol, sCol, x = 1866, y = 128, sy = 182, shadow, before, after, spacing = 0 }) => {
83
+ c.save(); c.textAlign = 'right'; c.textBaseline = 'alphabetic';
84
+ if (before) before(c);
85
+ if (shadow) { c.shadowColor = shadow.color; c.shadowOffsetX = shadow.x || 0; c.shadowOffsetY = shadow.y || 0; c.shadowBlur = shadow.blur || 0; }
86
+ c.font = tFont; c.fillStyle = tCol; if (spacing) c.letterSpacing = spacing + 'px'; c.fillText(title, x, y); c.letterSpacing = '0px';
87
+ if (sub) { c.font = sFont; c.fillStyle = sCol || tCol; c.fillText(sub, x, sy); }
88
+ if (after) after(c);
89
+ c.restore();
90
+ };
91
+ })();
@@ -0,0 +1,118 @@
1
+ // 真实素材 MD:把截图、照片、录像帧放进画面当主体。解说片里有真实素材就让它满幅当主画面,代码负责解释、标注和运镜。
2
+ // 出处:两支被认可的片子——一支把照片满幅铺开、口播点到细节时推近(cover),一支把照片冲印成带白边的件摆在调查桌上、配黑底撕边标签。
3
+ // 满幅一镜一张图时,镜头唯一能做的就是往里推,整片很容易变成一镜一推:只在那一处在当前景别读不清时才推,实拍录像本身在动就停住;
4
+ // 要在几件素材之间走,把它们摆进同一张世界画布(MD.print 调查桌)用横移,见 references/镜头语言.md「真实素材满幅时」。
5
+ // 约定:素材缺失一律报错(throw → render.py / qa.py 判失败),不静默画空白;所有参数由调用方用时间算好传进来,本库不读时钟。
6
+ //
7
+ // MD.size(src) 素材的像素尺寸 [w, h](图片 / 视频帧 / canvas 都行);缺失或没加载完 → throw
8
+ // MD.cover(c, src, o) → geo 满幅铺开:等比放大到盖满框(裁掉多出的边),按焦点裁、按 z 推近
9
+ // o = { x=0, y=0, w=画宽, h=画高(框), fx=.5, fy=.5(焦点,0..1 相对素材:裁切和推近都绕它), z=1(推近倍数,≥1),
10
+ // crop:[sx,sy,sw,sh](先取素材的这一块,0..1), fit:'cover'|'contain'(contain = 整张放进框里、不裁,留边), clip=true }
11
+ // 返回 geo = { x, y, w, h(素材在画面上的矩形), s(缩放), box },配 MD.toScreen 把素材上的点/框换算到画面
12
+ // MD.toScreen(geo, r) 素材上 0..1 的点 [u,v] 或框 [u,v,w,h] → 画面坐标([x,y] 或 {x,y,w,h})
13
+ // MD.focusFor(rect) → {fx, fy} 框 [u,v,w,h] 的中心当焦点
14
+ // MD.zoomFor(rect, iw, ih, bw, bh, fill=.6, fit='cover') → z 要让素材上的框 rect 占框宽/高的 fill,cover 之上还要推几倍(≥1)
15
+ // MD.print(c, src, w, h, o) 冲印件:白边+旧纸色+投影+胶带,原点在冲印件中心(调用方先 translate/rotate)
16
+ // o = { border=16·u, crop, fx, fy(按焦点 cover 进 w×h), tape=true, caption(白边下方小字), polaroid=false(底边加宽、caption 写在底边里),
17
+ // shadow=true, key(给了 key 且素材是静态图就缓存成位图)}
18
+ // MD.label(c, text, x, y, o) 黑底撕边标签:o = { size=48·u, maxW(限宽,超了先缩后截断), fam='PuHui-Heavy', bg='#191817', fg='#f3efe6', align='left'|'center'|'right',
19
+ // t, at(at 这一帧出现:先 1.12 倍一拍再落定,字按 rate 字/秒、12fps 打出;不给 t 就直接画完整的), rate=14, r(旋转)}
20
+ // 返回 {w, h}
21
+ // MD.frameAt(frames, lt, fps=30, loop=false) 帧序列(图片数组)在片内时间 lt 的那一帧;缺帧 → throw
22
+ (() => {
23
+ let W = 1920, H = 1080; U.onStage((w, h) => { W = w; H = h; }); // 画布尺寸跟 U.setStage 走(默认 1920×1080)
24
+ const { clamp } = U;
25
+ const MD = window.MD = {};
26
+ const u0 = () => Math.min(W, H) / 1080;
27
+
28
+ MD.size = src => {
29
+ if (!src) throw new Error('MD:素材缺失(图片没加载或路径写错)——不画空白帧');
30
+ const w = src.videoWidth || src.naturalWidth || src.width, h = src.videoHeight || src.naturalHeight || src.height;
31
+ if (!(w > 0 && h > 0)) throw new Error(`MD:素材尺寸是 0(还没加载完或解不开):${src.src || src.currentSrc || src}`);
32
+ return [w, h];
33
+ };
34
+
35
+ MD.cover = (c, src, o = {}) => {
36
+ const [iw0, ih0] = MD.size(src);
37
+ const bx = o.x ?? 0, by = o.y ?? 0, bw = o.w ?? W, bh = o.h ?? H, fx = o.fx ?? 0.5, fy = o.fy ?? 0.5, z = Math.max(1e-3, o.z ?? 1);
38
+ const cr = o.crop || [0, 0, 1, 1], sx = cr[0] * iw0, sy = cr[1] * ih0, iw = cr[2] * iw0, ih = cr[3] * ih0;
39
+ const s0 = (o.fit === 'contain' ? Math.min : Math.max)(bw / iw, bh / ih), s = s0 * z, w = iw * s, h = ih * s;
40
+ // 焦点:cover 时让焦点尽量落在框的同一相对位置(不露边);推近绕焦点
41
+ const ax = bx + bw * fx, ay = by + bh * fy;
42
+ let x = ax - w * fx, y = ay - h * fy;
43
+ if (o.fit !== 'contain') { x = Math.min(bx, Math.max(bx + bw - w, x)); y = Math.min(by, Math.max(by + bh - h, y)); }
44
+ else if (z <= 1) { x = bx + (bw - w) / 2; y = by + (bh - h) / 2; }
45
+ c.save();
46
+ if (o.clip !== false) { c.beginPath(); c.rect(bx, by, bw, bh); c.clip(); }
47
+ c.drawImage(src, sx, sy, iw, ih, x, y, w, h);
48
+ c.restore();
49
+ return { x, y, w, h, s, box: { x: bx, y: by, w: bw, h: bh } };
50
+ };
51
+
52
+ MD.toScreen = (geo, r) => r.length === 2 ? [geo.x + r[0] * geo.w, geo.y + r[1] * geo.h]
53
+ : { x: geo.x + r[0] * geo.w, y: geo.y + r[1] * geo.h, w: r[2] * geo.w, h: r[3] * geo.h };
54
+ MD.focusFor = r => ({ fx: r[0] + r[2] / 2, fy: r[1] + r[3] / 2 });
55
+ MD.zoomFor = (rect, iw, ih, bw = W, bh = H, fill = 0.6, fit = 'cover') => {
56
+ const s0 = (fit === 'contain' ? Math.min : Math.max)(bw / iw, bh / ih), rw = rect[2] * iw * s0, rh = rect[3] * ih * s0;
57
+ return Math.max(1, Math.min(bw * fill / rw, bh * fill / rh));
58
+ };
59
+
60
+ const printCache = {};
61
+ MD.print = (c, src, w, h, o = {}) => {
62
+ const u = u0(), b = o.border ?? 16 * u, bot = o.polaroid ? Math.max(b * 4, h * 0.2) : b, PW = w + 2 * b, PH = h + b + bot;
63
+ const paint = g => {
64
+ g.fillStyle = '#f7f5ef'; g.fillRect(0, 0, PW, PH);
65
+ const f = o.crop ? null : MD.focusFor([o.fx ?? 0.5, o.fy ?? 0.5, 0, 0]);
66
+ MD.cover(g, src, { x: b, y: b, w, h, crop: o.crop, fx: f ? f.fx : 0.5, fy: f ? f.fy : 0.5 });
67
+ g.save(); g.globalCompositeOperation = 'multiply'; g.fillStyle = 'rgba(214,205,185,.16)'; g.fillRect(0, 0, PW, PH); g.restore(); // 印在纸上:压一层旧纸色
68
+ if (o.polaroid && o.caption) { g.save(); g.fillStyle = '#2b2925'; g.font = `${Math.min(bot * 0.42, 40 * u)}px "LXGWWenKai-500", "PuHui-Medium"`; g.textBaseline = 'middle'; g.fillText(o.caption, b * 1.2, b + h + bot / 2); g.restore(); }
69
+ };
70
+ MD.size(src);
71
+ let sp;
72
+ if (o.key && !(src instanceof HTMLVideoElement)) { const k = `${o.key}|${Math.round(PW)}x${Math.round(PH)}`; sp = printCache[k] || (printCache[k] = (() => { const cv = document.createElement('canvas'); cv.width = Math.ceil(PW); cv.height = Math.ceil(PH); paint(cv.getContext('2d')); return cv; })()); }
73
+ c.save();
74
+ if (o.shadow !== false) { c.shadowColor = 'rgba(30,22,10,.32)'; c.shadowBlur = 14 * u; c.shadowOffsetX = 3 * u; c.shadowOffsetY = 8 * u; }
75
+ if (sp) c.drawImage(sp, -PW / 2, -PH / 2);
76
+ else { c.translate(-PW / 2, -PH / 2); c.fillStyle = '#f7f5ef'; c.fillRect(0, 0, PW, PH); c.shadowColor = 'transparent'; paint(c); }
77
+ c.restore();
78
+ if (o.tape !== false && window.CL) { CL.tape(c, -w / 2 + 30 * u, -PH / 2 + 6 * u, -0.6, 110 * u); CL.tape(c, w / 2 - 30 * u, -PH / 2 + 6 * u, 0.55, 110 * u); }
79
+ if (o.caption && !o.polaroid) { c.save(); c.font = `${22 * u}px "PuHui-Medium"`; c.fillStyle = 'rgba(40,36,30,.78)'; c.textBaseline = 'top'; c.fillText(o.caption, -PW / 2, PH / 2 + 10 * u); c.restore(); }
80
+ return { w: PW, h: PH };
81
+ };
82
+
83
+ const labCache = {};
84
+ MD.label = (c, text, x, y, o = {}) => {
85
+ text = String(text ?? ''); if (!text) return { w: 0, h: 0 };
86
+ const u = u0(), fam = o.fam || 'PuHui-Heavy', bg = o.bg || '#191817', fg = o.fg || '#f3efe6';
87
+ let size = o.size ?? 48 * u;
88
+ if (o.t != null && o.at != null && o.t < o.at) return { w: 0, h: 0 };
89
+ c.save(); c.font = `${size}px "${fam}"`;
90
+ if (o.maxW) { // 限宽:先把字缩到 62% 为止,还放不下就截断加「…」,标签不许比画面宽
91
+ const full = c.measureText(text).width + size * 0.84;
92
+ if (full > o.maxW) { size = Math.max(size * 0.62, size * o.maxW / full); c.font = `${size}px "${fam}"`;
93
+ const cs = [...text]; while (cs.length > 1 && c.measureText(cs.join('')).width + size * 0.84 > o.maxW) cs.pop();
94
+ if (cs.length < [...text].length) text = cs.join('').trimEnd() + '…'; }
95
+ }
96
+ const tw = c.measureText(text).width, padX = size * 0.42, w = Math.round(tw + padX * 2), h = Math.round(size * 1.5);
97
+ const key = `${text}|${size}|${fam}|${bg}`;
98
+ const sp = labCache[key] || (labCache[key] = (() => { const cv = document.createElement('canvas'); cv.width = w; cv.height = h; const g = cv.getContext('2d');
99
+ if (window.CL) CL.tornRect(g, w, h, [...text].length * 7 + Math.round(size), 3 * u); else { g.beginPath(); g.rect(0, 0, w, h); }
100
+ g.fillStyle = bg; g.fill(); return cv; })());
101
+ const k = o.t != null && o.at != null ? MO.step(o.t - o.at + 1e-6, 12) : 1e9; // 一拍二:从 at 起算,at 这一帧就是第一帧
102
+ const pop = k < 1 / 12 ? 1.12 : 1, ox = o.align === 'center' ? -w / 2 : o.align === 'right' ? -w : 0;
103
+ c.translate(x, y); if (o.r) c.rotate(o.r); c.scale(pop, pop);
104
+ c.drawImage(sp, ox, -h / 2);
105
+ const n = o.t != null && o.at != null ? Math.ceil((k + 1 / 12) * (o.rate || 14)) : 1e9;
106
+ c.fillStyle = fg; c.textBaseline = 'middle'; c.textAlign = 'left';
107
+ c.fillText([...text].slice(0, n).join(''), ox + padX, size * 0.04);
108
+ c.restore();
109
+ return { w, h };
110
+ };
111
+
112
+ MD.frameAt = (frames, lt, fps = 30, loop = false) => {
113
+ if (!frames || !frames.length) throw new Error('MD.frameAt:帧序列是空的');
114
+ let i = Math.floor(Math.max(0, lt) * fps + 1e-6);
115
+ i = loop ? i % frames.length : Math.min(frames.length - 1, i);
116
+ const im = frames[i]; MD.size(im); return im;
117
+ };
118
+ })();