public void Accumulate(System.Drawing.Point pixel, Ray r, double t) {
   PerPixel pp = _grid[pixel];
   if (pp == null) {
     pp = new PerPixel(_max_entries, r, t);
     _grid[pixel] = pp;
   } else {
     pp.Add(t);
   }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Stores the captured pixel in the grid.
        /// If the value of "pixel" corresponds to point which is
        /// already stored in the list, the mean t will be updated.
        /// </summary>
        /// <param name="pixel"></param>
        /// <param name="r"></param>
        /// <param name="t"></param>
        public void Accumulate(System.Drawing.Point pixel, Ray r, double t)
        {
            PerPixel pp = _grid[pixel];

            if (pp == null)
            {
                pp           = new PerPixel(r, t);
                _grid[pixel] = pp;
            }
            else
            {
                pp.Add(t);
            }
        }