Skip to content
Permalink
Browse files

Improved lighting

This commit rewrites the procedure that is responsible for light
updating.

this commit
-provides iterative solutions for unlighting and light spreading
-introduces a new priority queue-like container for the iteration
-creates per-node MapBlock caching to reduce retrieving MapBlocks from
the map
-calculates with map block positions and in-block relative node
coordinates
-skips light updating if it is not necessary since the node's new light
will be the same as its old light was
  • Loading branch information
juhdanad authored and nerzhul committed Oct 27, 2016
1 parent 1fd9a07 commit c071efaa43ad3dcba7d60a7a67e942aae2a7dc83
Showing with 643 additions and 443 deletions.
  1. +15 −426 src/map.cpp
  2. +1 −15 src/map.h
  3. +14 −2 src/mapnode.cpp
  4. +9 −0 src/mapnode.h
  5. +584 −0 src/voxelalgorithms.cpp
  6. +20 −0 src/voxelalgorithms.h

0 comments on commit c071efa

Please sign in to comment.