Re: SDL-News: Need help for SDL Timer

Subject: Re: SDL-News: Need help for SDL Timer
From: rick reed (
Date: Tue Jul 29 2003 - 10:41:06 GMT

Become an SDL Forum Society member <>
The originator of this message is responsible for its content.
-----From rick reed <> to sdlnews -----

on 26/7/03 23:46, Weimin Ma at wrote:

> Hello!
> I have a question on SDL Timer. Could you please
> give me an example which has a timer set by one
> process
> and consumed or reset by another process?
> Many thanks!
> Weimin Ma

The answer from Fabrice is correct, but you may wish to consider the

Send the time of expiry in a signal to the process to "consume" the timer.

When the signal is received compare the time with NOW.
If NOW is greater than the sent time the "timer" has expired, otherwise set
a local timer.

Actually you could just set the local timer to the time received in which
case it will expire immmediately.

Rick Reed -
Tel:+44 15394 88462 Fax:+44 15394 88218 Mob:+44 7970 50 96 50

--End text from rick reed <> to sdlnews --- For extra SDL Forum Society benefits join at <>

This archive was generated by hypermail 2a23 : Thu May 09 2013 - 16:05:49 GMT