25 August 2011

Flash Player Released

Glory Be!

All the issues from the catastrophic release of Flash Player appear to have been fixed.


Still counting the cost of the previous update - well into the thousands of dollars. On the bright side, the hypertension it gave me didn't cause a heart attack!

16 August 2011

Flash Player AS1 Shared Library Bug

I came across a critical bug in Flash Player, a security update that was released on Thursday 11th August 2011.

Basically, if you use shared libraries from circa Flash 6 / AS1 with a 2 frame preloader that uses either nextFrame() and/or gotoAndPlay(1), the whole containing swf movie will unload itself and you're left with a blank screen.

Here's the detail:

Google Chrome users get Flash updated immediately and automatically and were the first to call tech support. The legacy games would load and then... nothing! Calls from IE and FF users soon followed. As we have lots and lots of swfs for old games still in use, a mild wave of panic started to fill the office.

Luckily the fix is simple, it's just a case of altering the preloader by removing the offending nextFrame() or gotoAndPlay(1). We ended up removing the preloader entirely as the 40k file size of the shared library is tiny by today's standards. Unfortunately for us, we had to do this on 400+ fla's, test them and release them as a hotfix to our clients.

Another cracking update from Adobe! In the UK, this is known as "dropping a bollock!"

24 February 2011

Particle Code

Particle Code, unlike its name suggests, is a new cross platform SDK for mobile devices. I first became interested in it when I discovered Actionscript was one of the supported languages.

The basic idea behind Particle Code is to write once and deploy eveywhere and the language you chose to write your code is up to you. The code will then be compiled to native code and packaged as apps for:
  • iOS
  • Android
  • BlackBerry
  • Windows Phone 7
  • J2ME
  • Symbian
Compiling to native code is an important difference between Adobe's paradigm: AIR apps deployed to mobile devices that require the AIR runtime installed in order to work.

This looks like a great idea and has the potential to save hundreds of hours porting an app between devices. However, even though Actionscript is supported, it is a completely separate platform to Flash/Flex, you will not be able to write a Flash Platform application with Particle Code.

Looking at the Particle Code API, it looks fairly similar to the way you would develop apps in Android, you can use Java or Actionscript to create your apps, though I suspect more will be added to that list.

From a Flash Platform developer perspective, there are lots of things missing, MovieClips, Sprites etc. plus you won't be able to do any E4X. You will undoubtedly need to write more code to get anywhere close to the animation capabilities of Flash, but the amount of platforms you can deploy to, may justify that extra effort.

09 February 2011

Flash Player 10.2 now available

Following my previous rant about some issues in FP10.1, you'll be pleased to know they're still there in 10.2. Obviously this fix is waiting for the 11.0 release.

Still, it's good to see that the CPU usage for video is vastly improved with Stage Video. However, this comes at a price as it bypasses the usual software rendering pipeline and passes the stream straight to the hardware. Therefore you can only rotate in 90ยบ increments and you can't skew, transform or convert to bitmaps. This is a pure video acceleration feature, which is good news as it saves battery time and will hopefully cause Apple to reconsider its increasingly irrational position regarding the FlashPlayer on iOS.

Although I wouldn't put much faith in that - Mac users beware - this is a known issue:
"On some Macintosh systems with NVidia 9400, GT 320, or GT 330 GPUs, live video streams render all black with hardware acceleration, or all white when using the software decoder."

Other new features include full-screen support for multiple monitors, hardware rendering support for IE9, custom native mouse cursors (use responsibly people!) and sub-pixel text rendering. That's great news if you're Chinese - you may actually be able to read something in 12pt. text!

This looks like a good "point" update, plus the 64-bit "square" version is now out of beta too. Time will tell if I have to go through my API's and fix a load of things as I did for FP10.1, but so far it looks impressive.

FlashPlayer 10.2 Download

FlashPlayer 10.2 Release Notes

02 February 2011

Google vs Bing - my tuppence worth.

As you probably know already, Google is accusing Microsoft of copying its search results on the Bing search engine. you can read a detailed account of the complaint here:
Google: Bing is Cheating, Copying Our Search Results

If you don't want to read all that, it basically says that Microsoft was using IE8 to capture the result of what people were searching for on Google, then copying that result, which would eventually appear on Bing. Google discovered this by adding "synthetic searches", searches made of random strings such as "mbzrxpgjys", added by Google engineers, that would only return results on Google itself. Strange, then, that they started to appear on Bing a few weeks after the Google engineers started searching for those terms using IE8 with the Bing Toolbar and the Suggested Sites feature switched on.

Is what Microsoft doing illegal? It's certainly cheeky, yet many sites use Google's search, albeit branded with a Google logo. I think the key to this is IE8.

