Rotating a picture

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Tom Gur

    #1

    Rotating a picture

    Hi,

    I'm trying to build a small spaceship battle game as an exercise,
    using pygame.
    How can I rotate the gif file of my ship by X degrees ?

  • Marc 'BlackJack' Rintsch

    #2
    Re: Rotating a picture

    In <1182238895.646 197.270090@k79g 2000hse.googleg roups.com>, Tom Gur wrote:
    I'm trying to build a small spaceship battle game as an exercise,
    using pygame.
    How can I rotate the gif file of my ship by X degrees ?
    You shouldn't do this with the PyGame functions, the quality is poor.
    Either use a paint program to pre-generate rotated images or the python
    imaging library (PIL) to create them in the game.

    Either way you should use an RGB format instead of a format with a
    palette to have better anti aliasing, and always rotate from the original
    image as each rotation introduces some loss of quality and detail.

    Ciao,
    Marc 'BlackJack' Rintsch

    Comment

    Working...