Image Loss on GUI elements
by Bryce "Cogburn" Weiner · in Torque Game Engine · 06/12/2007 (8:48 pm) · 3 replies
I'm experiencing some odd loss with GUI images and I'm wondering if anyone has any pointers since a website search turned up fruitless (except for one post that suggested that it was a flaky video card).

Top are the images loaded into Photoshop... BMP on the left, JPG on the right.
Below are the same two images in-game. BMP on the left, JPG on the right. The dimensions of the image are the same in-game as in Photoshop.
The problem is the artifacting.
I think there's an accuracy problem somewhere, but in tracing it down to dglDrawBitmapStretchSR I haven't found anything that jumps out at me.
I checked other GuiBitmap controls and they all behave in the same manner.
I've got a few other OpenGL games of the same version of TGE 1.5.2 (for testing purposes :) ) and none are exhibiting the same issue, so I'm going to rule out driver/OpenGL/video card as the culprit.
Any clues?
edit:image

Top are the images loaded into Photoshop... BMP on the left, JPG on the right.
Below are the same two images in-game. BMP on the left, JPG on the right. The dimensions of the image are the same in-game as in Photoshop.
The problem is the artifacting.
I think there's an accuracy problem somewhere, but in tracing it down to dglDrawBitmapStretchSR I haven't found anything that jumps out at me.
I checked other GuiBitmap controls and they all behave in the same manner.
I've got a few other OpenGL games of the same version of TGE 1.5.2 (for testing purposes :) ) and none are exhibiting the same issue, so I'm going to rule out driver/OpenGL/video card as the culprit.
Any clues?
edit:image
#2
first , i test my game on 2 platforms. one is a laptop with a Intel 915 Series video chip set and a wide screen display, the other is a desktop pc with a 17 inch display on a ATI Radeon X1300 Pro video card.
on the the desktop i do not get this with the my hud overlay png, but on the laptop i do. there are disortions/artifacting on some of the lines in the graphic that are not present on the desktop system.
What video card do you have tha thas this problem?
Are you using a widescreen monitor?
06/13/2007 (8:19 am)
I am having this issue as well, but for me i have narrowed it down to either the fact that i am using a wide screen monitor or the video card.first , i test my game on 2 platforms. one is a laptop with a Intel 915 Series video chip set and a wide screen display, the other is a desktop pc with a 17 inch display on a ATI Radeon X1300 Pro video card.
on the the desktop i do not get this with the my hud overlay png, but on the laptop i do. there are disortions/artifacting on some of the lines in the graphic that are not present on the desktop system.
What video card do you have tha thas this problem?
Are you using a widescreen monitor?
#3
The images themselves are not set to be resized based on the resolution of the canvas. I tested this against a variety of resolutions with the same result.
@Jason: This kind of artifacting is inconsistent with a low bit depth. Were that the case, the artifacting would be identical regardless of the input image format. You do, however, bring up an interesting point. I wonder if this isn't a result of the blending of the JPEG alpha. I'm going to remove that from the engine tonight and see if the artifacting is still present. For what it's worth, I've modified GuiBitmapButton to accept an alpha image in the datablock as opposed to one based on the file name. The space savings using this method as opposed to the old way or PNGs is pretty significant with a lot of similarly shaped GUI elements.
06/14/2007 (8:07 pm)
This is on an Nvidia 7900 on a 21" non-widescreen LCD display.The images themselves are not set to be resized based on the resolution of the canvas. I tested this against a variety of resolutions with the same result.
@Jason: This kind of artifacting is inconsistent with a low bit depth. Were that the case, the artifacting would be identical regardless of the input image format. You do, however, bring up an interesting point. I wonder if this isn't a result of the blending of the JPEG alpha. I'm going to remove that from the engine tonight and see if the artifacting is still present. For what it's worth, I've modified GuiBitmapButton to accept an alpha image in the datablock as opposed to one based on the file name. The space savings using this method as opposed to the old way or PNGs is pretty significant with a lot of similarly shaped GUI elements.
Torque Owner Jason Lee