POV-Ray : Newsgroups : povray.beta-test : Photon counting : Re: Photon counting Server Time
26 Jun 2024 12:32:52 EDT (-0400)
  Re: Photon counting  
From: waggy
Date: 6 Jan 2011 12:35:00
Message: <web.4d25fc328b8311479726a3c10@news.povray.org>
Warp <war### [at] tagpovrayorg> wrote:
> Le_Forgeron <lef### [at] freefr> wrote:
> > Two threads updating the same counter would need a mutex to protect the
> > counter, defeating the purpose of multi-threading (well, the mutex would
> > become the bottleneck).
>
>   If the count is updated infrequently (eg. once per second) it shouldn't
> make any difference.
>
Agreed.  Alternately, threads can update their own counters.  When it's time to
report, they can read the others and report the total.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.