Results 1 to 7 of 7

Thread: Tutorial - Anti-Alias Pixels

Threaded View

  1. #2

    Thread Starter
    Frenzied Member cyborg's Avatar
    Join Date
    May 2000
    Location
    Sweden
    Posts
    1,755
    Some theory:

    Here are some illustrations that shows the pixel we want to draw.
    The grid shows the pixels that the monitor has, also our boundary - We can't draw
    between those pixels.



    Lest say we want to draw a red pixel on X position 2.6 and Y position 2.8 - Right between
    two monitor pixels. Without AA the pixels position would be rounded off and it would
    be painted on X 3 and Y 3 and we can't do anything about that, that's why we simulate
    that the pixel is drawn inbetween. We do this by drawing 4 pixels (because our pixel
    touches 4 of the monitors pixels) with different colors depending on how much our pixel
    touches the surrounding pixels.

    As you can see in the illustration, our pixel only touches the (2,2) pixel a little bit,
    so we draw the (2,2) pixel just a little bit read.
    The illustration also shows that our pixel touches the (3,3) pixel very much, so we will
    draw that one almost red.
    We do like this for all the pixels we touch. (In this case there are 4 pixels, but sometimes
    there are only 2 pixels ore maybe even just 1)
    Attached Images Attached Images  
    Check out the FAQ and do a search before you post.
    My tutorials: Anti-Alias Pixels, Accurate Game Loop, Resource File

Posting Permissions

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



Click Here to Expand Forum to Full Width