dan's blog

3D Cube

thumbnail: 
The idea at first was to make a 3D menuing system in Javascript where you choose from potentially hundreds of elements by mousing over an interactive 3D environment. This proof-of-concept is a cube with 64 (4x4x4) elements in it.

For now it's a basic 3D object inspection applet that uses your browser's DOM to store and manipulate a 3D object by plotting a set of points in 3D space using only rectangular DIVs. The 'closer' elements are rendered bigger than the farther ones and use z-indexing for hiding obscured elements. This doesn't use any trigonometric functions -- just integer arithmetic -- so this should be pretty fast even on a slow browser.

Mouse over the applet and see for yourself. Seems to work on every modern browser I've tested except for IE8 -- it seems IE8 particularly has a lot of problems like this in the wild, so I'm not fixing it for this browser yet.

Mathematical ASCII Movie

thumbnail: 
A Javascript for calculating and running a simple ASCII movie.

It uses the setTimeout and clearTimeout methods in Javascript as well as Javascript's built in integer arithmetic functions and arrays -- all the calculating, arithmetic and data storage are done by your browser, so it is very scalable and lightweight (for the server at least).

This is a web application proof-of-concept for visualization of data and mathematical concepts. It has 80x20 'pixels' in it with 2-bit 'color' -- 4 values for each pixel.


Syndicate content