Re: Use Cases for The <canvas> Element

Laura Carlson wrote:
> I began adding info from this canvas element thread into the wiki.
> 
> http://esw.w3.org/topic/HTML/AddedElementCanvas
> 
> If you find anything that needs changing, please revise. Or if you
> have further info please add it.

Laura

Perhaps this would work well as a multiple solution pro/con analysis 
like other proposals for the spec. Something with a structure like (I'm 
sure others can fill in many of the gaps caused by my ignorance):

Requirement:
Simple script-driven drawing for rendering dynamic bitmap graphics on 
the fly.

Use Cases:
Charts - Plotkit + etc.
Simple games -
Mathematics -
Decorative effects -
etc.

Proposed solutions:

<canvas> element + API
Pros:
Simple mapping on to platform graphics APIs - easy to implement
Mostly interoperable implementations for 3/4 major  browsers + scripted 
implementation for IE
Element allows for rich fallback content
Large test suite available
Cons:
Semantically element is close to <img> but has a different name

<img> element + drawing API
Pros:
Architecturally cleaner than <canvas>
Cons:
No existing implementations
Duplicates <canvas> functionality that is unlikely to be removed from UAs
Harder to implement? (this was claimed somewhere I think)
Poorer fallback story than <canvas>

SVG
Pros:
Provides for wide range of graphics needs in single spec
Test suite available [2]
Cons:
Large and complex to implement; existing browser implementations do not 
cover all the features needed to replace <canvas>
Optimized primarily for vector graphics; does not cover exactly the same 
use cases
Works best in XML content

[1] http://canvex.lazyilluminati.com/tests/tests/
[2] 
http://www.w3.org/Graphics/SVG/Test/20061213/htmlObjectHarness/full-index.html
-- 
"Mixed up signals
Bullet train
People snuffed out in the brutal rain"
--Conner Oberst

Received on Monday, 30 July 2007 20:43:15 UTC