Results 1 to 10 of 26

Thread: I need some help with 2D drawing libraries

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #12
    PGD Staff / News Reporter phibermon's Avatar
    Join Date
    Sep 2009
    Location
    England
    Posts
    524
    I got it from the OpenGL red-book... And I quote :

    "An optimum compromise that allows all primitives to be specified at integer positions, while still ensuring predictable rasterization, is to translate x and y by 0.375, as shown in the following code fragment. Such a translation keeps polygon and pixel image edges safely away from the centers of pixels, while moving line vertices close enough to the pixel centers."

    But if you want to add 0.5, on the CPU, to both components of every coordinate you send, to the GPU, be my guest

    I'm no longer using immediate mode, will post if I find any problems getting unfiltered, pixel aligned fonts working under GL3 Core. (I may go down the vector font route if I can't figure out an elegant way to render bitmap fonts using shaders)
    Last edited by phibermon; 18-10-2010 at 09:36 PM.
    When the moon hits your eye like a big pizza pie - that's an extinction level impact event.

Tags for this Thread

Bookmarks

Posting Permissions

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