|
1 | | -This is, by far, the devlog with most hours registered this project has ever had. So, what new, cool thing did I implement? Nothing! This time was almost entirely dedicated writing _documentation_, and preparing the project to be released. |
| 1 | +A month later, we're in the world wide web! |
2 | 2 |
|
3 | | -One of the main challenges I knew I'd have to face when starting this project was explaining it to other people. The math behind it is quite complex (get it?), so I knew that, eventually, I'd have to write some sort of educational guide to tell people what it does, and how to use it. More than nine hours later, we're done! |
| 3 | +From the beginning of the project, I kept telling myself that I would, eventually, port it to Web Assembly. Many architectural choices were made with this in mind (not using compute shaders, sticking to version 330 features, using ImGUI for the frontend, not using a file system, etc). |
| 4 | +I just knew that this would be sort of a headache, and kept delaying it, but it comes a time at our lives where we have to accept that not everyone wants to download a sketchy binary from github. So we had to port it to web assembly! |
4 | 5 |
|
5 | | -I figured most people learn better visualy, so I poured some of my time to learn how to use Manim, the animation software 3blue1brown uses for his videos. I made about a dozen animations with it, and wrote a guide to introduce a laymen into complex analysis and function plotting. |
6 | | -Additionally, I also documented how the tool works internally (basically doing the same thing that I already did with the devlogs, but to more depth), and its features. |
7 | | -This, plus an install guide, getting a bunch of screenshots and videos from the plotter to put in README, makes us have completed our project's documentation! |
| 6 | +For those not familiar with the tech, WebAssembly (wasm, for short), is essentially the low-level language of the web. The advantage is that it's faster than javascript, and many languages can compile down to it - and that includes C++! |
| 7 | +Our graphics core is entirely made in OpenGL, but thankfully, a tool named Emscripten also handles this conversion by turning OpenGL into WebGL (the web equivalent). So, we just had to rewrite our code to handle things specific to the web. |
8 | 8 |
|
9 | | -A small portion of this time was also dedicated to making the project build to a single executable, for it to have a favicon, and other small quality-of-life changes. Next we'll bugfix, and this project will be ready to ship! |
| 9 | +Our main change was the textures that we were using to send data to our shaders. Originally, this was done through `samplerBuffer`s, which don't exist in the version OpenGL runs. This made us have to change our data to 2D textures, `sampler2D`. This requires a little more math to get data from the texture, but it's small enough to be a change applied both to the desktop and web version (to avoid refactoring headache). |
10 | 10 |
|
11 | | -Attached, some of the animations! |
| 11 | +The rest is changing the main loop logic (to be step-based), the event callbacks, and creeating a basic UI. Attached, our code running in the website! |
12 | 12 |
|
13 | | -**Related Commits** |
14 | | -[Commit a160c09](https://url.jam06452.uk/754z65): Finished basic settings for deployment |
15 | | -[Commit fae6ce0](https://url.jam06452.uk/1c5esi5): Added grid warping |
16 | | -[Commit 42ee549](https://url.jam06452.uk/1v2p4t0): Finished the-basics documentation |
17 | | -[Commit 5bb3f81](https://url.jam06452.uk/akab42): Added advanced.md and assets |
18 | | -[Commit 6a5f185](https://url.jam06452.uk/44q6td): Added images to features.md, started README.md |
19 | | -[Commit 30b3560](https://url.jam06452.uk/e7mrhd): Finished readme.md |
| 13 | +Take a look for yourself in: https://sekqies.github.io/complex-plotter/ |
20 | 14 |
|
| 15 | +**Commits** |
| 16 | +[04e5437](https://url.jam06452.uk/1w417ue): Working web assembly build - ImGUI not working |
| 17 | +[181a62c](https://url.jam06452.uk/up08en): Finished web assembly porting |
| 18 | +[5ea3105](https://url.jam06452.uk/1s6zjmu): Add web deploy |
| 19 | +...and 7 other commits fixing github |
0 commit comments