On 23/09/2011, at 11:37 AM, Steven Boswell II wrote:
If that's how you expect to use mutexes, an atomic integer would be a LOT more efficient, e.g. the g_atomic_int functions in glib. Those are implemented with processor instructions instead of OS system calls.
I assume I'd need to use glib but it appears to be broken on my system. I also tried the gcc atomic operations but I've only got gcc 4.0.1.I've also sig_atomic_t but I've got no idea if it's reading and incrementing as an atomic action. The read and increment is such a short duration I cannot get it to break even without locking.
Doesn't look like there is a simple atomic method I can add to the code.
I've struggled mightily to make y4mdenoise more multiprocessor friendly, and one of the methods I'd like to try is to slice the frame into pieces and denoise them separately. I just fear visible artefacts at the boundaries between slices. Having a day job pretty much kills the energy I'd need to code in my spare time, so traditionally, y4mdenoise development happens during periods of unemployment, thus I haven't had time to try this method yet.
Are you making your output frame solely from the input frame(s) ? Or are you using pixels from the output frame to generate other pixels ? Or updating the frame data in place?If you aren't using any of the data from the output frame then there won't be any artifacts. Just remember to pass in the entire input frame into your worker thread, not just a slice. But you only need to generate the output pixels for the slice.
Does this make sense? Mark
------------------------------------------------------------------------------ All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2dcopy2
_______________________________________________ Mjpeg-users mailing list Mjpeg-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mjpeg-users