{"id":"book-flip","version":"1.0.0","title":"Book Flip","summary":"An open book whose pages turn one after another in a gentle breeze, then turn back. Loops perfectly.","kind":"object","target":"three","collections":["satisfying","hypnotic-loops","product-reveals"],"tags":["book","pages","page turn","reading","library","story","paper","flip","loop","3d"],"loopable":true,"motion":"procedural","durationSeconds":16,"status":"published","media":{"poster":"https://aipixelwizard.com/media/book-flip/1.0.0/poster.webp","preview":"https://aipixelwizard.com/media/book-flip/1.0.0/preview.mp4","sample":"https://aipixelwizard.com/media/book-flip/1.0.0/sample.mp4","sampleBytes":3232832,"sampleNote":"Pre-rendered with the default settings. Customised settings must be exported locally (npm run render)."},"urls":{"page":"https://aipixelwizard.com/visuals/book-flip","manifest":"https://aipixelwizard.com/api/v1/visuals/book-flip/versions/1.0.0","agentMd":"https://aipixelwizard.com/registry/book-flip/1.0.0/agent.md","files":"https://aipixelwizard.com/registry/book-flip/1.0.0/","demo":"https://aipixelwizard.com/registry/book-flip/1.0.0/index.html"},"description":"An open book on a desk in lamplight: each page rises, curls over the spine in a soft arc and settles on the left, revealing the next spread of printed lines, drop capitals, little pictures and page numbers; when the last page has turned they all turn back, one after another, and the book is where it began. Choose the number of pages, the cover cloth (oxblood, navy, forest or black), the paper, how much the pages curl, the seed, the backdrop and whether the camera drifts.","role":"Object (3D, three.js): a quiet, literary hero object for reading, education, story and knowledge content.","useCases":["An education, library or reading-app title scene","A storytelling or fairy-tale opener","A knowledge-base or documentation backdrop"],"synonyms":["page flip","turning pages","open book","book animation","flipping pages","storybook"],"digest":"45006221ab73d57a26ea6146b574024ad85f541415cc66e16312e1af5c26913d","implementation":{"target":"three","runtime":"browser","language":"javascript","module":"esm","entry":"src/book-flip.js","exports":[{"name":"createBook","signature":"createBook({ pages?, cover?, curl?, seed?, paper? }) => { group, setProgress(progress), dispose() }","description":"The covers, spine and curling pages as a group (pages 3 × 4, spine on the y axis); add it with a shadow-casting light."},{"name":"COVERS","signature":"COVERS: { oxblood, navy, forest, black }","description":"Cover cloth colours."}],"reusable":["src/book-flip.js"],"demo":"demo.js","harness":"index.html"},"dependencies":[{"id":"three","version":"0.185.1","scope":"source","reason":"Renderer, geometry and materials."},{"id":"chrome-material","version":"1.1.0","scope":"demo","reason":"Studio environment light, backdrop and contact shadow."},{"id":"apw-runtime","version":"1.0.0","scope":"demo","reason":"Demo harness."}],"uses":[],"usedBy":[],"params":[{"key":"pages","label":"Pages","help":"Leaves in the book; each has two printed sides.","type":"integer","min":4,"max":10,"step":1,"default":8},{"key":"cover","label":"Cover","type":"select","default":"oxblood","options":[{"value":"oxblood","label":"Oxblood"},{"value":"navy","label":"Navy"},{"value":"forest","label":"Forest"},{"value":"black","label":"Black"}]},{"key":"paper","label":"Paper","type":"color","default":"#f1e8d2"},{"key":"curl","label":"Curl","help":"How much a page bends as it turns.","type":"number","min":0,"max":1.6,"step":0.05,"default":1},{"key":"seed","label":"Seed","type":"integer","min":1,"max":999,"step":1,"default":4},{"key":"background","label":"Backdrop","type":"color","default":"#241a12"},{"key":"orbit","label":"Camera drift","type":"boolean","default":true}],"presets":[{"id":"default","label":"Oxblood, eight leaves","params":{}},{"id":"navy","label":"Navy, cream paper","params":{"cover":"navy","paper":"#ede6d6","seed":9,"background":"#101a2a"}},{"id":"forest","label":"Forest, many pages","params":{"cover":"forest","pages":10,"seed":14,"background":"#12201a"}},{"id":"gentle","label":"Gentle curl","params":{"curl":0.4,"cover":"black","pages":6,"background":"#1c1c1e"}}],"output":{"width":1080,"height":1080,"fps":30,"durationSeconds":16,"posterSeconds":4,"alpha":false,"motion":"procedural","loop":{"seamless":true,"cycleSeconds":16,"method":"In the first half of the loop the pages turn forward one after another and in the second half they turn back in the same order; each page's angle and curl are smooth functions of the loop, so the book ends where it began."},"seed":{"param":"seed","behavior":"Seed sets the printed lines, capitals and pictures on every page: same seed, same book."}},"composition":{"inputs":"Time within the loop; the number of pages, cover, paper, curl, seed, backdrop and camera drift.","outputs":"A full frame rendered in 3D with soft shadows.","coordinates":"The spine is on the y axis, each page is 3 wide (x) and 4 deep (z); unturned pages lie to the right, turned ones to the left.","lighting":"A warm key light with a shadow map and a studio environment.","timing":"setProgress(progress) sets every page's turn; frames render in any order.","compatibleWith":["chrome-material","orbit-camera","kinetic-title","number-reveal"],"notes":["Each page is a 28-segment strip whose segment directions are the turn angle plus a bend; the strip is rebuilt every frame on the CPU.","Page faces are canvas textures drawn once; the back face is the same texture mirrored."]},"reuse":["Reading-app or library title: Oxblood, eight leaves.","Documentation backdrop: Navy, cream paper.","Storybook opener: Forest, many pages."],"integration":{"newProject":"Create a WebGLRenderer with shadows, add createBook().group and call book.setProgress(progress) each frame.","existingProject":"Copy src/book-flip.js; add book.group to your scene with a shadow-casting light."},"performance":{"notes":"Up to ten 56-vertex strips rebuilt on the CPU each frame, a few boxes and one shadow map. A few milliseconds a frame on an integrated Intel GPU.","limits":"Software WebGL renders in about a second a frame."},"limitations":["The pages turn on a hinge without collision, so a turning page may pass through its neighbours by a hair.","The text is suggested by bars, not real letters."],"license":{"spdx":"MIT","notice":"Copyright (c) 2026 AI Pixel Wizard. Released under the MIT License. See LICENSE in this folder.","thirdParty":[]},"rights":{"approvedForPublicRelease":true},"provenance":"Adapted from the owner's threejs-sketches/objects-scenes/book-flip (MIT) and rebuilt for AI Pixel Wizard in October 2026 as an original object: curling page strips as closed forms of the loop, procedurally printed page textures and a forward-then-back turn sequence for an exact loop.","changelog":[{"version":"1.0.0","date":"2026-10-05","notes":"Initial release."}],"verification":{"testedOn":"2026-10-06","inputs":{"book-flip@1.0.0":"45006221ab73d57a26ea6146b574024ad85f541415cc66e16312e1af5c26913d","three@0.185.1":"664ca387e5fab46ff2daaa6895e1d015426850891af5ea5082cbbcc3985b068c","chrome-material@1.1.0":"ecb41776bfc1ee88997604f916a5ffe833f971d7edcc97c855697a5792d6f1dd","apw-runtime@1.0.0":"5be859cdac74823ba0bcc32c6daf06688a871104d24db5d4ceaffffd84d7c40d"},"environment":"Chrome 154.0.8037.97 headless on Linux 7.0.0-38-generic (x64), Node 22.14.0","renderer":"WebGL 2 via SwiftShader (software)","width":1080,"height":1080,"fps":30,"frames":480,"renderSeconds":1597.9,"loopCheck":{"checked":true,"seamless":true,"maxDifference":0,"note":"Frame 0 vs end state (progress 1): mean |Δ| 0.0000, max |Δ| 0 of 255."},"determinism":{"checked":true,"identical":true},"errors":[],"media":{"poster":"/media/book-flip/1.0.0/poster.webp","preview":"/media/book-flip/1.0.0/preview.mp4","sample":"/media/book-flip/1.0.0/sample.mp4","sampleBytes":3232832}},"files":[{"path":"LICENSE","size":1072,"sha256":"8a5f3a96f07e11522ec4bdd0a583356f99bad1245920f9709cee09b995a45153","contentType":"text/plain; charset=utf-8","url":"https://aipixelwizard.com/registry/book-flip/1.0.0/LICENSE"},{"path":"asset.json","size":7727,"sha256":"415d4f7dbeee396aaa9de7144a7a284e164c136909e049998f5649dc1d456df7","contentType":"application/json; charset=utf-8","url":"https://aipixelwizard.com/registry/book-flip/1.0.0/asset.json"},{"path":"demo.js","size":2842,"sha256":"68743ce69fd5db2b43c098b8932a0e4cea98463dcfd7025a414900b933f2c2ae","contentType":"text/javascript; charset=utf-8","url":"https://aipixelwizard.com/registry/book-flip/1.0.0/demo.js"},{"path":"index.html","size":523,"sha256":"542dc01b02f97e6df62c54ee18b926a8948adcc96cc73ff44250a303b487e7c4","contentType":"text/html; charset=utf-8","url":"https://aipixelwizard.com/registry/book-flip/1.0.0/index.html"},{"path":"src/book-flip.js","size":7068,"sha256":"195d1bf46afba94baef5197cb4f45cbf820a71a65c84191f2d60810cfe8e835b","contentType":"text/javascript; charset=utf-8","url":"https://aipixelwizard.com/registry/book-flip/1.0.0/src/book-flip.js"}],"warnings":[]}