Follow Slashdot blog updates by subscribing to our blog RSS feed


Forgot your password?

Submission + - 3D Teapot Classic Using Pure DHTM - who needs HTML5? (

mikejuk writes: This is a project of madness — but you have to admire it. Render the classic 3D Teapot using nothing but DHTML, i.e. JavaScript and HTML but no canvas, no CSS 3, no SVG? It sounds impossible — but it's not. The key is that you can take a div and, using JavaScript, you can assign it a color, size and position. This means you have a small rectangular graphics component that you can use to create other shapes. In other words DHTML (Dynamic HTML) already has a primitive vector graphics ability. You can even work with bitmap graphics if you shrink the div down to the size of a single pixel, but this might just overload the layout engine of a typical browser. The solution is to make use of a quirk of the div that does allow you to show a triangular area of color. Once you have a triangle the rest follows and soon you have a full 3D pipeline and the classic teapot fully rendered using nothing but old fashioned HTML. It all raises the question of do we actually need HTML5, let alone canvas or WebGL?
This discussion was created for logged-in users only, but now has been archived. No new comments can be posted.

3D Teapot Classic Using Pure DHTM - who needs HTML5?

Comments Filter:

System restarting, wait...