Try to distill in the plainest non marketing terms what this means: Adobe is now your new rev share partner congrats! they get paid 9% if you get success by doing what?...umm...

What just happened:

If you want to create console quality experiences in flash, Adobe has created a new tollbooth/firewall inside the WEB Flash player (possibly projector too) that if BOTH  stage3d AND alchemy are used will trigger this new license, and you will have to pay for it.  This is a way of segmenting the use of 'conventional' flash from what exists today to the 'console quality' level access that is possible when both are used.

NOTE: If you are targetting AIR, this does not affect you (yet).  My guess as odds are you are already paying Apple, Android marketplace and can't afford another 9% mouth to feed.

NOTE: if you are not using hardware acceleration Stage3d, it does not affect you.

To review:

Hardware accelerated Stage3d is primarily used just for complex 3d game graphics, though some are using Starling to do fast 2d rendering, again most likely with goals of console quality game engines.

Alchemy is primary used for C/C++ code ported to run inside actionscript, common use: physics, image compression, and mp3 compression.  All these things are possible but potentially impractical without the 10x-100x Alchemy speed boost.

The Breakdown

The Breakdown Premium Features vs Free

Stage3d + Alchemy
No +  No => no impact, same game as most flash games today
Yes + No => no impact, fancy 3d games, just sluggish physics/media processing.
No + Yes => no impact, 2d games, can do jpg/png/mp3 compression.
Yes + Yes => console level quality, subject to licensing restrictions

Starting with Flash Player 11.2, developers will see a notification watermark in the debug version of Flash Player  if their content uses both of these APIs, informing them that they will need to obtain a license.

They say that they believe very few if any apps out there will be affected by this and are offering exemptions for a bit. So get em now if you need em.

The player is now becoming a DRM license engine, a private network running on the normal web like Valve's Steam.  They are planning other premium features to fit into this, like instant startup, local cache (probably), bookmarking levels etc.  Basically the more your desktop/laptop and browser do what your xbox/Ps3 do the more it fits into the premium category Adobe wants a piece of for making possible, without any risk on their part in actually creating your content, marketing etc.

If you don't pay, right now they only say that rendering will fall back to software based Stage3D. But how and when...being overly dramatic, I assume your code will have a thumbprint (necessary for caching and version..flex's big libs already does this) and ultimately if your bills/papers aren't in order with Adobe, potentially your content may suddenly stop working on the web. Which is kinda scary if you've ever had Google/Apple take down your app/website before, except this happens ON YOUR SITE and ON YOUR/YOUR USERS DESKTOP, and you are footed with the customer support calls when your game suddenly turns to molasses.

From the important to read FAQ

Net revenue is calculated as revenue after taxes, payment processing fees, and social network platform fees are subtracted. Revenues subject to the revenue share include application sales, in-app purchases, subscription fees, sponsorship, and advertising fees received for advertising in, or related to the application.

Meaning after you pay facebook, they want 9% of ALL money you get pre your production costs.  HOW exactly they can find this out is beyond me, most companies have a hard enough time tracking this, and things like Ads end up.  I believe this is calculated as net LIFETIME revenue as well.


From Unity 3d's announcement

We see this as Flash positioning itself alongside other well known distribution channels: make money through the App Store, Apple takes a share. Make money through the Android Market place, Google takes a share. Make money through Flash, Adobe takes a share.

I agree. Adobe has lost control of the tool chain by opening up the flex compiler, and giving that away, and the decreasing need/feature set for the Flash IDE with bigger games being built in other more game friendly tooling front ends,  and are attempting to follow Apple/Google into a subscription app + content tollbooth company instead of a desktop tool company.

Some other links worth reading.


Flash multiple file uploading has a few different ways to be ..a pain in the butt.

ISSUE1: DIY MultiPart Uploader

If you need to do client side processing (resize, thumbnail etc) you have to use a custom MultiPart uploader, which for reasons I don't fully understand has to be hacked in AS3. The consequences of this are typically:

1) you have to do encoding prior to allowing upload, largely as it's impossible to encode and upload in a single click.  Due to security restrictions around how many uploads are possible per one user click, basically

2)you have to bundle more than one file typically at a time, which can make the upload large.  Due to security restrictions around how many uploads are possible per one user click.

3) this mechanism due to flash limitations does not report upload progress only complete, meaning you're fancy graphical uploader is rather worthless and users are going to see a bunch of nothing and then bam everything is done. Which if 2 is true means it will look broken..not good.

4) who knows how well this works in flash when dealing with large files, not fond of the idea of shuttling byteArrays of great magnitude, especially on a mobile device.

The later 2 are deal breakers for me, but at present there isn't any other work around so you kinda have to live with it, unless you want to do server side resizing which has it's own issues.  Though I do find it's better if the image doesn't need resizing to just use the Native Uploader, no point in reencoding images losing quality if it's not needed.

ISSUE2: Native Uploader,
This is simple to code, providers upload progress, small files work fine, but get into larger (e.g. 20MB) files like video, some threshold is crossed and the uploader behaves differently. Grr.

First in my case it did not upload params included with the URLRequest regardless of what I tried, this first was due to needing to up these beefier php.ini settings:

