Tuesday, 11. September 2007, 16:22:21
3d, widget, globe
Well, I've updated my
3D Globe Widget to now shade the night side of the Earth. I ended up accomplishing it by overlaying a semitransparent hemisphere over the existing globe. Since those triangles are monochromatic, I can draw them with simple path filling instead of image mapping, making a higher detail level for the shadow practical. In order to rotate independent of the globe when necessary (for updating the shadow's location), the shadow triangles have their own camera.
Wednesday, 22. August 2007, 22:54:55
canvas, 3d, widget, globe
As far as my experiments go, my most recent and currently favorite one can be seen in my
3d globe widget.
There are lots of ways to fake 3D on a 2D canvas context; I'll just note my texture mapping method here since I haven't seen it elsewhere.
In a nutshell, my textures are images like the following:

From the coordinates of the destination triangle, I calculate a transformation to map the texture triangle to the rendered triangle, then draw the texture with drawImage(...). While true perspective mapping doesn't work well, this method does seem to work reasonably fast.
Here's the unzipped widget file, if you are reading this on a Wii or just don't want to bother with a widget. You can click and drag the globe to rotate it.
edit: This is an old, 20 polygon version. If I can find an easy way to upload 132 files, I'll update this with a link to the 128-poly version.
Wednesday, 22. August 2007, 22:45:24
cliche
Everybody else seems to be starting a blog. May as well start one too...
So, if I have something to say, I guess I'll put it here.
I like to try making weird things on the computer, and web technologies are easy to develop in. So, most of my experiments are browser-based.