Author Topic: blurred text upon resize?  (Read 1067 times)

Offline Minigame

  • int
  • **
  • Posts: 55
    • View Profile
blurred text upon resize?
« on: January 13, 2013, 02:26:31 am »


Whenever I resize the client application, it seems that text blurs.

Here's the bit of code I am using for this feature:
Code: [Select]
// Handle resizing
if (Display.wasResized()) {
buffer.resize(Display.getWidth(), Display.getHeight());
buffer.refresh();
app.getSettings().setWidth(Display.getWidth());
app.getSettings().setHeight(Display.getHeight());
mouseYOffset = buffer.getOutputHeight();
}

To draw the text Strings I am using an implementation of raft's GLFont class, so I figured maybe somebody here has used it and could tell me if  I am doing something wrong?

Updated:
Sometimes when I resize the application I get these random lines? I didn't notice this when I originally posted, but it is relevant to the original post so I shared it on this thread as well..
« Last Edit: January 13, 2013, 05:48:34 am by corey »

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 11746
    • View Profile
    • http://www.jpct.net
Re: blurred text upon resize?
« Reply #1 on: January 13, 2013, 01:06:59 pm »
This happened for odd widths/heights only. It was a problem with the way resize() was calculating the framebuffer's center. It should be fixed in this jar: jpct.de/download/beta/jpct.jar

Offline Minigame

  • int
  • **
  • Posts: 55
    • View Profile
Re: blurred text upon resize?
« Reply #2 on: January 13, 2013, 07:19:52 pm »
This happened for odd widths/heights only. It was a problem with the way resize() was calculating the framebuffer's center. It should be fixed in this jar: jpct.de/download/beta/jpct.jar

Excellent, it seems to be fine. Thank you very much Egon