Do you know anything about any WASM developments that will enable pure WASM interaction with the browser's Web-APIs at no or at a low cost without the JS layer? Sometimes I look at https://github.com/WebAssembly/proposals and it's very confusing. There are the type imports proposal(years away), the almost complete GC proposal(which is apparently only for GCd languages, but not for anything browser wasm), the componen…
Show HN: Unity like game editor running in pure WASM
81–90 of 166 posts
Re: Show HN: Unity like game editor running in pure WASM
#82Earlier quoted context omitted.
do you know what engine was in use or development during around 2002-2003? the engine was somewhat baked but flexible and had entry points where you drop c++ snippets in, I believe with a GUI
Was it a 2D game engine? I recall before using Zero I used an engine called ProjectFUN, which is similar to what you described. That was around 2013 though, not 2002.
Re: Show HN: Unity like game editor running in pure WASM
#83Do you know anything about any WASM developments that will enable pure WASM interaction with the browser's Web-APIs at no or at a low cost without the JS layer? Sometimes I look at https://github.com/WebAssembly/proposals and it's very confusing. There are the type imports proposal(years away), the almost complete GC proposal(which is apparently only for GCd languages, but not for anything browser wasm), the componen…
Reference types technically already allow for calling directly into the browser APIs as reference types allow wasm to pass JavaScript objects around. So if you import all the relevant web apis, you don't really need any (almost any?) intermediate JS anymore, because you can just forward the JS objects between the individual API calls. The only real need for JS would be to initialize the wasm module in the first place…
I don't think that's true. You still need JS glue code that would return these externrefs. A WebAssembly module loaded through ESM integration can't as far as the current proposals access Web-APIs on its own. As far as I understand there is also a number performance issues related to the wasm spec itself that limit possible optimizations, making wasm second class to JS in terms of performance of WebAPI access.
Re: Show HN: Unity like game editor running in pure WASM
#84Earlier quoted context omitted.
I'm getting a really nice smooth experience on my Intel HD Graphics 620 (7th gen intel integrated graphics, old and slow). Also just looking at the default ball scene, and I was really impressed how smooth it was on my system. I'm using chrome.
I suspect this is possibly down to the use of readPixels and how slow that is on various devices. The engine seems to run in a worker and render to an offscreen canvas then transfer the image data in JS to the main thread before drawing it to a canvas there.
I just did some profiling on Firefox and I feel like the profiling result doesn't quite make sense but it's saying that the majority of time is spent calling Performance.now() from the clock calls in C++. I'm wondering if that's because we're calling it too many times and maybe we should just call it once per frame.
Re: Show HN: Unity like game editor running in pure WASM
#85How do I add WASD controls to the camera?
Re: Show HN: Unity like game editor running in pure WASM
#86I like the concept. My GPU and browser weep with lag. Its a very impressive slideshow. I finally managed to highlight the starting sphere after several tries. At first I wasn't sure if it was loaded. Of course, I'm only using a 1.8 GHz Celeron with onboard GPU and 8GB Ram in Firefox, so... not exactly high-end stuff.
I'd be curious if it runs any better under Chrome. Seems a lot of people are hitting Firefox issues. I'll be sure to test Firefox regularly though.
I know personally, anything 3d in Firefox is a slideshow, even with a 4090
Re: Show HN: Unity like game editor running in pure WASM
#87How are Raverie spaces different from Unity scenes?
To be honest I haven't spent much time in Unity. Back in the day you either had to parent objects to the camera to make UI, or use a completely different UI system. It sounds like now Unity scenes can be overlaid on top of each other, is that correct?
You also don't need to parent objects to the camera for UI. Not sure how it used to be in the past.
Re: Show HN: Unity like game editor running in pure WASM
#88Earlier quoted context omitted.
I'd be curious if it runs any better under Chrome. Seems a lot of people are hitting Firefox issues. I'll be sure to test Firefox regularly though.
AFAIK, Firefox has all around awful webgl and webgpu performance. I know personally, anything 3d in Firefox is a slideshow, even with a 4090
Re: Show HN: Unity like game editor running in pure WASM
#89I like the concept. My GPU and browser weep with lag. Its a very impressive slideshow. I finally managed to highlight the starting sphere after several tries. At first I wasn't sure if it was loaded. Of course, I'm only using a 1.8 GHz Celeron with onboard GPU and 8GB Ram in Firefox, so... not exactly high-end stuff.
I'd be curious if it runs any better under Chrome. Seems a lot of people are hitting Firefox issues. I'll be sure to test Firefox regularly though.
Re: Show HN: Unity like game editor running in pure WASM
#90Earlier quoted context omitted.
I'd be curious if it runs any better under Chrome. Seems a lot of people are hitting Firefox issues. I'll be sure to test Firefox regularly though.
AFAIK, Firefox has all around awful webgl and webgpu performance. I know personally, anything 3d in Firefox is a slideshow, even with a 4090
It was laggy in Windows and under X11 on linux, but under Wayland I get 60-80fps and it's very usable.
Not sure what the cause is
EDIT: Under Chromium (compiled from AUR) the performance is roughly the same