The article above examines the T's and C's of IE8 and the Suggested Sites feature, which has 2 key points:
  • "addresses of websites you visit are sent to Microsoft, together with standard computer information."
  • "Information associated with the web address, such as search terms or data you entered in forms might be included."
By accepting these terms, you are in effect allowing IE8 to act as spyware, to monitor your web activity. It may well be used to improve your search results on Bing, but it also has the ability to glean information from Google search.

Personally I think passing off the Suggested Sites feature as something other than what it is - spyware - is dodgy in the first place, but the T's and C's probably do give adequate warning. Obviously information gathered by Suggested Sites is used to improve the search results for Bing, which is fair enough, but was the ulterior motive to scrape results from Google?

Aggregating results from search engines is common practice and can be quite useful, but if Microsoft want to use Google results in Bing, then it's only fair play to add the "powered by Google" logo next to them. If they're too precious to do that, then they should stop using Google's results, or at least pay Google to use their results without have to acknowledge the source.

At the end of the day, web searches are based on copying, storing and ranking information from all over the web, it's the forming of relevance and context which is the trick, something that Google nailed in the late 90's. As Isaac Newton admitted to "standing on the shoulders of giants" in order to create the Theory of Gravitation, Bing should be equally gracious if they are to use Google as a part of a utopian search service, vastly superior than its competitors. Bing certainly isn't that.

Cheats never prosper, unless you're Microsoft, which has arguably spent the last 30 odd years copying other peoples ideas. I'd like to think it's time for Google to give them a good hiding, but I doubt this will go any further than exposing Microsoft's practices to the public. If this did go to court, Google may have to openly explain how its precious algorithms work.

Google had concrete proof of this issue on December 31st, but waited until February 1st to release its findings - why? Because that was the date of the Farsight 2011 search engine conference, perfect timing to undermine everything Microsoft was to eulogise about Bing. Google seems to want to fight this battle with hearts and minds rather than through the courts (to date at least). Blog posts like this are popping up all over the web and if it only serves to steer your average computer user away from Internet Explorer, that can only be a good thing!

20 January 2011

HTML5 or HTML? Fallen at the First.

I found recent developments from W3C and WHATWG rather humorous, as they don't seem to have agreed on the name for
HTML ... erm ... version 5.

W3C recently pushed out a load of marketing tat for HTML5 which includes a snazzy superhero-laundry-detergent logo and the geekiest t-shirts known to man.

"You have HTML5 on the brain. Tell the world!" is the message from W3C.

Shame nobody spoke to WHATWG, who are also working with W3C (supposedly) on the specification:

"HTML is the new HTML5" they declare on their blog. They suggest renaming HTML5 back to plain old HTML and dropping the version number. "Time to move on!", they say. What will W3C do with all those t-shirts!?

The sad truth is, the organisations that are creating the HTML(5) specification can't even agree on the name, which seems like a case of falling at the first hurdle and doesn't inspire confidence in future developments!


12 January 2011

IntelliJ 10: A Real Alternative to Flash Builder

Have you ever had a large project in Flash Builder and you need to refactor a whole chunk of code into a new namespace and also have it move the files in SVN?

Have you tried to run an ANT build and got an "OutOfMemory error:PermGen Space" error and needed to up the memory to 1GB or over?

Has your machine been bogged down by massive memory/processor usage?

Much as I like Flash Builder, with its UI features and its ability to publish Flash projects, it has one major flaw: it's built on Eclipse.

Refactoring code and updating SVN in Flash Builder with Subclipse is possible but it can take a few minutes, plus it does have a tendency to go wrong and the whole SVN project can get addled, causing much grief.  Doing the same refactoring job in IntelliJ can take seconds and it will also update all your package declarations to match the new namespace. I can link to and run my ANT or Maven builds in a much more pleasing way, and it never seems to run out of memory, and all the while during coding, refactoring or building I'm using < 200MB of memory.

With IntelliJ you can debug swfs running in the FlashPlayer, unit test and refactor with ease. The downside is you don't get the memory profiler, the ability to publish Flash projects, or Flash Builder design view (I'm sure most proficient Flex developers hardly use it anyway).

I've been using IntelliJ 9 for 6 months now (I was previously using FDT), and IntelliJ 10 has added extra support for Actionscript, Flex and AIR. If you develop large scale Flash, Flex or AIR projects, IntelliJ saves time and frustration and is also a great editor for many other languages too.

Here's the Flex features: IntelliJ 10 Flex Features

I still use Flash Builder at home for my own projects. At home I tend to follow Adobe's recommended workflows between Flash Platform applications which all works reasonably well. So it's horses for courses, but for my job which deals with many large Actionscript heavy frameworks, IntelliJ is much more pleasant to use than FDT, FlashDevelop or Flash Builder.