|
9 | 9 | brew install webp ffmpeg # for img2webp and ffmpeg |
10 | 10 |
|
11 | 11 | Usage: |
12 | | - # 1. Serve this directory locally: |
13 | | - python -m http.server 8765 --directory tools/ |
| 12 | + # 1. Serve the repo root locally (so /assets/js/source-palette.js resolves): |
| 13 | + python -m http.server 8765 |
14 | 14 |
|
15 | 15 | # 2. Run the capture: |
16 | 16 | python tools/capture_globe_rotation.py |
|
35 | 35 |
|
36 | 36 | async def capture_globe(num_frames=120, duration_sec=15, output_path="/tmp/isamples_globe.webp", |
37 | 37 | width=800, height=500, quality=40, |
38 | | - url="http://localhost:8765/globe_capture.html"): |
| 38 | + url="http://localhost:8765/tools/globe_capture.html"): |
39 | 39 | from playwright.async_api import async_playwright |
40 | 40 |
|
41 | 41 | frame_dir = tempfile.mkdtemp(prefix="globe_frames_") |
@@ -163,7 +163,7 @@ def main(): |
163 | 163 | parser.add_argument("--width", type=int, default=800, help="Width in pixels (default: 800)") |
164 | 164 | parser.add_argument("--height", type=int, default=500, help="Height in pixels (default: 500)") |
165 | 165 | parser.add_argument("--quality", type=int, default=40, help="WebP quality 0-100 (default: 40)") |
166 | | - parser.add_argument("--url", default="http://localhost:8765/globe_capture.html", help="Page URL") |
| 166 | + parser.add_argument("--url", default="http://localhost:8765/tools/globe_capture.html", help="Page URL") |
167 | 167 | args = parser.parse_args() |
168 | 168 |
|
169 | 169 | asyncio.run(capture_globe( |
|
0 commit comments