MyGUI Feedback

General discussion regarding the OpenMW project.
For technical support, please use the Support subforum.
User avatar
psi29a
Posts: 5362
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

MyGUI Feedback

Post by psi29a »

BrotherBrick wrote: Is there anything that we (OpenMW) can do for you guys?
George Evmenov wrote: well, may be some feedback about library itself.

what is done wrong or complicated way, what is too unclear in library, what cam be added, improved, etc.

we do not need any specific help currently, but we do not gain constructive feedback frequently
Well devs, since we are using their library... now is the time to ask questions and field comments.
User avatar
pvdk
Posts: 528
Joined: 12 Aug 2011, 16:34

Re: MyGUI Feedback

Post by pvdk »

One thing I can think of is: better bitmap font handling. That's something I have asked about at the Ogre Addons subforums and PM-ed with a MyGUI dev. The thing is, every glyph has to be the same height. Glyphs that are shorter get stretched. I also tried to get it working with CEGUI at the time, and it works properly with CEGUI.

For us it won't matter that much anymore, since we're going to stick with non-bitmap fonts, but other people might want to have better bitmap font support.
User avatar
Lazaroth
Posts: 220
Joined: 30 May 2012, 05:04

Re: MyGUI Feedback

Post by Lazaroth »

2 things pop into my mind:

1. It's really built around having one master image and using different parts of it for different things with offsets. Morrowind however have different images for the same thing, e.g. 8 for a border and 3 for a scrollbar. For the border it's not that big of a problem, but fixing the scrollbar properly can't be done without hacking away in C++.

2. Coming back to the scrollbar, there is only one scrollbar, used for both vertical and horizontal sliders, but gets rotated accordingly. Rotating it must also be done in C++, but would be much easier if there were a property key or something similar easy.

What it could look like:

<Skin name="MW_ScrollTrackV" size="16 16"
texture="scrollbar_left.dds, scrollbar_middle.dds, scrollbar_right.dds"> // combines 3 images into 1 "group"
<BasisSkin type="TileRect" offset="0 0 16 16" align="Stretch">
<State name="normal" offset="0 0 16 16">
<Property key="TileSize" value="16 16"/>
<Property key="TileV" value="true"/>
<Property key="Rotate" value="90"/> // rotates image group 90 degrees
</State>
</BasisSkin>
</Skin>
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: MyGUI Feedback

Post by scrawl »

I would appreciate a better way of laying out text and button widgets based on the size of the text (entirely in .layout files)
This is the workaround currently in place but it's horrible.
Ideally I would like a layouting system similiar to GTK / QT toolkits.
Altren
Posts: 12
Joined: 05 Jun 2013, 14:27
Location: Moscow, Russia
Contact:

Re: MyGUI Feedback

Post by Altren »

pvdk wrote:The thing is, every glyph has to be the same height. Glyphs that are shorter get stretched.
This wasn't implemented last time we discussed that. Right now it works (was added in 3.2.0 as far as I remember), I just looked at default bitmap font that comes with MyGUI and all glyphs have different height, advance and bearing.
Altren
Posts: 12
Joined: 05 Jun 2013, 14:27
Location: Moscow, Russia
Contact:

Re: MyGUI Feedback

Post by Altren »

Lazaroth wrote:1. It's really built around having one master image and using different parts of it for different things with offsets. Morrowind however have different images for the same thing, e.g. 8 for a border and 3 for a scrollbar. For the border it's not that big of a problem, but fixing the scrollbar properly can't be done without hacking away in C++.
In theory it is possible, but it is actually very bad idea to store widgets parts in different textures, since when you render this on GPU it will use one batch for each texture, thus any complex gui would work slow. Such things were used when rendering was done using CPU, but now all GPU based GUIs use texture atlases.
So this is step back, that would decrease GUI performance and increase code complexity for barely no profit.

Well, those textures can be united during loading, but again it is easier to do that in image editor, rather than slow down startup time.
Lazaroth wrote:2. Coming back to the scrollbar, there is only one scrollbar, used for both vertical and horizontal sliders, but gets rotated accordingly. Rotating it must also be done in C++, but would be much easier if there were a property key or something similar easy.
Makes sense, I guess we can add such skin property in future. It is very minor thing though and I never heard any MyGUI user needed that before.
User avatar
pvdk
Posts: 528
Joined: 12 Aug 2011, 16:34

Re: MyGUI Feedback

Post by pvdk »

Altren wrote:This wasn't implemented last time we discussed that. Right now it works (was added in 3.2.0 as far as I remember)
Very nice! Thanks. I wonder if there is still interest in getting Morrowind's bitmap font supported in OpenMW.
Altren wrote:Well, those textures can be united during loading, but again it is easier to do that in image editor, rather than slow down startup time.
Combining them with an image editor is not an option for us, since we can't ship Morrowind content due to copyright.


Didn't we need rotation for the cursors too?
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: MyGUI Feedback

Post by scrawl »

Yes, cursors need rotation. We don't use mygui's cursor display functionality, but still use MyGUI to render them using a floating widget with RotatingSkin.
Altren
Posts: 12
Joined: 05 Jun 2013, 14:27
Location: Moscow, Russia
Contact:

Re: MyGUI Feedback

Post by Altren »

scrawl wrote:I would appreciate a better way of laying out text and button widgets based on the size of the text (entirely in .layout files)
This is the workaround currently in place but it's horrible.
Ideally I would like a layouting system similiar to GTK / QT toolkits.
We tried to implement that and this feature have high priority, but we failed to implement well structured and easy system so far.
Altren
Posts: 12
Joined: 05 Jun 2013, 14:27
Location: Moscow, Russia
Contact:

Re: MyGUI Feedback

Post by Altren »

scrawl wrote:Yes, cursors need rotation. We don't use mygui's cursor display functionality, but still use MyGUI to render them using a floating widget with RotatingSkin.
Is it used for player position in minimap? Then it is done how it is supposed to be - with RotatingSkin.
Though, It have nothing to do with rotations that Lazaroth asked about, since it is static rotation used to customize skin.
Post Reply