I want to create an ImageBox with stretch alignment, but I don't want the texture to be distorted by Ogre's linear filtering.
I have seen the FilterNoneSkin but I don't understand how to use it with ImageBox, can you provide an example?
Thanks in advance
Using custom skin for ImageBox
<?xml version="1.0" encoding="UTF-8"?>
<MyGUI type="Resource" version="1.1">
<Resource type="ResourceSkin" name="ImageBoxFilterNone" size="16 16">
<BasisSkin type="FilterNone" offset="0 0 16 16"/>
Thanks for the answer my.name,
I tried that (I put the code in MyGUI_CommonSkins.xml under the normal ImageBox one) and I changed my ImageBox to look like this
<Widget type="ImageBox" skin="ImageBoxFilterNone" position="0 0 400 230" align="Stretch" name="textureClient">
The file gets loaded correctly and there's no error/warning in the log.
However, when I actually use it I can see that ogre loads the texture, but the widget is empty and the image doesn't show up.
Any idea? I'm using the latest svn rev (5179)
std::string subWidgetCategory = MyGUI::SubWidgetManager::getInstance().getCategoryName();
Try to register it.
Thanks a lot, it works now
Although I had to add the MyGUI_FilterNoneSkin.h and .cpp in my project since they are in the EditorFramework, not in MyGUIEngine, but it works so it's ok