kazster
03-06-2007, 11:17 AM
I posted this on the flash lite forums at Adobe, but it's probably a good idea to post it here aswell:
I've noticed some pretty serious problems when when working with Flash Lite 2.1 on on a device, on a device simulator, and on the Flash 8 emulator. There were no Object watches or any other kind of behind-the-scenes mayhem when I found these bugs. Here's just a small list of issues that have gone wrong (among other things):
1. The Number data type is flaky at best. When doing a trace() on a variable of type Number, the value will change from signed to unsigned depending on what was done with the variable even if the actual contents haven't changed. For example I tried doing a bitwise OR on a Number that had 0xFFFFFFFF in it, and the interpretation switched from unsigned to signed.
2. It seems that when I do an add 0 to a _y member of one of my MovieClips the contents of my movie EXPAND AND SKEW to extreme extents. I don't even know how this is possible, because nowhere in my application do I modify _width/_height, or any scale property values of ANY MovieClip objects (only read them).
3. When testing my app on a device (LG VX8000), Flash Lite began IGNORING certain core language operations (adding / creating an empty movie clip / etc..) RANDOMLY if I start mashing keys fast enough (happens sometimes even if I don't mash keys).... operations which work 100% of the time in the Flash 8 device emulator both with a low and high FPS rate.
4. When retrieving _y and _height properties of a MovieClip, in certain places these properties were INTERCHANGED WITH EACH OTHER if I didn't add trace() calls to print their values before hand. Taking out the trace() calls caused the values to continue being swapped.
These are pretty serious issues that are making my app unstable all around. My application is entirely based on the basics of ActionScript 2.0. I can assure people reading this that the problems are not because of bugs within my application. Has anyone come across any of these problems before? Can anyone at Adobe provide information or workarounds/support.
It's a shame to see such huge bugs in the Flash Lite VM.
I don't really know what the NSTL/QUALCOMM requirements are for allowing extensions. How something like this has passed any kind of QA process is beyond me.
Here's an ActionScript demo that shows one of the most serious bugs (Bug number 3). Contrary to my prior belief, you don't even need to be mashing keys for the VM to start ignoring operations, on almost every iteration there'll be something wrong with the output on the screen (random missing blocks/ignored lineTo's) as opposed to having a screen with a full colour palette. This bug ONLY appear when testing on an actual device (in this case the LG VX9800), and doesn't happen at all on the Flash 8 emulator.
function drawSquares(mc:MovieClip) {
if (mc.innerClip != null)
removeMovieClip(mc.innerClip);
var innerClip:MovieClip = mc.createEmptyMovieClip("innerClip", mc.getNextHighestDepth());
var systemX:Number = System.capabilities.screenResolutionX;
var systemY:Number = System.capabilities.screenResolutionY;
var totalXBlocks:Number = 0xF;
var totalYBlocks:Number = 0xF;
var blockWidth = Math.floor(systemX / totalXBlocks);
var blockHeight = Math.floor(systemY / totalYBlocks);
for (var x:Number = 0; x < totalXBlocks; x++) {
for (var y:Number = 0; y < totalYBlocks; y++) {
var newClip:MovieClip = innerClip.createEmptyMovieClip(x + "x" + y, innerClip.getNextHighestDepth());
var color:Number = (y << 12) + (x << 4) + y;
newClip.beginFill(color);
newClip.moveTo(0, 0);
newClip.lineTo(blockWidth, 0);
newClip.lineTo(blockWidth, blockHeight);
newClip.lineTo(0, blockHeight);
newClip.lineTo(0, 0);
newClip.endFill();
newClip._x = x * blockWidth;
newClip._y = y * blockHeight;
}
}
}
setInterval(drawSquares, 1, this);
These bugs seem like they're pretty serious. I haven't gotten an answer from anyone at Adobe. I think it's almost as if though they have a "don't ask don't tell" policy when it comes to issues with Flash Lite.
I've noticed some pretty serious problems when when working with Flash Lite 2.1 on on a device, on a device simulator, and on the Flash 8 emulator. There were no Object watches or any other kind of behind-the-scenes mayhem when I found these bugs. Here's just a small list of issues that have gone wrong (among other things):
1. The Number data type is flaky at best. When doing a trace() on a variable of type Number, the value will change from signed to unsigned depending on what was done with the variable even if the actual contents haven't changed. For example I tried doing a bitwise OR on a Number that had 0xFFFFFFFF in it, and the interpretation switched from unsigned to signed.
2. It seems that when I do an add 0 to a _y member of one of my MovieClips the contents of my movie EXPAND AND SKEW to extreme extents. I don't even know how this is possible, because nowhere in my application do I modify _width/_height, or any scale property values of ANY MovieClip objects (only read them).
3. When testing my app on a device (LG VX8000), Flash Lite began IGNORING certain core language operations (adding / creating an empty movie clip / etc..) RANDOMLY if I start mashing keys fast enough (happens sometimes even if I don't mash keys).... operations which work 100% of the time in the Flash 8 device emulator both with a low and high FPS rate.
4. When retrieving _y and _height properties of a MovieClip, in certain places these properties were INTERCHANGED WITH EACH OTHER if I didn't add trace() calls to print their values before hand. Taking out the trace() calls caused the values to continue being swapped.
These are pretty serious issues that are making my app unstable all around. My application is entirely based on the basics of ActionScript 2.0. I can assure people reading this that the problems are not because of bugs within my application. Has anyone come across any of these problems before? Can anyone at Adobe provide information or workarounds/support.
It's a shame to see such huge bugs in the Flash Lite VM.
I don't really know what the NSTL/QUALCOMM requirements are for allowing extensions. How something like this has passed any kind of QA process is beyond me.
Here's an ActionScript demo that shows one of the most serious bugs (Bug number 3). Contrary to my prior belief, you don't even need to be mashing keys for the VM to start ignoring operations, on almost every iteration there'll be something wrong with the output on the screen (random missing blocks/ignored lineTo's) as opposed to having a screen with a full colour palette. This bug ONLY appear when testing on an actual device (in this case the LG VX9800), and doesn't happen at all on the Flash 8 emulator.
function drawSquares(mc:MovieClip) {
if (mc.innerClip != null)
removeMovieClip(mc.innerClip);
var innerClip:MovieClip = mc.createEmptyMovieClip("innerClip", mc.getNextHighestDepth());
var systemX:Number = System.capabilities.screenResolutionX;
var systemY:Number = System.capabilities.screenResolutionY;
var totalXBlocks:Number = 0xF;
var totalYBlocks:Number = 0xF;
var blockWidth = Math.floor(systemX / totalXBlocks);
var blockHeight = Math.floor(systemY / totalYBlocks);
for (var x:Number = 0; x < totalXBlocks; x++) {
for (var y:Number = 0; y < totalYBlocks; y++) {
var newClip:MovieClip = innerClip.createEmptyMovieClip(x + "x" + y, innerClip.getNextHighestDepth());
var color:Number = (y << 12) + (x << 4) + y;
newClip.beginFill(color);
newClip.moveTo(0, 0);
newClip.lineTo(blockWidth, 0);
newClip.lineTo(blockWidth, blockHeight);
newClip.lineTo(0, blockHeight);
newClip.lineTo(0, 0);
newClip.endFill();
newClip._x = x * blockWidth;
newClip._y = y * blockHeight;
}
}
}
setInterval(drawSquares, 1, this);
These bugs seem like they're pretty serious. I haven't gotten an answer from anyone at Adobe. I think it's almost as if though they have a "don't ask don't tell" policy when it comes to issues with Flash Lite.