Situation: I'm trying to replace Flash Socket communication (byte-range) with javascript, to avoid the flash socket security policy file restrictions.
Details: I have binary data from javascript, and I can pass it to flash by base64 encoding/decoding, but this is too slow. Saving to disk and passing the local url is not an option (and not just for speed, but also clients prefer everything in memory, and the swf file may be restricted from loading local files). Furthermore, not using base64 doesn't work, as flash's ExternalInterface uses XML (which isn't designed to carry binary data) to pass the data to AS3.
Question: Is there any way to get binary data from JS to AS3 without writing to disk and not bae64 encoding?
I am aware of Action Message Format (AMF) but it seems to add way to many external dependencies, and may still be slow?
Note: My program needs to be as browser compatible as possible, and it's downloaded by clients (so needs to be small) and it also needs to run as fast as possible...
thanks!