SlideShare une entreprise Scribd logo
1  sur  23
Télécharger pour lire hors ligne
From Flash to Canvas  a penchant for black holes




        @flashpatric
THIS PRESENTATION
            Canvas 2D context
                  History
                   Today
How a display list will make your life easier
   Tools for a better Canvas experience
                   Demo
WHAT’S CANVAS?!
  <canvas id=”canvas”></canvas>

 A part of the HTML5 standard
        Dynamic bitmap
 API’s for drawing and using text
ADVANTAGES
                      From a Flash developers point of view
Low learning curve                       Powerful along with other new functions
Very good performance in new browsers        Semantics
                                             Offline & Storage
Image manipulation down to pixel level
                                             Device access
Lots of proven JS-libraries                  Connectivity
Pretty high market penetration               Audio & video
                                             3D graphics & effects
3D context – WebGL
                                             Performance & Integration
GPU acceleration                             CSS3
HISTORY
                                  Flash vs HTML
                            FutureSplash    1995   HTML 3.2 draft, Internet Explorer
                           Macromedia       1996   I Learned HTML
                                            1998   HTML 4.01 draft
My first Flash applikation, Actionscript 1   2000
                          Actionscript 2    2003   Firefox
                                            2004   WHATWG
                                  Adobe     2005
                          Actionscript 3    2006
                                            2007   HTMLWG, death of XHTML
                             Adobe AIR      2008   Google Chrome
        Mobile Flash Player, Scepticism     2009   HTML5
          Adobe AIR for Android & iOS       2010   IE9
Adobe AIR for iOS, Mobile Flash Player      2011   Shifting focus, comunication fail
TODAY
                   HTML5 Canvas 2D market penetration

Canvas basic support                          Text API for Canvas
71.17%                                        70.56%
Opera Mini has partial support for Canvas     Opera Mini is missing support for Text API


CSS Canvas Drawing                            Full Screen API
35.56% (Chrome, Safari, iOS Safari, Android   0%
browser)                                      Partial support in Firefox, Chrome och Safari
TODAY
                             Canvas 2D Context in Internet Explorer

IE8 and below is missing support for Canvas                      <!DOCTYPE html>
                                                                 <html>
Polyfills can be used for VML in IE7 and IE8                      <head>
                                                                     <meta charset="utf-8">
Explorercanvas.js                                                    <title>Dive Into HTML5 Canvas</title>
                                                                     <!--[if lt IE 9]>
Everything is not supported, there’s limitations!
                                                                           <script src="excanvas.js"></script>

     -   Only linear gradients                                       <![endif]-->
     -   Patterns must repeat in both directions                 </head>
     -   Clipping paths is not supported                         <body> ... </body>
     -   Non-uniform scaling does not scale outlines correctly   </html>
     - Really bad performance
DISADVANTAGES
                 From a Flash developers point of view

Polyfills is needed for older browsers   There is no editor for Canvas yet
No timeline or API for animations       Drawn objects is only pixels
Bad text rendering                      No display list/scene graph
THE OPTIMIST
                       But there’s hope for Canvas

Polyfills cover some needs           Adobe Flash Professional CS6
We’re programmers!                  Dynamic pixels

Web fonts                           Logic display list
WHAT A DISPLAY LIST IS
”A hierarchic list with graphical objects
      described with its properties”
WHAT A DISPLAY LIST IS
Display Object                            Different objects and properties
Family based – parents and children       Stage          x&y

Inherits from an abstract class           Bitmap         alpha

Renders in relation to its parent         Shape          scaleX & scaleY
Its properties determines the rendering   Text           Etc..
THE TOOLS
CREATEJS
A suite of Javascript libraries & tools for building
     rich, interactive experiences with HTML5
EASELJS
          Based on the Flash display list

        Display list and display list objects

                  DOM-elements

Mouse events on objects, even onClick and onPress

                  Touch support
TWEENJS
A Javascript library for tweening and animating HTML5
                 and Javascript properties
SOUNDJS
  A Javascript library that provides a simple API, and
powerful features to make working with audio a breeze
PRELOADJS
A Javascript library that lets you manage and co-ordinate
                   the loading of assets
ZOË
  A stand alone tool for exporting SWF animations as
EaselJS sprite sheets that can be used in Canvas and CSS
DEMO!
Adobe Flash Professional CS6
         Toolkit for CreateJS
                  Nested animations
                  Sounds
                  Dynamic texts
                  Vector objects
                  Armature
                  Shape morphs
