Archive

Archive for May, 2010

HTML vs. Flash: Can a turf war be avoided?

from http://news.cnet.com/8301-30685_3-20000037-264.html

A difference of opinion among developers has become a high-profile debate over the future of the Web: should programmers continue using Adobe Systems’ Flash or embrace newer Web technology instead?

The debate has gone on for years, but last week’s debut of Apple’s iPad–which like the iPhone doesn’t support Flash–turned up the heat. Before that, Adobe had been saying with some restraint that it’s happy to bring Flash to the iPhone when Apple gives the go-ahead.

But Chief Technology Officer Kevin Lynch took the gloves off Tuesday with a blog post that said Apple’s reluctance to include Flash on its "magical device" means iPad buyers will effectively see a crippled Web. And he played the Google Nexus One card, too.

"We are now on the verge of delivering Flash Player 10.1 for smartphones with all but one of the top manufacturers," Lynch said, specifically mentioning the Nexus One as one such device and adding that the software also works on tablets, Netbooks, and Net-enabled TVs. "Flash in the browser provides a competitive advantage to these devices because it will enable their customers to browse the whole Web…We are ready to enable Flash in the browser on these devices if and when Apple chooses to allow that for its users, but to date we have not had the required cooperation from Apple to make this happen."

Adobe CTO Kevin Lynch

Adobe CTO Kevin Lynch

(Credit: Stephen Shankland/CNET)

Flash has indeed spread to near-ubiquity on computers, with better than 98 percent penetration, according to Adobe’s statistics. Its roots lay with graphical animations, but its success was cemented by providing an easy streaming video mechanism to a Web that had been plagued with obstreperous and incompatible technology from Microsoft, Apple, and Real.

But a collection of new technologies–including a rejuvenated HTML (Hypertext Markup Language) standard used to write Web pages–are aiming to reproduce some of what Flash offers.

Bruce Lawson, Web standards evangelist for browser maker Opera Software, believes HTML and the other technologies inevitably will replace Flash and already collectively are "very close" to reproducing today’s Flash abilities.

"The Web (including video, games, animation) is too vital a platform for business, communication, and society to be in the hands of any single vendor," Lawson said. "But it’ll be a while; there is a huge body of existing content that uses Flash."

It’s not just a matter of the installed base of Flash on the Web, though. Although HTML5 and its associated technologies are maturing rapidly, and because they evolve concurrently with browser support, they’re arriving and relevant now even though incomplete. But many developers are likely to sit on the sidelines until things settle down in 2010 and perhaps beyond.

Open Web allies
After years of HTML standardization disarray, browser makers Apple, Opera, Mozilla, and most recently Google now are hammering out new directions for Web standards.

Perhaps the most visible HTML5 aspect is built-in support for audio and video, but there are other HTML abilities under way: storing data on a computer for use by an application, Web Sockets for periodically pushing updates to a browser, Web Workers for letting Web programs perform multiple tasks at once, and Canvas for better two-dimensional graphics.

At the same time, these allies marching under the "Open Web" banner also are creating new standards such as WebGL for accelerated 3D graphics on the Web, enabling better typography through CSS (Cascading Style Sheets) and Web fonts, beefing up support for others including SVG (Scalable Vector Graphics), and improving the power of JavaScript for writing Web-based programs.

Even Microsoft, despite sitting out much of the last decade’s browser development activity and having a Flash rival called Silverlight to promote, is getting involved. It pledges interest in Web standards and in recent months engaged in HTML and SVG development. "The positive response has been overwhelming," said Patrick Dengler, a senior program manager on the IE team, in a blog post Monday about SVG Microsoft’s SVG involvement.

In addition to some philosophical opposition to Adobe’s proprietary Flash software, there’s a practical complaint, too: crashes. It’s a major reason Mozilla is rushing out a new "Lorentz" version of Firefox that isolates plug-ins into a separate computing process so problems don’t bring down the whole browser.

