Location of SpringApp class definition.

Location of SpringApp class definition.

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
User avatar
ILMTitan
Spring Developer
Posts: 410
Joined: 13 Nov 2004, 08:35

Location of SpringApp class definition.

Post by ILMTitan »

I've begun fiddling about making a GUI interface, and I thought it would be a good idea to make it so that SDL_Events went to the GUI first, and then could be passed through to the current UI Event handling code. This, however, required calling a newly written function in SpringApp, which in turn required including "Main.cpp" which caused link errors. So I moved SpringApp to SpringApp.h and SpringApp.cpp.

As this is a rather large change to the very core of the program, I felt I should get opinions of others.

I also thought I should get feedback on having a SpringApp function called by something other than main().
User avatar
jcnossen
Former Engine Dev
Posts: 2440
Joined: 05 Jun 2005, 19:13

Post by jcnossen »

SpringApp contains a lot of the basic setup code, I would say keep that the same and just move the event handling out of it in a seperate class.

If you're serious about doing the GUI, I think it would be best if you get svn access and make a new GUI branch.
User avatar
Tim Blokdijk
Posts: 1242
Joined: 29 May 2005, 11:18

Post by Tim Blokdijk »

Yes, and join the mailinglist.
User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

Post by Argh »

Oh, noes! We shall never see ILMTitan get anything done, ever again! He's being sucked down the black hole of

GUuuuuiiiiiiiiiii
User avatar
Comp1337
Posts: 2434
Joined: 12 Oct 2005, 17:32

Post by Comp1337 »

Pshh, someone needs to do it. Dont make him reconsider!
User avatar
ILMTitan
Spring Developer
Posts: 410
Joined: 13 Nov 2004, 08:35

Post by ILMTitan »

Ok, I made an event handler class. In the main loop in SpringApp::Run(), once it gets the event, it just passes it to the event handler. However, because of the way the code was written, I also needed to move UpdateSDLKeys(), SetSDLVideoMode(), SetVSync(), and InitOpenGL() into the new class. I do think, however, this is about the minimum change I can make to get access to the event management external to SpringApp.

Before I get SVN commit access, however, I want to make sure I can load up the Cegui libraries.

Also, I am mostly going to be working on the API. It sounds like Word my be doing the actual Gui coding. I'll have to get in contact with him.

@Argh Jokingly, I half decided to do this to guarantee getting a job.
Post Reply

Return to “Engine”