DEMO!
Founder of CREATEJS
                            Grant Skinner
                                  gskinner.com
Recognized speaker, leader and innovator within
                              interactive media
                                       Gtween
                                        RegExr
                                      CreateJS
                                       EaselGL
THANKS!
    Patric Jonsson
Interactive Developer

      @flashpatric
 flashpatric@gmail.com

Contenu connexe

Tendances

Class 4: Introduction to web technology entrepreneurship
Class 4: Introduction to web technology entrepreneurshipClass 4: Introduction to web technology entrepreneurship
Class 4: Introduction to web technology entrepreneurship
allanchao
 
Debugging Web Apps on Real Mobile Devices
Debugging Web Apps on Real Mobile DevicesDebugging Web Apps on Real Mobile Devices
Debugging Web Apps on Real Mobile Devices
Dale Lane
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
tutorialsruby
 
Familiar Tools, New Possibilities: Leveraging the Power of the Adobe Web Pub...
Familiar Tools, New Possibilities:  Leveraging the Power of the Adobe Web Pub...Familiar Tools, New Possibilities:  Leveraging the Power of the Adobe Web Pub...
Familiar Tools, New Possibilities: Leveraging the Power of the Adobe Web Pub...
John Hartley
 

Tendances (20)

Hooray Icon Fonts! Artifact Conference
Hooray Icon Fonts! Artifact ConferenceHooray Icon Fonts! Artifact Conference
Hooray Icon Fonts! Artifact Conference
 
Hooray Icon Fonts workshop
Hooray Icon Fonts workshopHooray Icon Fonts workshop
Hooray Icon Fonts workshop
 
Accessibility in pattern libraries
Accessibility in pattern librariesAccessibility in pattern libraries
Accessibility in pattern libraries
 
Starting mobile development
Starting mobile developmentStarting mobile development
Starting mobile development
 
Class 4: Introduction to web technology entrepreneurship
Class 4: Introduction to web technology entrepreneurshipClass 4: Introduction to web technology entrepreneurship
Class 4: Introduction to web technology entrepreneurship
 
Overview of Using Wordpress for Web Site Design
Overview of Using Wordpress for Web Site DesignOverview of Using Wordpress for Web Site Design
Overview of Using Wordpress for Web Site Design
 
Debugging Web Apps on Real Mobile Devices
Debugging Web Apps on Real Mobile DevicesDebugging Web Apps on Real Mobile Devices
Debugging Web Apps on Real Mobile Devices
 
The Audio User Experience for Widgets
The Audio User Experience for WidgetsThe Audio User Experience for Widgets
The Audio User Experience for Widgets
 
&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />&lt;img src="../i/r_14.png" />
&lt;img src="../i/r_14.png" />
 
Adobe XD
Adobe XD Adobe XD
Adobe XD
 
Familiar Tools, New Possibilities: Leveraging the Power of the Adobe Web Pub...
Familiar Tools, New Possibilities:  Leveraging the Power of the Adobe Web Pub...Familiar Tools, New Possibilities:  Leveraging the Power of the Adobe Web Pub...
Familiar Tools, New Possibilities: Leveraging the Power of the Adobe Web Pub...
 
Adobe Max 2009 - Learnings
Adobe Max 2009 -  LearningsAdobe Max 2009 -  Learnings
Adobe Max 2009 - Learnings
 
FLASH AND AIR IN EDUCATION
FLASH AND AIR IN EDUCATIONFLASH AND AIR IN EDUCATION
FLASH AND AIR IN EDUCATION
 
Explaining Ajax
Explaining AjaxExplaining Ajax
Explaining Ajax
 
Is the Past. Is the Future. Is the Browser.
Is the Past. Is the Future. Is the Browser.Is the Past. Is the Future. Is the Browser.
Is the Past. Is the Future. Is the Browser.
 
Titanium appcelerator sdk
Titanium appcelerator sdkTitanium appcelerator sdk
Titanium appcelerator sdk
 
Responsive Web Design
Responsive Web DesignResponsive Web Design
Responsive Web Design
 
Developing Modern Web Interfaces with Dreamweaver CC
Developing Modern Web Interfaces with Dreamweaver CCDeveloping Modern Web Interfaces with Dreamweaver CC
Developing Modern Web Interfaces with Dreamweaver CC
 
Introduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJsIntroduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJs
 
WebDU Keynote
WebDU KeynoteWebDU Keynote
WebDU Keynote
 