Here’s one new example in action: a browser application that lets people drag an image onto the browser, which stores it locally on the computer, enables various editing abilities, resizes it to a small size, and uploads it to TwitPic using Twitter login credentials. And some more: a Star Wars imperial walker animated in CSS, Windows 3.1 reconstructed in JavaScript, and a first-person gifter game using Canvas.

But there are real-world sites, too, that forsake Flash. For example, the iPhone Google Voice application runs in the browser.

Flash advantages
It’s far from game-over for Flash, though.

The Open Web work is chaotic, fluid, and scattered, and browser support for its various elements is inconsistent when it exists at all. Flash is a single browser plug-in that provides consistency from one computer to the next. And unlike with browsers, where Microsoft’s 2001-era Internet Explorer 6 has only recently been dethroned as the most-used browser, most people upgrade to new Flash versions relatively rapidly.

Formal standardization proceeds slowly. HTML5 editor and Google employee Ian Hickson opened the last call for HTML5 comments in October for WHATWG (Web Hypertext Application Technology Working Group), which has been working on HTML5 for years. But that group works jointly with the more straight-laced W3C (World Wide Web Consortium) to come up with the standard.

So today, if you’re publishing The New York Times’ graphical tour of the federal budget proposal, Flash is the obvious choice.

The difficulties of HTML5 video is a good illustration of difficulty of matching Flash. Flash video can use a variety of "codecs" for encoding an decoding video as it’s sent from server to viewer. Viewers don’t need to know anything beyond how to click a video’s "play" button, a contrast to Net video’s incompatibility-fraught early days.

But with HTML5, though, there are two prevailing codecs right now: H.264, supported by Apple’s Safari and Google’s Chrome, and Ogg Theora, supported by Firefox, Chrome, and, according to plan, Opera. IE, the dominant browser, doesn’t support any at HTML5 video at present.

What’s a video streamer to do? If a Web site supports HTML5 video at all–YouTube just started experimenting with it–it’s safest to include Flash as a fallback for the vast number of people whose browsers today can’t use HTML5 yet.

Another thing: the Open Web allies may be close to reproducing what Flash has today–but not necessarily what it’s getting tomorrow. Adobe’s Lynch last year pledged to advance Flash, keeping it "a leading agent in terms of exploring what’s possible in the Web."

Finally, programming tools aren’t as mature for the hodgepodge of Open Web tools.

One reason for that immaturity is that HTML5 and related technologies aren’t finalized yet, Lawson said. Another: "You’re relying on browsers interoperating–which historically has never been the cleverest bet, although as the specs become final there’s a better chance," he said.

Cooler heads
HTML vs. Flash has the potential to become a religious war. As long as there have been programming languages, there have been arguments about which tool is the best for getting the job done, and this issue has some extra elements that add some emotion to the mix.

There are plenty of Firefox-using open-source fans who chafe at proprietary plug-ins, and they’re accustomed to making their opinions heard. Another group enjoys bashing Flash as a conduit for in-your-face online advertising. Add a little Apple iPad love-hate invective into the mix, and you’ve got great potential for Flash bashing.

"People want a certain ‘killer’ narrative: Good guys vs. bad guys, open vs. proprietary, blah blah," said John Nack, Adobe’s Photoshop principal product manager but also a defender of Flash in his spare time.

Indeed, it’s probably wiser to take a deep breath and accept that both technologies will prevail and neither will conquer the other any time soon.

Perhaps the gulf isn’t as wide as it appears. Don’t forget that Adobe has HTML authoring tools as well, and its AIR (Adobe Integrated Runtime) software foundation includes not just a Flash player, but also the WebKit HTML-handling engine that’s also in Safari and Chrome. Adobe has a big investment in Flash, but count on its HTML interest increasing as that technology matures.

In the big picture, Adobe sees a place for both but not a day when the Web can dispense with Flash.

