Hi.
I've started doing my own Falagard skin to use in my game. At the moment it's just a clone of TaharezLook which I will do a draw-over of this week. Except I have upped the texture to 1024*1024 so I can do some high res detailing (Also made the image a PNG so that it displays in the unified editor).
I've quadrupled all of the positions and dimensions of the pieces in the ImageSet to match to new larger texture.
After doing this I ran the TextDemo.layout within the editor, and noticed that I needed to apply offsets to WindowLeftEdge and WindowRightEdge within the ImageSet editor. (+16 and -16 lined up perfectly).
This worked great within the editor, but was not reflected when I ran the layout in my game (all data correctly copied across to my game folder).
So my question is this:
Is there a way to make the CEGUI-lib in my game apply the offsets found in the ImageSet file (in the same way that the editor picks up the offset values and uses them), or will I have to poke around in the LookNFeel file to achieve the same results?
Quick question about skinning.
Moderators: CEGUI MVP, CEGUI Team
- Nickenstein79
- Quite a regular
- Posts: 93
- Joined: Thu May 09, 2013 06:19
- CrazyEddie
- CEGUI Project Lead
- Posts: 6760
- Joined: Wed Jan 12, 2005 12:06
- Location: England
- Contact:
Re: Quick question about skinning.
This should work as-is - CEED uses CEGUI to render its layout and preview content (different versions, but this should still work - nothing was 'fixed' relating to this in the version of CEGUI that CEED uses). It's possible that it's looknfeel related, but I don't think so. I will look into this a little more closely later and get back to you (because it's obviously something).
CE.
CE.
Useful Links: Forum Guidelines | Documentation | Tutorials | HOWTO | Videos | Donate to CEGUI | CEGUI Twitter
- Nickenstein79
- Quite a regular
- Posts: 93
- Joined: Thu May 09, 2013 06:19
Re: Quick question about skinning.
Thanks, Eddie.
Extra info:
I'm using the OgreRenderer. CEGUI 0.7.9 built against Ogre_1_8_1.
This is my CEGUI setup code (In case you spot me doing something wrong here):
I have debug-stepped into:
The rawXML data that gets passed to XML_Parse is indeed the correct XML data found in my Scheme file.
and "Scheme& Scheme_xmlHandler::getObject() const" is returning a valid d_scheme that references 1 imageset, named "TaharezLook.imageset" as would be expected, so as far as I can tell the XML scheme is parsed correctly and the imageset loaded correctly.
Could it be the OgreRenderer not picking up on the offset values?
Cheers,
Nick
EDIT - I can work around this issue by setting the offsets back to zero, and instead increase the widths of the rectangles by 16 to achieve the same effect.
Extra info:
I'm using the OgreRenderer. CEGUI 0.7.9 built against Ogre_1_8_1.
This is my CEGUI setup code (In case you spot me doing something wrong here):
Code: Select all
// Start CEGUI
CEGUI::OgreRenderer& myRenderer = CEGUI::OgreRenderer::bootstrapSystem();
// set the default resource groups to be used
CEGUI::Imageset::setDefaultResourceGroup("Imagesets");
CEGUI::Font::setDefaultResourceGroup("Fonts");
CEGUI::Scheme::setDefaultResourceGroup("Schemes");
CEGUI::WidgetLookManager::setDefaultResourceGroup("LookNFeel");
CEGUI::WindowManager::setDefaultResourceGroup("Layouts");
CEGUI::ScriptModule::setDefaultResourceGroup("Lua_Scripts");
CEGUI::XMLParser* parser = CEGUI::System::getSingleton().getXMLParser();
if (parser->isPropertyPresent("SchemaDefaultResourceGroup"))
parser->setProperty("SchemaDefaultResourceGroup", "Xml_Schemas");
// SETUP CEGUI DEFAULTS
CEGUI::SchemeManager::getSingleton().create( "TaharezLook.scheme" );
CEGUI::FontManager::getSingleton().create( "DejaVuSans-10.font" );
CEGUI::System::getSingleton().setDefaultFont( "DejaVuSans-10" );
CEGUI::System::getSingleton().setDefaultMouseCursor( "TaharezLook", "MouseArrow" );
//CEGUI::System::getSingleton().setDefaultToolTip( "TaharezLook/Tooltip" );
// start a layout
CEGUI::WindowManager& wmgr = CEGUI::WindowManager::getSingleton();
CEGUI::Window* myRoot = CEGUI::WindowManager::getSingleton().loadWindowLayout("TextDemo.layout");
CEGUI::System::getSingleton().setGUISheet( myRoot );
// add an additional "hello world" window
CEGUI::FrameWindow* fWnd = static_cast<CEGUI::FrameWindow*>(wmgr.createWindow( "TaharezLook/FrameWindow", "testWindow" ));
myRoot->addChildWindow( fWnd );
fWnd->setPosition( CEGUI::UVector2( CEGUI::UDim( 0.0f, 0 ), CEGUI::UDim( 0.0f, 0 ) ) );
fWnd->setSize( CEGUI::UVector2( CEGUI::UDim( 0.25f, 0 ), CEGUI::UDim( 0.25f, 0 ) ) );
fWnd->setText( "Hello World!" );
I have debug-stepped into:
Code: Select all
CEGUI::SchemeManager::getSingleton().create( "TaharezLook.scheme" );
The rawXML data that gets passed to XML_Parse is indeed the correct XML data found in my Scheme file.
and "Scheme& Scheme_xmlHandler::getObject() const" is returning a valid d_scheme that references 1 imageset, named "TaharezLook.imageset" as would be expected, so as far as I can tell the XML scheme is parsed correctly and the imageset loaded correctly.
Could it be the OgreRenderer not picking up on the offset values?
Cheers,
Nick
EDIT - I can work around this issue by setting the offsets back to zero, and instead increase the widths of the rectangles by 16 to achieve the same effect.
- Nickenstein79
- Quite a regular
- Posts: 93
- Joined: Thu May 09, 2013 06:19
Re: Quick question about skinning.
Just a bump to say:
This is very, very low priority, Eddie. (I already mentioned that I can easily work around the issue by not using offsets and just shift positions, add blank pixels, etc...)
Now that I have drawn my own set of widget pieces, my Hi-Res Re-Skin of TaharezLook doesn't actually need any offset values at all.
(Apparently my 'coder art' is quite good. Fellow games-industry-artists think I have a real artist chained up under the stairs to draw pixels for me.)
For anyone interested in CEGUI-Skinning:
Essentially, I am doing a Hi-Res re-skin of the TaharezLook ImageSet for my Operation-Roboid game (Because CEED works very well with the Taharez ImageSet, once you learn how to avoid the specific clicks that will crash the editor).
My Hi-Rez TahrezLook is now very visually similar to the 'Confluence-Skin' currently used as the main frontend for XBMC.
Which looks like this:
I'll upload some vids/pics of my Re-Skin when I'm fully happy with the look of it. (probably before Friday.)
Cheers,
Nick
This is very, very low priority, Eddie. (I already mentioned that I can easily work around the issue by not using offsets and just shift positions, add blank pixels, etc...)
Now that I have drawn my own set of widget pieces, my Hi-Res Re-Skin of TaharezLook doesn't actually need any offset values at all.
(Apparently my 'coder art' is quite good. Fellow games-industry-artists think I have a real artist chained up under the stairs to draw pixels for me.)
For anyone interested in CEGUI-Skinning:
Essentially, I am doing a Hi-Res re-skin of the TaharezLook ImageSet for my Operation-Roboid game (Because CEED works very well with the Taharez ImageSet, once you learn how to avoid the specific clicks that will crash the editor).
My Hi-Rez TahrezLook is now very visually similar to the 'Confluence-Skin' currently used as the main frontend for XBMC.
Which looks like this:
I'll upload some vids/pics of my Re-Skin when I'm fully happy with the look of it. (probably before Friday.)
Cheers,
Nick
Who is online
Users browsing this forum: Bing [Bot] and 15 guests