max_execution_time = 1000
max_input_time = 1000
memory_limit = 128M

Which basically give PHP more time, as working with large files things take more time than webpages.

Next it would strip out the custom params like where to upload the file files would get uploaded to the default instead of desired folder. To workaround this I maintained some variables in Session.

Things at this point worked fine locally using xamp, but not in production for a really odd reason separate sessions between the normal URLLoader.load and the FileReference.upload being created! To work around this I started using cookies to store stuff, which still didn't work reliably.

After a day beating my head against this, figured out that the contentType needs to be explicitly set (even to the defaults) as it appears to be overwritten when a file large enough to trigger AND POST needs to be explicitly set in the method.

Like this:
params = new Object();
params["topath"] = _topath;
params["setPath"] = _topath;

urlReq.method = URLRequestMethod.POST;
urlReq.requestHeaders.push(new URLRequestHeader('Cache-Control', 'no-cache'));
urlReq.contentType = "application/x-www-form-urlencoded"; = params;
someFileRef.addEventListener(DataEvent.UPLOAD_COMPLETE_DATA, onRAWuploadComplete);

After that it worked locally, and in production  yay :)

Some others that had similar issues (that didn't help me) URLLoader using POST fails to send variables URLVariables problem

A Hybrid Solution.

So to solve the bigger problem supporting user client side resizing/rotating uploads and big file uploads with progress is use both approaches. After file selection the UI disabled uploads until all images are resized (only if necessary).  Upon upload click the master loop determines what  type of uploader to use, first writing all the converted image to a single composite ByteArray one at a time, then sends all of them in one request up.  As well each FileReference goes one at a time.  All of these are in one master loop triggered by the user clicking on an upload to make flash 10 security happy.

Mobile Tweaks

Once I got all this working locally with XAMP, then on Amazon EC2, I hit a odd snag using Android.

The evil was currFile.type apparently is not implemented on Android, so you have to fall back to string processing on the file name, to route based on the media type and filesize.

var currFile : FileReference = _fileRef.fileList[k];
trace2("loader for " + + " size: " + currFile.size + " type:" + currFile.type);
var ext:String =".")[1]; //use this instead, file extensions are null on android?!

Nicely the Flash10 image resizer performs reasonably on my EVO4g phone which was not what I was expecting.


Flash and Flex optimizing swf size via -link-report

October 22, 2011

I have been trying to find a way to figure out what scripts are taking up the most space, and came across this which links to a neat air utility with a treemap + datagrid to help visualize what’s taking up space. So for example you publish your file with the new setting in bold, […]

Read the full article →

Flash AS3 detect undesired line break in TextField wordWrap is true.

June 9, 2011

Flash inserts silent line breaks when you tell it wordWrap = true. Visually it’s easy to see the break, but this new line is not reflected in either the htmlText or text, so how do you find it? Turns out you have to iterate over both the string and the textfield looking for where they […]

Read the full article →

Multidimensional Arrays and Vectors Optimized with VectorEx

May 29, 2011

My Brilliant friend Alex has released a small library to help optimize creation and access of multi-dimensional Vectors much easier. Instead of endless nested Array commands initialize like var vector:VectorEx=new VectorEx(int,5,3,4); To speed access, and reduce re-lookups, it caches pointers so vector.getElementAt(0,1,2) and vector.setElementAt(55,0,1,2); are much faster than vector[0][1][2]; Check it here

Read the full article →

TLF Clone copy a TextFlow

May 25, 2011

Say you have two  TLF textFields on stage ( and you want to copy the content from one to the other. You have to jump though a few hoops. In this example stlf_txt is the source.  tlf2_txt is the destination. PROBLEM: tlf2_txt.textFlow= stlf_txt.textFlow.deepCopy() as TextFlow; does not work in my experience, for reasons I don’t […]

Read the full article →

AWS Service Outtage…Outrage…Grow up people!

April 24, 2011

Amazon’s Web services over the last couple days had an unprecedented outtage, that caused many sites (including almost all my sites on the cloud) to go down. Understandably many people are pretty upset at Amazon,  when really they should be upset at themselves. The cardinal rule of the cloud …and ANY mission critical application for […]

Read the full article →

AIR 2.0 CS5 +NativeProcess + Ubuntu Linux Rant

October 29, 2010

Like many I was excited to hear that AIR 2.0 offered command line integration, in fact it opens up some cool opportunities for some of our applications that run on the cloud. But wow compared to the ease of compiling a swf and Mac and Windows Projectors…building AIR is somewhere between a gauntlet or a […]

Read the full article →

Fuzzy Logic in Actionscript 3.0, a new open source library

September 3, 2010

Alex just released a library on fuzzy logic with actionscript, if you are doing game development this is a fun subject.

Read the full article →

ReferenceError: Error #1065: Variable addFrameScript is not defined. SOLUTION

May 3, 2010

THE ISSUE: Ah lovely “ReferenceError: Error #1065: Variable addFrameScript is not defined.” can you be more vaque? THE FIX: in whatever the piece of code in the stack trace, inside the Fla, navigate internal to the frame, and remove any script OR comment on the timeline. WHY:Somewhere in the initialization the script on the timeline […]

Read the full article →