Then I convert it to spherical coordinates and get rid of the ratio to ignore the magnitude of the vector and add it to the position of foreground points. Then you segregate the selected array into the foreground and background, find the arithmetic mean of the fg and bg, respectively and find the difference. Then loop through every 50 milliseconds, apply a 3d transformation, get points that lie within a radius of the mouse position and reference them in the selected array. It starts off simple enough, do lots of freaky trigonometric loops to generate a set of points that lie on a sphere. It is based on my js1k entry, and I considered making this a 1k submission, but I gave up and said I couldn’t. At ~300 LOC of pretty trivial JS, it’s not much at all (though it is hideous, I must warn you). So how does it work? It’s actually really simple, and probably too simple. The pictures on the top of the page are of the death star and alderaan, respectively, mostly because planets (and moons that aren’t moons) are mostly spherical and explosions and light rays are pretty much the only things that this app is suitable for at these stages. Eventually, I ended up basing it off my js1k function plotter, because it’s a fairly simple 3d renderer. Panorama is so slow it lags from simple dragging). First I thought of using WebGL, but trying to start chromium with webgl always ends up with a GLXFBConfig error, and on Firefox, it’s stuck with using libosmesa which gives absolutely terrible framerates ( IDK why but Fx4 crawls on my computer. It’s windows-only, and I thought it would be neat to have something like it that works in the browser. It’s this amazing digital sculpting app where your canvas is basically a blob of virtual clay that can be molded into any shape with any level of detail. So for the past few days, I discovered this neat app called Sculptris. ![]() If you want to contact me or read obnoxiously nostalgic autobiographical trivia, check out the about section. This is my little corner of the internet, where I talk about random projects and ideas and stuff. I’m Kevin Kwok, and I’m currently a junior at MIT,Īnd this is my obligatory online presence or whatever.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |