Long image's angle transformation render time?


(Nirvan) #1

Hi all.

I’ve made little spermatzoids with flexible tails, but for this effect I created array of images. When there is big number of images to rotate render time is big. They are very small files ( 13x4 ) and if there will be about 12 spermatzoids on screen fps will go down :109: There is example ( player have sett 200 parts of tail ) http://shadowsgames.net/tests/SpermInvaders2.swf


(Justin Wolf) #2

Have you tried using a PreRotation for each of the graphics instead of an Image? Should cut down on a lot of FPS issues as the rotation graphics get cached. This is just assuming you already aren’t using PreRotation.


(Nirvan) #3

Wow thanks for help! But I have to load images in different way than Image class? Because I have error when I loading by preRotation: “Error #1069: Property bitmapData not found on GC_H0 and there is no default value.” Also other small question, is there possibility to work with vector graphics in flashpunk?


(Justin Wolf) #4

Could you post the code where you’re loading the images?

PreRotation extends the Image class so other than a few class name changes and parameter changes on the initialization of the image, it should work.


(Zachary Lewis) #5

It is possible to forgo the bitmap-based rendering of FlashPunk and use vector-based rendering. It would be a good idea to create a new topic in help using the “Reply as new topic” button next to your post and ask the vector question by itself, so we can focus this topic on the main question you had. :strawberry:


(Nirvan) #6

Thanks Zach, I will post new topic for it. For main question: I loading images as octet streams to keep small size of compressed png files, then I encode it and it works good with Image class, so I don’t know why It not working with preRotation. When I not loading images as octet streams there is no error but nothing is rendering :O.


(Nirvan) #7

Exists way to fast transform Spritemaps like preRotation? :smiley: