by bartczernicki.nospam@nospam.gmail.com (Bart Czernicki) via Silverlight Hack on 2/8/2010 10:31:00 AM
Note: I know this topic is controversial, so I want to preface that this article is meant to be a conversation. If you don't agree with something or I have information incorrect, please add a comment or e-mail me. As the HTML 5 spec evolves, I will update this article.
HTML 5 is the next update to the HTML standard that powers the web. There are many new exciting features being added like the the canvas element, local offline storage, drag and drop and video playback support. HTML needed to evolve and added these features in order to stay relevant as the de facto markup language that can provide a rich web experience.
This upcoming featureset is encroaching on areas dominated by RIA (Rich Internet Application or Rich Interactive Application) frameworks like Flash, Silverlight and JavaFX. Unlike most RIA frameworks, HTML is not a proprietary language/framework and its standards are maintained by the World Wide Web Consortium (W3C). This has led speculation that HTML plus the new RIA-like features can spell doom to proprietary RIA frameworks. This article aims to cover what is in HTML 5 (as of February 2010) and how some features in the spec are lacking compared to RIA like Silverlight. This is not a complete overview of HTML 5, nor is it a "HTML 5 vs. Silverlight" article. Below is a quick list of items that I will be covering to try to prove my assertion that HTML 5 is not ready to replace RIAs like Silverlight:
There are some really nice demos appearing of certain HTML 5 features (HTML 5 capable browser required like Safari, Chrome or Firefox 3.x). As you can see, HTML 5 is very capable in creating RIA-like experiences:
A very large majority of current "HTML 5 demos" center around three key features: the new canvas, audio, and video tags. The HTML 5 spec is MUCH larger than this. For example, look at how many differences there are between HTML 4 and HTML 5. However, many people (including technologists and developers) see one or two demos called "cool HTML 5 demo" and clamor on Twitter that RIA frameworks are gone. If you dig down deeper, only a small fraction of the HTML 5 spec is implemented in some of the browsers. Furthermore, the HTML 5 spec is still evolving (You will see some examples below of changes that have occured in the last few weeks). Some have speculated it might take three to five years to implement the "full" HTML 5 spec once it is finalized. Will it take that long? I think companies like Google and Apple who have a very strong vested interest in moving HTML 5/WebKit along are going to push this faster. However, the HTML 5 spec has to be finalized FIRST (to see the full scope of the implementation) before we can speculate on how long the undertaking will be.
One of the biggest additions to the HTML 5 spec is the audio and video element tags which allows you to embed media files directly into the HTML markup. This allows you to use these media files very similar to the way you would use the the img tag for example. Providing the location of the resource is all that is required (Additional attributes allow you to create the behavior of the media elements such as streaming). This is a simple and standard way to enhance your HTML with media files.
HTML 5 video tag markup from W3 Schools
I think HTML takes the right step with the audio and video tag additions. However, providing a great multimedia experience is more than just playing a video file or a music mp3. Here are some limitations of the audio/video elements and how it compares to Silverlight:
HD Silverlight video with a 3D transformation and pixel shaders applied in real-time (from Mix 2009 conference)
Note: Silverlight is not the only technology that offers smooth streaming. Apple's Quicktime Streaming and Adobe's Flash Media Server are two examples of technologies that offer streaming and DVR-like capabilities. It is worth noting that Silverlight Smooth Streaming is a FREE value-add to Windows Server 2008 IIS 7.x.
The HTML 5 spec is partially supported by the latest versions of Safari, Chrome and Firefox. Internet Explorer from Microsoft is the key browser missing HTML 5 support. The fact remains that Internet Explorer is still one of the most widely used browsers in the world. Designing a site without Internet Explorer in mind would probably not be a great idea. Isn't evil Micro$oft simply blocking innovation? I don't think so. Internet Explorer 9 is rumored to have HTML 5 support. Furthermore, Microsoft would further degrade the use of Internet Explorer if they simply decided to skip the HTML 5 standard. No matter what your open-source/Linux fanboy tells you, that won't happen.
Let's say the next version of Internet Explorer comes out and it supports HTML 5 tomorrow! As an architect/CTO, are you going to design a new web site in HTML 5 with over 66% of the web running Internet Explorer 6-8? There are so many web connected devices out there that simply will not support HTML 5 for a long time. Remember web connected devices include mobile phones as well. Furthermore, many casual users (like your parents) may not upgrade their browser for the entire lifetime of the "family computer". Furthermore, the HTML 5 specification is pretty big and different browsers support various features. You can see from this Wikipedia article that no current browser supports the current HTML 5 spec (because it is still evolving).
Internet Explorer is losing its dominance. However, even a 10% drop would be equivalant to hundrends of millions of users stopping use of Internet Explorer. I don't see a 20% drop until two to three years from now. You can check out the web browser trends for yourself: http://statowl.com/web_browser_market_share.php
Note: Providing fallback markup is a valid option; however, this leaves yet another architecture/code path to put through QA. That works great for sites that are template-based (like YouTube). However, creating a large scale business app with fallback markup has a large cost associated with it.
If you have done any sort of web development, you have probably used Javascript to provide dynamic content on the client browser. The same applies for manipulating HTML 5 content. So what is the problem?
In this article, I define productivity as a set of architecture and design tools, add-on frameworks, and developer tools that makes me more efficient in crafting and maitaining an application. HTML, CSS and Javascript suffer from a wide variety of productivity problems. Have you used a web tool that does everything for you on a complex project?
The Silverlight framework handles the productivity issues in a cohesive set of tools that include design tools, developer tools, and a rich .NET foundation.
I could add a lot more to this topic. However, my experience on working on Silverlight has been "night and day" in terms of productivity. Projects I have worked on allowed developers/designers to seemlessly create complex controls and extend existing ones and create very unique product designs. The combination of Silverlight frameworks/tools and what you gain from .NET makes it a pleasure to work with compared to HTML/Javascript/CSS. The tools that accompany the HTML 5 spec have to truly go through a revolutionary transformation in order to keep up with the design experience provided by Silverlight and Flash.
HTML 5 is a markup language for the web. You essentially need a web browser to interpret HTML content. Silverlight allows you to write once and deploy to desktop, web and now Windows Phone 7/Symbian/Android. Additional features like multi-touch features allow you to take advantage of next-generation hardware natively, without having to rely on the browser.
Note: I realize that technology like Mozilla's Prism allows for "installing" HTML/Javascript sites locally on the desktop. But that technology is not very popular and I haven't met anyone that uses it widely commercially,
The current HTML 5 spec does not have support to offload rendering to the GPU. There are plans to support it in the future with WebGL technology using the HTML 5 canvas. WebGL should provide 3D, hardware-acceleration, and pixel shaders to HTML/Javascript. Silverlight (as of Version 3) already supports 3D projections, hardware-acceleration, and Pixel Shader 2.0. Furthermore, the GPU acceleration is not limited to just one layout control (canvas in HTML5). There are also many physics and 3D engines out there for Silverlight.
The screen shot below is from a chapter in my book that shows a piece of XAML layout that was GPU accelerated. As you can see, GPU acceleration does free up noticable CPU resources.
One of the ugly parts of the WebGL implementation is that you are still using Javascript to provide dynamic content to the 3D Canvas. I can imagine this being passable for simple 3D demos, but it won't work for complex interactive 3D scenes. Doing complex 2D/3D vector math or matrix computations in Javascript isn't going to perform well. For example, some military simulations for the HUD of a cockpit use a Flash UI for training. Rendering these complex visuals and providing real-time event-driven calculations is important.
Broad WebGL support is probably a ways off as the spec is still changing. The future Firefox 3.7 release will suport WebGL/3D Canvas. Other browers like Chrome and Safari will get support as well via the WebKit compatibility. I would estimate we should see decent WebGL support for Chrome, Firefox and Safari in one to two years. The reason why I think it is still a year (or two) away is because there are major revisions yet to be implemented and tested. Furthermore, WebGL is an extension of the HTML 5 canvas. Therefore, it would make sense that once the canvas tag has matured, WebGL will probably have some upcoming changes.
Providing device support integrated into the browser is a huge deal for social, collaboration, and media applications. Web cam and microphone device support is becoming a big deal for mobile applications as well. The HTML 5 spec does not support these devices. There is a plan to add device support in post HTML 5 (5.01 or 5.1, etc.) Conversely, Silverlight 4 supports both of these devices.
Augmented Reality Applications (shown below), web conference/chat (chatroulette.com), or real-time photo manipulation (and more) applications can all be done with Silverlight 4 device support. (As the HTML 5 spec stands now, these types of applications cannot be done natively with HTML/Javascript).
Rene Schulte's great example of Silverlight 4 augmented reality
A large majority of the HTML 5 spec is being pioneered by the Google and Apple engineers; not that this is a bad thing. However, note that both Google and Apple do not have RIA or popular graphics frameworks. They have to do something and have a very vested interest in HTML 5 coming out ASAP. Rather than creating their own RIA-type frameworks, they are trying to evolve the HTML 5 spec to compete with the rich RIA web experiences. Here are a couple of interesting points to think about:
This is the last point, however the most important. After reading all of the "new" HTML features like: video tag, audio tag, canvas, Web Workers, WebGL, future device tag support etc. you should have realized that HTML 5 is JUST CATCHING up to Silverlight. Furthermore, the HTML 5 spec is not close to being implemented. Lets assume that the full HTML 5 spec is implemented in 2 years (assuming a very aggressive schedule)...where will Silverlight be by then? Silverlight is on about a 9 month release cycle. Therefore, by the time HTML 5 is "implemented"...Silverlight will be on version 6 or 7of the platform. HTML will have to play catch up....again.
Original Post: Top Reasons why HTML 5 is not ready to replace Silverlight
The content of the postings is owned by the respective author. Silverlight Feeds is not responsible for the contents of the postings. This site is automatically generated and cannot be reviewed for abusive content. If you find abusive content on Silverlight Feeds, please contact us. Designated trademarks and brands are the property of their respective owners. All rights reserved.