## Registration code : 12 ##
It is currently Tue May 22, 2018 7:53 pm

All times are UTC + 1 hour [ DST ]

Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: Frost Engine's GUI : a new library
PostPosted: Wed Sep 15, 2010 3:34 am 
Site Admin
User avatar
 WWW  Profile

Joined: Mon Jan 28, 2008 9:44 pm
Posts: 200
Location: France
Hi everyone,

I'm proud to announce that Frost Engine's GUI system is now a separate library.
It now supports different front-ends for rendering, currently OGRE and SFML.

(the GUI in Frost Engine, using OGRE, and another project, using SFML)

To use it, you still need the Utils, XML and Input libraries from Frost Engine, along with Lua 5.1, OIS and FreeType.
Usage is then very simple :
s_refptr<GUIManager> pGUIMgr;

// Provide some parameters (may change depending on the front-end)
s_map<s_str, s_var> lParams;
lParams["game_version"] = s_str("1000");
lParams["width"]        = s_uint(1024);
lParams["height"]       = s_uint(768);
pGUIMgr = s_refptr<GUIManager>(new GUIManager(lParams));

// Set the directory and load it


// In the game loop :
// Update

// ... and render

Everything else is done by .xml and .lua files of your addons.

Note that the GUI lib requires that you define several functions :
// Closes the program nicely
void Shutdown()

// Renders a quad on the current render target
// Note : it is only used for "unmanaged" GUI, that is : Sprite and Text used without GUIManager, if you ever need these.
void RenderQuad( const GUI::Quad& mQuad )

Then, adding your custom GUI widget type is rather straightforward : see this wiki link for more infos.

For the record :
The reason why I did this is because I started a new game project along with Frost Engine. You may not know, but making this GUI system took me many, maaaany hours ! And after all, I really like it.
So I took the time to make it more generic, and allow it to be used outside of Frost Engine.

Anyway, I hope it will be of some use to anyone :)

- Kal.


Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour [ DST ]

Who is online

Users browsing this forum: No registered users and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
SourceForge.net Logo
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group  
Design By Poker Bandits