"Longer term, some point to HTML as eventually supplanting the need for Flash, particularly with the more recent developments coming in HTML with version 5," Lynch said. "I don’t see this as one replacing the other, certainly not today nor even in the foreseeable future."

Categories: Flash News

Does HTML5 Really Beat Flash? The Surprising Results of New Tests

From http://www.readwriteweb.com/archives/does_html5_really_beat_flash_surprising_results_of_new_tests.php

With the impending launch of the Apple iPad, the Cupertino-based company’s shunning of Adobe Flash technology has been brought to the forefront of technological discussions. While it was one thing to forgo Flash on a small, mobile device such as the iPhone or iPod Touch, some are questioning whether lack of Flash support is going to be a make-it-or-break it feature for the new slate devices arriving next month – devices which, if you believe Apple CEO Steve Jobs – are "better than netbooks."

On the flip side, Apple supporters echo the company’s sentiments that "Flash is a CPU hog" and including support for the technology in Apple’s mobile line-up would negatively impact battery life.

However, recent tests have put Flash up against HTML5, the new web markup language that eliminates the need for the Adobe plugin. The results of these tests show that this is not a simple black-and-white issue. Is Flash really a CPU hog? Yes, in some cases. But, surprisingly, not all the time. In fact, sometimes HTML5 actually performed worse.

Testing Flash and HTML5

Jan Ozer is an expert in video encoding technologies, has worked in digital video since 1990 and is the author of 13 books related to the subject [Editor’s Note: some people have pointed out that Ozer has done seminars and written books featuring Adobe products, so therefore he makes money from the success of Adobe Flash. We don’t think that has any effect on the test outcomes, but we thought it was worth updating the post to note it.] Recently, he put HTML5 up against Flash in a series of tests that pitted the two technologies against each other on both the Mac and PC and in different web browsers including Internet Explorer 8, Google Chrome, Apple Safari and Mozilla Firefox.

The results of the tests in their entirety are published here on StreamingLearningCenter.com. The summary in a nutshell? Flash isn’t always a CPU hog, sometimes that honor goes to HTML5.

Some of the highlights of Ozer’s findings are below, broken up into both Mac and Windows test results.

Mac Tests

  • With Safari, HTML5 was the most efficient and consumed less CPU than Flash using only 12.39% CPU. With Flash 10.0, CPU utilization was at 37.41% and with Flash 10.1, it dropped to 32.07%
  • With Google Chrome, Flash and HTML5 were both equally inefficient (both are around 50%)
  • With Firefox, Flash was only slightly less efficient than in Safari, but better than in Chrome

Windows Tests

  • Safari wouldn’t play HTML5 videos, so there was no way to test that. However, Flash 10.0 used 23.22% CPU but Flash 10.1 only used 7.43% CPU
  • Google Chrome was more efficient on Windows than Mac. Playback with Flash Player 10.0 was about 24% more efficient than HTML5, while Flash Player 10.1 was 58% more efficient than HTML5.
  • On Firefox, Flash 10.1 dropped CPU utilization to 6% from 22% in Flash 10.0
  • In IE8, Flash 10.0 used 22.41% CPU and Flash 10.1 used 14.62% CPU

Hardware Acceleration Key to Flash Performance

In analyzing the results of the tests, Ozer determined that the key to better Flash performance was dependent upon whether or not it could access hardware acceleration. This feature, launched in Flash 10.1, allows the plugin to use the graphics processing unit (GPU) on some computers to decode video. Depending on the video card and drivers, (NVIDIA, AMD/ATI and Intel offer products that support this), the video decoding process in Flash 10.1 can now work for all video playback, not just full-screen playback as was available in Flash 10.0.

According to Adobe, hardware acceleration is not supported under either Linux or Mac OS X, the latter because Mac OS X does not expose access to the required APIs. Adobe goes on to say "The Flash Player team will continue to evaluate adding hardware acceleration to Linux and Mac OS X in future releases."

