Results 1 to 7 of 7

Thread: PNG Smoothing

  1. #1

    PNG Smoothing

    Hey there, simply im thinking of replacing all the Vector graphics in a game with PNG versions for optimal performance, now as my game involves lots of rotation with trig etc i enabled smoothing on the image properties which cancels out the pixelation that you get when rotating bitmaps. But it seems to good to be true, is there a catch? Smoothing is as bad as Vector images or somthing !! PLz enlighten me!

  2. #2
    Are you storing the smoothed png's or smoothing them every frame you render?

  3. #3
    Rendering every frame, as the rotations are too precise for storing them!

  4. Quote Originally Posted by Krabex View Post
    Rendering every frame, as the rotations are too precise for storing them!
    Well, that's not gonna be much faster..

  5. #5
    As far as rotation is involved, storing them is pretty, I keep them in an array with a length of 36. Rotations appear pretty smooth too.

    Anyway, why are .png's 'optimal' over vector? I recently switched from vectors to .png and when dealing with small images (like 7x7) vectors are definatly better. They both just become bitmaps in the end right?
    Last edited by substance; April 15th, 2008 at 03:34 PM.

  6. #6
    This deals with how they are rendered. Bitmap requires setting all the pixels in a region. Vector have a method that fills areas. A 7x7 filled image should render slower. Remember that flash has special instructions for vector so filling 49 pixels might be faster for it to compute than what it does for the 7x7 bitmap.

    Run a benchmark and post it online, people like to know about these things and see tests.

  7. #7
    Quote Originally Posted by Sirisian View Post
    This deals with how they are rendered. Bitmap requires setting all the pixels in a region. Vector have a method that fills areas. A 7x7 filled image should render slower. Remember that flash has special instructions for vector so filling 49 pixels might be faster for it to compute than what it does for the 7x7 bitmap.

    Run a benchmark and post it online, people like to know about these things and see tests.
    Are you reffering to how flash '.draw''s the bitmap?

    I would assume that once the bitmap is drawn into a bitmapdata object it is treated the same whether the source bitmap was vector or .png since it's just pixel data at that point. Anyway, I'm probably not the best person to run a benchmark as I'm still pretty new to as3 =X.

    **btw, when I said vectors are "better" than .png's with smaller images I just ment visually. Obviously if you save a 7x7 image out as a .png there is going to be noticeable pixelation. I guess this could be remedied by saving it out at a larger resoloution then scaling down at run-time.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012