En vedette

En vedette (8)

The high resolution web
The high resolution webThe high resolution web
The high resolution web
 
NFC Power
NFC PowerNFC Power
NFC Power
 
Mobilapp på 30 minuter
Mobilapp på 30 minuterMobilapp på 30 minuter
Mobilapp på 30 minuter
 
Pioneers Festival 2014
Pioneers Festival 2014Pioneers Festival 2014
Pioneers Festival 2014
 
Från Flash till Canvas - en förkärlek till svarta hål
Från Flash till Canvas - en förkärlek till svarta hålFrån Flash till Canvas - en förkärlek till svarta hål
Från Flash till Canvas - en förkärlek till svarta hål
 
Successful OTC Branding for a demanding consumer audience in 2012
Successful OTC Branding for a demanding consumer audience in 2012Successful OTC Branding for a demanding consumer audience in 2012
Successful OTC Branding for a demanding consumer audience in 2012
 
Firebase
FirebaseFirebase
Firebase
 
The Upgraded Human
 The Upgraded Human The Upgraded Human
The Upgraded Human
 

Similaire à From Flash to Canvas - a penchant for black holes

WordCamp Thessaloniki2011 The NextWeb
WordCamp Thessaloniki2011 The NextWebWordCamp Thessaloniki2011 The NextWeb
WordCamp Thessaloniki2011 The NextWeb
George Kanellopoulos
 
HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1
James Pearce
 
An Intro to Mobile HTML5
An Intro to Mobile HTML5An Intro to Mobile HTML5
An Intro to Mobile HTML5
James Pearce
 
WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)
Shumpei Shiraishi
 
Dive Into HTML5
Dive Into HTML5Dive Into HTML5
Dive Into HTML5
Doris Chen
 
Easy charting with
Easy charting withEasy charting with
Easy charting with
Major Ye
 

Similaire à From Flash to Canvas - a penchant for black holes (20)

HTML5 Technical Executive Summary
HTML5 Technical Executive SummaryHTML5 Technical Executive Summary
HTML5 Technical Executive Summary
 
Dive into HTML5: SVG and Canvas
Dive into HTML5: SVG and CanvasDive into HTML5: SVG and Canvas
Dive into HTML5: SVG and Canvas
 
WordCamp Thessaloniki2011 The NextWeb
WordCamp Thessaloniki2011 The NextWebWordCamp Thessaloniki2011 The NextWeb
WordCamp Thessaloniki2011 The NextWeb
 
Word camp nextweb
Word camp nextwebWord camp nextweb
Word camp nextweb
 
Word camp nextweb
Word camp nextwebWord camp nextweb
Word camp nextweb
 
Adobe Flash Professional with CreateJS
Adobe Flash Professional with CreateJSAdobe Flash Professional with CreateJS
Adobe Flash Professional with CreateJS
 
HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1HTML5 and the dawn of rich mobile web applications pt 1
HTML5 and the dawn of rich mobile web applications pt 1
 
An introduction to html5 by Devs
An introduction to html5 by DevsAn introduction to html5 by Devs
An introduction to html5 by Devs
 
Rich Media Advertising with SVG and JavaScript
Rich Media Advertising with SVG and JavaScriptRich Media Advertising with SVG and JavaScript
Rich Media Advertising with SVG and JavaScript
 
Practical html5
Practical html5Practical html5
Practical html5
 
Echo HTML5
Echo HTML5Echo HTML5
Echo HTML5
 
An Intro to Mobile HTML5
An Intro to Mobile HTML5An Intro to Mobile HTML5
An Intro to Mobile HTML5
 
WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)
 
Flex For Java Architects Ledroff Breizh Jug V Blog Cc
Flex For Java Architects Ledroff Breizh Jug V Blog CcFlex For Java Architects Ledroff Breizh Jug V Blog Cc
Flex For Java Architects Ledroff Breizh Jug V Blog Cc
 
Dive Into HTML5
Dive Into HTML5Dive Into HTML5
Dive Into HTML5
 
HTML5 Intoduction for Web Developers
HTML5 Intoduction for Web DevelopersHTML5 Intoduction for Web Developers
HTML5 Intoduction for Web Developers
 
A Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 RevolutionA Snapshot of the Mobile HTML5 Revolution
A Snapshot of the Mobile HTML5 Revolution
 
Spsmi13 charts
Spsmi13 chartsSpsmi13 charts
Spsmi13 charts
 
Smart phone development
Smart phone developmentSmart phone development
Smart phone development
 