Here’s what this all means in layman’s terms: Apple isn’t allowing Flash to become more efficient on their Mac OS X/Safari platform (or their iPod/iPhone/iPad one, either) by not providing the access to the hardware it needs to reduce its CPU load. Adobe is waiting and watching to see if they do, but, as Ozer says "the ball is in Apple’s court."

Will Apple budge? At this point, it’s unlikely. In blocking Flash on Apple devices, the company can easily claim that it’s simply not an efficient technology…and that’s true for now, considering how it’s set up. But if the company wanted to allow it and make it work, it seems reasonable to believe that they could. This is what leads some insiders to believe that the decision to block Flash is less of a technological one and more of a business-minded one. After all, if you could easily visit Hulu.com to stream TV shows and movies, then why would you need to buy them from the iTunes Store?

So while Flash’s "CPU hogging" may be a contributing factor in Apple’s decision to not support the technology on their mobile devices, that’s probably not the only reason behind the block.

Thank you to Dan Rayburn, who pointed us to Jan Ozer’s article.

Categories: Flash News

As3 Crypto

from http://code.google.com/p/as3crypto/

Tags: , ,

As3 Crypto is a cryptography library written in Actionscript 3 that provides several common algorithms. This version also introduces a TLS engine (TLS is commonly known as SSL.)

  • Protocols: TLS 1.0 support (partial)
  • Certificates: X.509 Certificate parsing and validation, built-in Root CAs.
  • Public Key Encryption: RSA (encrypt/decrypt, sign/verify)
  • Secret Key Encryption: AES, DES, 3DES, BlowFish, XTEA, RC4
  • Confidentiality Modes: ECB, CBC, CFB, CFB8, OFB, CTR
  • Hashing Algorithms: MD2, MD5, SHA-1, SHA-224, SHA-256
  • Paddings available: PKCS#5, PKCS#1 type 1 and 2
  • Other Useful Stuff: HMAC, Random, TLS-PRF, some ASN-1/DER parsing

The library is offered under the BSD license, and include several derivative works from Java, C and javascript sources. Check the LICENSE.txt file for a list of contributors.

You can look at a demo of the functionality of the library. It’s built with Flex 2. It includes a unit test tab, and a benchmark tab.

This is what the benchmark tab outputs on my computer (Athlon64 2Ghz):

The 'numbers' are in 1000s of bytes per second processed.type             16 bytes     64 bytes    256 bytes   1024 bytes   8192 bytes
md2                  1.01k        3.64k       15.08k       53.89k      171.76kmd5                221.85k      447.32k      739.54k      893.72k      905.82ksha1                82.28k      184.78k      286.76k      336.03k      345.41ksha224              60.84k      125.67k      200.27k      234.28k      247.58ksha256              60.52k      126.30k      199.19k      234.04k      246.01khmac-md5            48.37k      159.37k      282.87k      295.15k      341.21khmac-sha1           18.29k       64.82k      165.72k      277.60k      342.52khmac-sha224          5.75k       24.84k      125.71k      204.35k      256.36khmac-sha256         15.10k       49.33k      123.71k      206.17k      249.08krc4                117.24k      381.34k      878.93k     1315.01k     1539.44kxtea-cbc             2.49k        6.48k       12.80k       33.00k       44.48kaes128-cbc           1.61k        4.01k       22.97k       78.55k      205.01kaes192-cbc           1.34k        5.13k       20.91k       69.45k      172.43kaes256-cbc           1.48k        5.63k       18.87k       63.45k      150.39kblowfish-cbc         2.77k       10.81k       42.28k      140.27k      343.05kdes-cbc              2.53k        9.73k       35.20k      124.84k      624.88k3des-cbc             2.50k        9.72k       35.61k      115.21k      253.42k

The library has not been optimized for speed, and those numbers could probably be improved.

You can browse the source, download the source or download the SWC binary

Check out the release notes for a bit more details.

