[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Displaying live video -- how to notify main loop from another thread
From: |
David Chisnall |
Subject: |
Re: Displaying live video -- how to notify main loop from another thread? |
Date: |
Fri, 9 Jul 2010 14:02:13 +0100 |
On 9 Jul 2010, at 13:56, Marek Peca wrote:
> Please, tell me: is it needed to create threads using GNUstep thread API, or
> may I use ordinary glibc pthreads? The whole application is written in plain
> C, requiring about 5 threads (2 camera threads, slower computation, disk file
> output, GUI) with different priorities, including a setting of SCHED_FIFO
> etc. I would really like to avoid GNUstep API for threads and use plain POSIX
> threads and to use GNUstep only for the GUI.
It is not required, however GNUstep does need to know that the app is
multithreaded. In a single-threaded app, it doesn't bother locking some things
internally. The simplest thing to do is start an NSThread that exits
immediately when your app launches. This will ensure that anything that needs
to be in multithreaded mode is.
David
-- Sent from my STANTEC-ZEBRA
Re: Displaying live video -- how to notify main loop from another thread?, David Chisnall, 2010/07/09