Skip to main content

HTML5 Media and Canvas

  • Chapter
  • 793 Accesses

Abstract

While the SVG environment is a declarative graphics environment dealing with vector-based shapes, the HTML Canvas provides a script-based graphics environment revolving around pixels or bitmaps. In comparison with SVG, it is faster to manipulate data entities in Canvas, since it is easier to get directly to individual pixels. On the other hand, SVG provides a DOM and has an event model not available to Canvas. Thus, applications that need graphics with interactivity will typically choose SVG, while applications that do a lot of image manipulation will more typically reach for Canvas. The available transforms and effects in both are similar, and the same visual results can be achieved with both, but with different programming effort and potentially different performance.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   29.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   39.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2010 Silvia Pfeiffer

About this chapter

Cite this chapter

Pfeiffer, S. (2010). HTML5 Media and Canvas. In: The Definitive Guide to HTML5 Video. Apress. https://doi.org/10.1007/978-1-4302-3091-5_6

Download citation

Publish with us

Policies and ethics