Things that should make it in the next release:

  • better ASN-1 parsing
  • SSL 3.0 support
  • various bugfixes (Socket, BigInteger)

http://code.google.com/p/as3crypto/downloads/detail?name=Crypto.zip

http://code.google.com/p/as3crypto/downloads/detail?name=as3crypto.swc

SVN Location

Categories: Actionscript 3

The AS3Commons project

from http://code.google.com/p/as3-commons/

Tags: , is dedicated to one principal goal: creating and maintaining reusable ActionScript 3.0 components. This is a place for collaboration and sharing, where developers from throughout the community can work together on projects to be shared.

AS3Commons developers will make an effort to ensure that their components have minimal dependencies on other libraries, so that these components can be deployed easily. In addition, AS3Commons components will keep their interfaces as stable as possible, so that users (including other AS3Commons projects) can implement these components without having to worry about changes in the future.

We welcome participation from all that are interested, at all skill levels. Coding, documentation and testing are all critical parts of the software development process. If you are interested in participating in any of these aspects, please join us!

AS3Commons Libraries

Collections Collection framework formerly know as Lite Collections Fx 1.0 download docs
Concurrency Pseudo-threading support 1.0-RC1 download
Lang Language utilites and extensions 0.2.1 download
Logging An abstraction over logging framework implementations. Being a pure actionscript library it can be used for any Flash/Flex/AIR project. Its use is recommended for use with other libraries/framework trying to be logging framework agnostic. 1.1.1 download docs API
Reflect A reflection API for ActionScript 3.0. Being a pure actionscript library it can be used for any Flash/Flex/AIR project. 1.3 download docs API

Maven

All libraries are also available in the Maven repository at http://projects.yoolab.org/maven/content/repositories/releases/org/as3commons

Categories: Actionscript 3

Facebook-actionscript-api

Tags: , ,

The new ActionScript 3.0 Client Library for Facebook Platform API, fully supported by Facebook and Adobe, makes it easy to build applications that combine the strengths of the Flash Platform and Facebook Platform.

The Adobe Flash Platform and Facebook Platform provide the ideal solution for building rich, social experiences on the web. Flash is available on more than 98% of Internet-connected PCs, so people can immediately access the applications, content, and video that enable social interactions. The Facebook Platform is used by millions of people everyday to connect and share with the people in their lives. Together, both platforms allow you to:

  • Share: Create rich interactions for users to share with friends.
  • Have fun: Make games social; let users compete against their friends.
  • Connect: Let users connect to your RIAs with Facebook Connect.
  • Solve problems: Build RIAs that harness the power of community.
  • Reach people: Reach millions of Facebook users through social distribution.

Getting Started

For tutorials, articles, and videos on using the new API, visit the Facebook page on the Adobe Developer Center. You can also see the docs for the most recent and stable build.

Project History

The API was originally developed by Jason Crist and authored under the direction of Terralever, an online marketing firm with strength in Flash-based media. Although Adobe has taken over day-to-day management of the project, Jason still maintains a consulting role. Under the direction of Adobe, the highly experienced team of Flash and Flex experts from gskinner.com have developed and architected the latest iteration of the API.

If you are looking for the deprecated code and samples, see the ‘tag/version2’ directory in the repository or search for files with the ‘Deprecated’ tag in the downloads section.

For questions and inquiries about this library, please contact Daniel Dura at Adobe Systems via email at ddura@adobe.com. Submit bug reports, patches, or feature requests via the issue tracker.

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_with_AIRConnect_v3.4_flex.swc

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_with_AIRConnect_v3.4_flash.swc

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_v3.4_source.zip

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_v3.4_flex.swc

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_v3.4_flash.swc

http://code.google.com/p/facebook-actionscript-api/downloads/detail?name=Facebook_library_v3.4_examples.zip

SVN Location

Combine PV3D & Webcam Motion Tracking

Categories: Showroom

GA for Flash

Categories: Actionscript 3