[codex] Add WebGL renderer benchmark comparison - #164
Draft
meekmachine wants to merge 1 commit into
Draft
Conversation
Owner
Author
PR backlog triage — DRAFT_KEEP (stacked on #163) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a WebGL renderer benchmark page that uses the same shared procedural Loom3 benchmark harness added in #163.
This is stacked on #163 intentionally, so this PR's diff is only the comparison layer:
npm run benchmark:webglexamples/webgl-benchmark/index.htmlexamples/webgl-benchmark/main.jsThe result shape matches the WebGPU benchmark exactly and writes to the browser console plus
window.__loom3BenchmarkResult.How to run
Open the printed local URL and inspect the browser console.
Validation
npm testpassed: 28 files, 179 tests.npm run buildpassed.npm run typecheckpassed.http://localhost:4173/examples/webgl-benchmark/.Smoke result excerpt:
{ "renderer": "WebGLRenderer", "threeRevision": "170", "rendererFlags": { "isWebGPURenderer": false, "isWebGLRenderer": true, "backend": null }, "setup": { "hairRegistrationCount": 1, "morphMeshCount": 2 }, "submitMs": { "avg": 0.2, "p95": 0.3, "p99": 0.4 }, "approximateFpsFromRaf": 71.978 }Notes
Because this PR targets #163's branch, checking out this top branch gives both benchmark commands for side-by-side browser-console comparison.