interviews.dotnetthread.com

↑ Grab this Headline Animator

Monday, December 1, 2008

Differences between Silverlight and Flash/Flex


Silverlight

Flash
Silverlight Limitations:

Now, we got moonlight for Linux user 

This limitation doesn’t exist with Flash.
Silverlight will (naturally) be using the WMV and Silverlight will add to the use of the WMV file format. Using the WMV video format essentially makes Silverlight useless for the vast majority of video websites such as YouTube. It cannot play .avi and .mov file.Flash Video turned Flash into a mechanism for delivering media with far more potential than any other solution that is .flv, no doubt Flash has also limitation to play other video file. For that Flash required codex for that player installed on Client machine.

Now, we are able to read the data from web services (including RESTful service), XML from URL. Silverlight 2 supports Socket communication too. 

Even flash is also lacking this area. Flash can read data source in terms of XML or text from some URL and can use it. Same thing silverlight also can read.

The standard controls are included in Silverlight 2 beta1. 

Flash has rich set of control library.

Once the accessibility features are provided with Silverlight versions, any existing test tools that support driving UI through Accessibility will be fully enabled to automate Silverlight applications

Edit: I'm not sure about this but I don't think that we can't automate the UI. I think Windows Hooking will do. 

Flash test tools are already in place.
Silverlight 1.0 does not support GIF-file format. Even it doesn’t support BMP and other file format. It supports only JPG and PNG file format.Support all image formats.
Can’t do sound processing.With some media file sound processing can possible.

Silverlight 2 supports Socket communication too. 

Flash allows creating XML Socket object.
Per pixel bitmap editing, bitmap filters (convolution, color matrix, etc), bitmap effects (drop shadow, blur, glow) cannot be done.Can do that.
Webcam and Microphone support it not there.

Flash supports it.

Built in file upload/download support is not available.Inbuilt Upload/download support is there.
The performance of Silverlight and Flash will be nearly the same. While Silverlight is using XAML as description language in a non-compressed format size of Silverlight component is large.In practical implementation of similar component in Flash and Silverlight it has found that size of Silverlight component is approximately 10-20 times larger than Flash component.Size of flash component is smaller.

We got .xap now. but there are a number of people who like to get XAML with managed code. (SL 1.1 Alpha style)

Flash ships in single component that is .swf. Images/video/sounds also incorporated in single .swf package.
It has found in practical implementation of image animation, at some extent flickering occurs on image.To avoid this type of flickering in flash, refresh layout or cache bitmap functionalities are available.
It has found in practical implementation of video play, audio may start playing before showing movie on screen. It has also found video can still continue to play after redirecting to other page. It may be it is bug of current beta release.Flash doesn’t face these types of issues.

XPF or XBAP is already there for that.  

Flash can be played as Windows application also by downloading player for it. Flash can be also packaged as .exe which can be deploying standalone.
Silverlight is new in market and required time to get acceptance in market.Flash is exist from many years and have strong acceptance in market.
Silverlight Feature comparison with Flash Features:
Animation - Silverlight supports the WPF animation model, which is not only time based instead of frame based, but lets you define the start and end conditions and it will figure out how to get there for you. No need to deal with matrixes like in flash. Also no need to calculate positions on various frames. It just works. The animation model is frame based.
Silverlight uses XAML. XAML is text based and can be output using a simple XML object.Flash stores its shapes using binary shape records. In order to write shape definitions, you will need to either license a 3rd party Flash file format SDK, or build your own. It isn’t too difficult, but it does require a bit of a learning curve.
The debugging with Silverlight is simpler than with flash.The debugging with flash is harder than Silverlight.

Silverlight lets you embed true type font information directly into your projects, and download that information with the webclient object.    

downloader is no longer available but we have webclient.

Dealing with fonts is fairly complex with flash.

Rich set of development languages are available for Silverlight. Developer can use JavaScript as well as managed code VB.Net, C# for Silverlight development.

Edit: The dynamic languages (IronPython, IronRuby, and Managed JScript)  are supported too.

Only Action Script can be used as programming tool in Flash.
XAML is declarative while ActionScript is imperative. Using imperative languages to build UIs goes back to the early days of DOS and Windows, when developers had to manage all of the API nuances when interacting with graphical panes.ActionScript is an imperative language, which brings itself the pitfalls of imperative languages when compared with declarative languages.
Web Services support for Silverlight Streaming:The services provided by Microsoft, called Silverlight Streaming, it allows users and developers to host their Silverlight content and apps with Microsoft, taking advantage of their extensive global network of datacenters and their content delivery network. Best of all, this service is free, and while currently it is only in alpha it allows users to upload up to 4GB of content, and to stream up to 1 million minutes of online video delivery at 700kbps, around DVD quality. Starting right now, you can build a total video content site using Silverlight at no cost. The future for this service looks good as they will incorporate Silverlight Streaming with the MSN Video ad network to allow you to easily monetize your video streams and participate in a revenue sharing opportunity with Microsoft while removing your distribution costs. There will also be a premium level of content delivery where you will be able to pay for higher levels of usage - the cost for this service is as yet unknown but expect it to be very low.There is not any such service provided by Flash to host the content and application with them. Because of the absence of any such service, building a video site based on Flash is not as cost effective as building a video content site using Silverlight. Moreover, because of the Silverlight Streaming service, the existing Video Content sites might be moving to Silverlight site.
Additional Support for mobile devices with desktop and desktop browsers:Silverlight is supported by Windows mobile device as part of a new service that the NBL have built. Silverlight applications and media streaming can be run on a mobile phone - so Silverlight even at this stage is about more than just the desktop browser and desktop market.  Silverlight may be seen soon on the Symbian OS too.Flash is not spread as across the vast majority of both desktops and mobiles platforms, as compared to Silverlight. Flash requires Flash Lite preinstalled on mobile devices.
Silverlight does not require video codec to run industry standard videos like .WMVFlash requires video codec to run .WMV videos.
Silverlight supports scalable video formats from HD to mobile.Flash does not support scalable video formats from HD to mobile
Silverlight supports Hardware-assisted editing and encoding solutions.Flash does not support Hardware-assisted editing and encoding solutions.

Edit: Now, we lost it. AFAIK, We have to use  *.xap if we want to use managed code. .xap is just a zip but not plain text anyway.

Flash does not have XAML based presentation layer for SEO. 
Silverlight provides End-to-end server and application platform.Flash does not provide End-to-end server and application platform.
Media server licensing is cheaper than flash.Media server licensing is costlier than Silverlight.
Silverlight supports Scalable full screen video.Flash does not support Scalable full screen video.


Forum discussion http://silverlight.net/forums/t/3015.aspx

Submit this story to DotNetKicks

No comments:

Post a Comment

Post your comments/questions/feedback for this Article.

 

Latest Articles