Some basic stuff about date and Time

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

User avatar
ritz
Quite a regular
Quite a regular
Posts: 49
Joined: Wed Jan 12, 2005 12:06

Some basic stuff about date and Time

Postby ritz » Fri Jan 21, 2005 06:28

Hello All,

I have some basic queries related to date and time handling.
Can any body please help me out by answering the same.

a) Crazy Eddie Gui system or Ogre does not support any kind of date / time manipulation APi's.

It will be required to use tm structure and other api's of time.h to handle date / time related issues.

b) If system date gets changed, does CEGUI applciation gets event or notification for the change.

I need to update the UI based upon the change in system date.

Rgds,
Ritz

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Re: Some basic stuff about date and Time

Postby CrazyEddie » Fri Jan 21, 2005 12:30

We have no time/date related stuff in the library at all (at least at the moment).

Your best bet is probably to periodicaly check to see if the date or time has been modified, or possibly use some mechanism provided by the operating system for this purpose.

HTH

CE.

User avatar
ritz
Quite a regular
Quite a regular
Posts: 49
Joined: Wed Jan 12, 2005 12:06

Re: Some basic stuff about date and Time

Postby ritz » Mon Jan 24, 2005 05:30

Hello CE,


In order to check periodically i need timer's or thread.
is their any facility available with the system

or can you suggest something else

rgds,
Ritz

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Re: Some basic stuff about date and Time

Postby CrazyEddie » Mon Jan 24, 2005 09:57

As I said there is no timer facility within the CEGUI library; you have to use something external. Depending upon your needs this will be provided by either your OS (even WM_TIMER may suffice if you're on Win32) or you could possibly use the date/time/timer facilities in the C/C++ libs. Basically the final approach you'll use will depend upon exactly what you need.

In any case there are zero provisions within CEGUI for this, very shortly CEGUI will actually require you to inject time pulses for certain new features.

CE.

User avatar
ritz
Quite a regular
Quite a regular
Posts: 49
Joined: Wed Jan 12, 2005 12:06

Re: Some basic stuff about date and Time

Postby ritz » Mon Jan 24, 2005 13:10

Hello CE,

Thanks a Lot for responding.
I can get time change event by trapping WM_TIMECHANGE(win32 sdk) event.

What i could not get is "How to trap win32 event in ogre stuff".

rgds
Ritz

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Re: Some basic stuff about date and Time

Postby CrazyEddie » Mon Jan 24, 2005 13:37

ritz wrote:
What i could not get is "How to trap win32 event in ogre stuff".

Oh right, I understand. You may end up either hacking the Ogre code, or more likely passing in your own window for Ogre to use; this way you have access to the Window procedure. I would not know how you'd go about doing this exactly, but I do know that it's possible (look into the SetExternalWindowHandle method in the concrete RenderSystem classes).

HTH

CE.

User avatar
ritz
Quite a regular
Quite a regular
Posts: 49
Joined: Wed Jan 12, 2005 12:06

Re: Some basic stuff about date and Time

Postby ritz » Mon Jan 24, 2005 14:17

Hello CE,
Thanks for the pointer.
I will try it out.

rgds,
Ritz


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 10 guests