new skin for falagard buttons gets pixelized when enlarged

Help and discussion regarding skinning, themes, and other artistic content.

Moderators: CEGUI MVP, CEGUI Team

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

new skin for falagard buttons gets pixelized when enlarged

Postby mba » Tue Jun 13, 2006 08:24

Hi all

I don't think the subject covers the problem I'm working on very well. And I'm not sure I can explain it very well, but here goes:

I have made a new skin for the Taharezlook/CEGUIFalagardBase widgetset by creating a new texture png and making a new imageset file defining each widget element in the image.

When I create a window with some buttons on, approximately the same size as in the texture file each button looks correct, meaning they are not pixelized.
When I create a window with some larger buttons on they get pixelized.
But if I show the window with small buttons on first, and then switch to the window with the larger buttons they now look correct, meaning they are smooth-shaded across the surface.
I've been looking into some of the properties of th button, such as HorzFormat with Stretched on the imagery, but this seems to be set as default.
Is there some gradient smoothing of a texture when the texture is smaller than the texture needed for a widget?

I'm using the mk2 0.4.1 version of CEGUI along with the OgreRenderer on a linux box.

Hope you can help...

Kind regards
Martin

User avatar
Dalfy
CEGUI Team (Retired)
Posts: 130
Joined: Tue Oct 11, 2005 16:13
Location: Paris, FRANCE
Contact:

Postby Dalfy » Tue Jun 13, 2006 10:09

I moved the topic to skins and theme cause it seems more related to this than to the editor :)


But I have no solution to suggest at the moment sorry

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Tue Jun 13, 2006 11:11

sorry thought I posted in the advanced help section?

Martin

User avatar
lindquist
CEGUI Team (Retired)
Posts: 770
Joined: Mon Jan 24, 2005 21:20
Location: Copenhagen, Denmark

Postby lindquist » Tue Jun 13, 2006 14:21

Can you post a screenshot or something? I'm not sure I understand the problem properly

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Wed Jun 14, 2006 08:49

I'm sorry but I have nowhere to post the images.

But the problem lies in that the skin texture gets stretched and magnified across the button surface to accomodate the size of the button. The texture for the button is not large enough.

My question is: is there some smoothing involved during this magnification, making the skin look smooth, instead of just magnifying the texture.

My problem is: When displaying a button that is somewhat larger than the actual size of button skin texture, the skin is 'just' magnified and not filtered in any way. When I flip through some windows where the buttons are smaller, where the texture is large enough to accomodate the size of the buttons. And when I return to the window where the troublesome buttons are: MAGIC! they are now smoothed.

I have been looking through the source of CEGUIRenderableImage.cpp and CEGUIImage.cpp but I can't find any thing that would cause such behavior. I have looked through CEImageset at draw_impl and all the way to the specific renderer.

Kind regards
Martin

User avatar
lindquist
CEGUI Team (Retired)
Posts: 770
Joined: Mon Jan 24, 2005 21:20
Location: Copenhagen, Denmark

Postby lindquist » Wed Jun 14, 2006 11:35

sounds like a problem with texture filtering. what renderer module are you using?

Rackle
CEGUI Team (Retired)
Posts: 534
Joined: Mon Jan 16, 2006 11:59
Location: Montréal

Postby Rackle » Wed Jun 14, 2006 11:51


User avatar
lindquist
CEGUI Team (Retired)
Posts: 770
Joined: Mon Jan 24, 2005 21:20
Location: Copenhagen, Denmark

Postby lindquist » Wed Jun 14, 2006 13:32

ah sry I just read your first post, so Ogre.
This is not a problem with CEGUI, but with the Ogre CEGUI renderer module.

You should take the problem to them as we do not maintain that renderer.

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Thu Jun 15, 2006 15:50

Thanks lindquist

for replying and helping narrowing it down, I will take the problem up in the ogre forum


martin

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Wed Jul 12, 2006 07:04

Hi again

I was playing around with some of the properties of my layout-file, when I discovered that a particular one didn't cause the pixelation of the widgets. I then compare it with some of those that had the problem, and one of the differences where they all had a <Property Name="CloseButtonEnabled" Value="False" />. When I removed this line from my layout files the problem went away!?

Do you still think its the ogre cegui renderer or is it more likely a bug in the xml parsing of the layout files? This is probably not the case because the layout files used in the Ogre GUI demo also has this property set.

Kind regards
Martin

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Update

Postby mba » Mon May 14, 2007 11:22

I have now done some more research into the matter.

If I have an ogre overlay for debug statistics I get pixelized gui elements until I press a button without any text on it.

If I leave out the overlay the pixelation is gone if the mouse cursor is visible on the screen. If I disable the cursor the elements are pixelized until I press a button without text.

Now to my question: What filtering is only activated/enabled when displaying the mouse cursor or a pressed button (without text).

I'm baffled, hope someone has a clue :D.

Regards
Martin B. Andersen

User avatar
mba
Not too shy to talk
Not too shy to talk
Posts: 41
Joined: Tue Oct 11, 2005 11:54
Location: Denmark

Postby mba » Wed Jul 04, 2007 07:20

The issue has been solved, partly in the new Eihort and partly by me. Texture filtering wasn't set correctly in OpenGL, and as you said lindquist it was in Ogre or more specific in the OgreCEGUI renderer.

see
http://www.ogre3d.org/phpBB2/viewtopic. ... highlight=
and
http://www.ogre3d.org/phpBB2/viewtopic. ... highlight=


kind regards
Martin


Return to “Skins and Themes”

Who is online

Users browsing this forum: No registered users and 11 guests