Easy charting with
Easy charting withEasy charting with
Easy charting with
 

Dernier

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Dernier (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 

From Flash to Canvas - a penchant for black holes

  • 1. From Flash to Canvas a penchant for black holes @flashpatric
  • 2. THIS PRESENTATION Canvas 2D context History Today How a display list will make your life easier Tools for a better Canvas experience Demo
  • 3. WHAT’S CANVAS?! <canvas id=”canvas”></canvas> A part of the HTML5 standard Dynamic bitmap API’s for drawing and using text
  • 4. ADVANTAGES From a Flash developers point of view Low learning curve Powerful along with other new functions Very good performance in new browsers Semantics Offline & Storage Image manipulation down to pixel level Device access Lots of proven JS-libraries Connectivity Pretty high market penetration Audio & video 3D graphics & effects 3D context – WebGL Performance & Integration GPU acceleration CSS3
  • 5. HISTORY Flash vs HTML FutureSplash 1995 HTML 3.2 draft, Internet Explorer Macromedia 1996 I Learned HTML 1998 HTML 4.01 draft My first Flash applikation, Actionscript 1 2000 Actionscript 2 2003 Firefox 2004 WHATWG Adobe 2005 Actionscript 3 2006 2007 HTMLWG, death of XHTML Adobe AIR 2008 Google Chrome Mobile Flash Player, Scepticism 2009 HTML5 Adobe AIR for Android & iOS 2010 IE9 Adobe AIR for iOS, Mobile Flash Player 2011 Shifting focus, comunication fail
  • 6. TODAY HTML5 Canvas 2D market penetration Canvas basic support Text API for Canvas 71.17% 70.56% Opera Mini has partial support for Canvas Opera Mini is missing support for Text API CSS Canvas Drawing Full Screen API 35.56% (Chrome, Safari, iOS Safari, Android 0% browser) Partial support in Firefox, Chrome och Safari
  • 7. TODAY Canvas 2D Context in Internet Explorer IE8 and below is missing support for Canvas <!DOCTYPE html> <html> Polyfills can be used for VML in IE7 and IE8 <head> <meta charset="utf-8"> Explorercanvas.js <title>Dive Into HTML5 Canvas</title> <!--[if lt IE 9]> Everything is not supported, there’s limitations! <script src="excanvas.js"></script> - Only linear gradients <![endif]--> - Patterns must repeat in both directions </head> - Clipping paths is not supported <body> ... </body> - Non-uniform scaling does not scale outlines correctly </html> - Really bad performance
  • 8. DISADVANTAGES From a Flash developers point of view Polyfills is needed for older browsers There is no editor for Canvas yet No timeline or API for animations Drawn objects is only pixels Bad text rendering No display list/scene graph
  • 9. THE OPTIMIST But there’s hope for Canvas Polyfills cover some needs Adobe Flash Professional CS6 We’re programmers! Dynamic pixels Web fonts Logic display list
  • 10. WHAT A DISPLAY LIST IS ”A hierarchic list with graphical objects described with its properties”
  • 11. WHAT A DISPLAY LIST IS Display Object Different objects and properties Family based – parents and children Stage x&y Inherits from an abstract class Bitmap alpha Renders in relation to its parent Shape scaleX & scaleY Its properties determines the rendering Text Etc..
  • 13. CREATEJS A suite of Javascript libraries & tools for building rich, interactive experiences with HTML5
  • 14. EASELJS Based on the Flash display list Display list and display list objects DOM-elements Mouse events on objects, even onClick and onPress Touch support
  • 15. TWEENJS A Javascript library for tweening and animating HTML5 and Javascript properties
  • 16. SOUNDJS A Javascript library that provides a simple API, and powerful features to make working with audio a breeze
  • 17. PRELOADJS A Javascript library that lets you manage and co-ordinate the loading of assets
  • 18. ZOË A stand alone tool for exporting SWF animations as EaselJS sprite sheets that can be used in Canvas and CSS
  • 19. DEMO!
  • 20. Adobe Flash Professional CS6 Toolkit for CreateJS Nested animations Sounds Dynamic texts Vector objects Armature Shape morphs
  • 21. DEMO!
  • 22. Founder of CREATEJS Grant Skinner gskinner.com Recognized speaker, leader and innovator within interactive media Gtween RegExr CreateJS EaselGL
  • 23. THANKS! Patric Jonsson Interactive Developer @flashpatric flashpatric@gmail.com