Author Topic: rotation of a not vector image (png) with a high quality  (Read 1683 times)

M77

  • Member
  • **
  • Posts: 10
  • Karma: +0/-0
    • View Profile
    • M77's BLOG
can somebody please provide source code that just rotates png image?
also i need the quality of the image highest
(not clear and separate pixels of many 2d Flash games)
i hope u understand what i mean by high quality
most Flash games for speed performance reasons can change the quality of image by changing amount of points to calculate a color of a single screen pixel
i use FlashDevelop so it wont satisfy me to complete what i'm asking for with Macromedia tools

i would be very glad if i'll finally get how to do this

photonstorm

  • Administrator
  • Key Contributor
  • *****
  • Posts: 1502
  • Karma: +1/-0
    • View Profile
    • Photon Storm
For the absolute highest quality of image rotation you have to draw it rotated yourself. Every frame.

If you want Flixel to try to make a rotated smooth version then use an FlxSprite and loadRotatedGraphic, and give it a good high number of frames (64 minimum really). But it'll never look as good as a hand-drawn rotation sequence.
http://www.photonstorm.com



"Tell me and I will forget, show me and I might remember, involve me and I will understand" - Confucius

M77

  • Member
  • **
  • Posts: 10
  • Karma: +0/-0
    • View Profile
    • M77's BLOG
i need real time rotation with almost unlimited frame count

photonstorm

  • Administrator
  • Key Contributor
  • *****
  • Posts: 1502
  • Karma: +1/-0
    • View Profile
    • Photon Storm
There's no such thing as "unlimited" frame count. 360 is the maximum, there aren't any more angles than this!

The more frames you have, the more memory you use.
http://www.photonstorm.com



"Tell me and I will forget, show me and I might remember, involve me and I will understand" - Confucius

felipe

  • Member
  • **
  • Posts: 36
  • Karma: +0/-0
  • games!
    • View Profile
    • i love pixel
I don't know if this helps, but what i do to rotate not pixelated images and avoid getting pixelated is setting antialiasing = true.