News for hackers. Stuff that matters.
Re:Show HN: A simple 2D fluid and gravity simulation with WA... by vrtnis on Friday May 10, 2024 @12:56PM (#40321200)
very cool! if you're exploring wasm for graphics, take a look at Wander- lets you create and execute "renderlets" — portable modules containing graphics data and code compiled to wasm https://github.com/renderlet/wander
Re:Show HN: A simple 2D fluid and gravity simulation with WA... by CSMastermind on Friday May 10, 2024 @06:29PM (#40324365)
This is probably a dumb question but I assume anything leveraging WASM can only run on the CPU?
Re:Show HN: A simple 2D fluid and gravity simulation with WA... by vrtnis on Friday May 10, 2024 @07:22PM (#40324686)
while it's true that wasm was originally designed to run primarily on the cpu(e.g., executed in a sandboxed environment on the main thread, which is generally managed by the cpu), the assumption that wasm only runs on the cpu might be becoming a bit dated. esp. as a result of webgpu and frameworks mentioned above, wasm is increasingly capable of executing on the gpu imho.