Rub�n wrote:
>
> On 1999/Oct/04, Andreas Beck wrote:
>
> > > We never intended to be real-time, so some while not in retrace
> > > schedule (); can do the job here)
> >
> > Be careful with that. As you get an interrupt that should be o.k., but
> > schedule will come back only every 10ms on Linux/Intel, which is too slow.
>
> My monitor usually has a vertical frequency of 100 Hz, which is the
> same, as you say, than kernel sheduling frequency. Then, you will get a
> screen blinking a lot, I think.
This is only true if:
a) There are other processes which are runable, _and_
b) You are not using realtime priority for your application.
> > The right thing would be to block much like the keyboard code does.
Well, blocking == calling schedule() + marking process as interruptible.
And if you want a graphics application synced with retrace you should
run it with realtime scheduling anyway. With SCHED_RR scheduling I've
run 30 simultaneous applications, where each application must run at
least once every 10ms, on a 50MHz processor without any problems.
This means scheduling 3000 times/s, which is quite a bit more than
any retrace syncing might require...
//Marcus
--
-------------------------------+------------------------------------
Marcus Sundberg | http://www.stacken.kth.se/~mackan/
Royal Institute of Technology | Phone: +46 707 295404
Stockholm, Sweden | E-Mail: [EMAIL PROTECTED]