[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mozilla-gtk
Subject:    Re: !HELP! Thread-safe drawing with GDK from Linux plugin
From:       Mark <markholmberg () yahoo ! com>
Date:       2001-01-04 20:51:32
[Download RAW message or body]

So, would you say that a  "local" NSPR thread for drawing the video frames, with a
PR_Sleep() in the threads main loop, would do the trick ?

Christopher Blizzard wrote:

> Mark wrote:
>
> > I am actually spawning a new thread and using it to draw video frames.
> > Because, when I try to play video from the main thread, the netscape GUI will
> > become unresponsive.
> >
> > Christopher Blizzard wrote:
> >
> >
> >> Mark wrote:
> >>
> >>
> >>> What kind of locking mechanism is needed to safely draw with GDK from a
> >>> multi-threaded plugin ? Is it possible to do this without using NSPR
> >>> threads (i.e. pthreads) ? If so, then how ? What is required to do it
> >>> with NSPR threads ?
> >>>
> >>> Thanks,
> >>> Mark
> >>
> >> If you are doing drawing from only one thread and it's the main thread
> >> then you should be fine.
> >>
> >> --Chris
> >>
> >> --
> >> ------------
> >> Christopher Blizzard
> >> http://people.redhat.com/blizzard/
> >> ------------
>
> That will happen no matter what you do.  You have to return control to
> the mainloop for a while.
>
> --Chris
>
> --
> ------------
> Christopher Blizzard
> http://people.redhat.com/blizzard/
> ------------

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic