Skip to content

Add fidget-wgpu crate#384

Draft
mkeeter wants to merge 12 commits intomainfrom
fidget-wgpu
Draft

Add fidget-wgpu crate#384
mkeeter wants to merge 12 commits intomainfrom
fidget-wgpu

Conversation

@mkeeter
Copy link
Copy Markdown
Owner

@mkeeter mkeeter commented Dec 23, 2025

This is an even-more-experimental WGPU rasterization backend. Basically the same as MPR (2020), but adapted for modern GPU APIs (e.g. indirect dispatch means we don't have to round-trip through the CPU). More to come...

This comment was marked as resolved.

@mkeeter mkeeter marked this pull request as draft December 23, 2025 20:59
@mkeeter mkeeter requested a review from Copilot January 22, 2026 17:06

This comment was marked as resolved.

@mkeeter mkeeter force-pushed the fidget-wgpu branch 2 times, most recently from e1686d9 to f00b30c Compare January 27, 2026 16:32
@mkeeter mkeeter force-pushed the fidget-wgpu branch 3 times, most recently from e889cf5 to 86896a1 Compare April 18, 2026 13:36
@mkeeter mkeeter requested a review from Copilot April 26, 2026 00:46
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 29 out of 31 changed files in this pull request and generated 6 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread fidget-wgpu/README.md Outdated
@@ -0,0 +1,9 @@
`fidget-wgpu` implements 3D rendering of Fidget tapes using WebGPU

It is typically used through the [`fidget`](https://crates.io/crate/fidget)
Copy link

Copilot AI Apr 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The crates.io link for the fidget crate uses /crate/ instead of /crates/, which results in a broken URL. Update it to https://crates.io/crates/fidget.

Suggested change
It is typically used through the [`fidget`](https://crates.io/crate/fidget)
It is typically used through the [`fidget`](https://crates.io/crates/fidget)

Copilot uses AI. Check for mistakes.
Comment thread CHANGELOG.md Outdated
Comment on lines +1 to +5
# 0.4.4 (unpublished)
- Add `fidget-wgpu` crate, which does 3D rasterization with a `wgpu` backend
- This is even more experimental than the rest of Fidget!

# 0.4.3
Copy link

Copilot AI Apr 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changelog header was bumped to 0.4.4 (unpublished), but the crate versions in this PR (including the new fidget-wgpu crate and the workspace-pinned =0.4.3 local crates) are still 0.4.3. This makes it unclear what version the changes will ship under; consider bumping crate versions consistently to 0.4.4 in the same PR, or keeping the changelog header at 0.4.3 (unpublished) until the version bump lands.

Copilot uses AI. Check for mistakes.
Comment thread Cargo.toml Outdated
Comment thread Cargo.toml Outdated
Comment thread fidget-wgpu/src/render3d.rs Outdated
Comment on lines +106 to +109
case OP_MEM: {
// Not implemented!
return out;
}
Copy link

Copilot AI Apr 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OP_MEM is currently treated as "Not implemented" and returns out without setting out.pos / out.count (they stay at 0). That can break interval/voxel rendering for any bytecode that contains Load/Store (e.g., register spills) and can also lead to invalid inputs to simplify_tape(out.pos, out.count, ...) (underflow / out-of-bounds when end == 0). Implement OP_MEM semantics in the interpreter, or at minimum set out.pos/out.count before returning and ensure callers skip simplification when memory ops are encountered.

Copilot uses AI. Check for mistakes.
@mkeeter mkeeter force-pushed the fidget-wgpu branch 3 times, most recently from 2f1100a to 40b35a9 Compare April 26, 2026 12:50
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