I am working with a Shape and I have just noticed a small problem:
when I use graphics.clear method graphics is not completely wiped out.
I have a green rectangle: if I clear graphics and then redraw the same rectangle, but red, I will see a very thin green border around the red rectangle!
The only solution for now is to remove the Shape, set it to null and create a new one.
Could you write a small test we could use to try and reproduce this? I have not seen an issue like this
I think it was because of cacheAsBitmap, but I still haven’t had the time for a test: cacheAsBitmap is nasty for sure, as it prevents the correct updates of the item, i.e. if I apply an Actuate.transform to change colour it is not visible, while in AS3 you can see everything (even if updating the cached BMP at each change is heavier on CPU and memory).
Maybe the clear-and-redraw approach of Shapes works “correctly”, drawing the new pixels on the old ones but leaving something of the old ones on the borders.
How does the update of the cached bitmap work? Is the BMP recreated from scratch at each update or just on the sub-children areas? If the BMP is updated on the changing areas only then they would need a small bleeding to prevent the problem.
Hmm, setting colorTransform should set an object’s render as dirty, which should invalidate the cached bitmap
Uhm, it sounds like you’re telling me the bmp is regenerated completely, right? Ok, as soon as I have the time I will do some testing. Well, maybe I can do a simple one tomorrow, the one with the Actuate.transform on mouseOver.