Commit 46754ef8

Introduces shader storage buffers to make world (lighting and temperature) information available on shaders and uses the information

Relates to #44, #45, #46


Hello! While the commit message does not sound super exciting, this is actually the basis of any upcoming work for light/temperature visualisations, as a proof of concept this has been now implemented for a very narrow case: just for the floor tiles and not taking any artificial light sources into consideration.
What hasn’t changed since the last commit is the temporary implementation of the light calculation for rooms, which is just applying a static offset to whatever the “outside” value is.

As you can see here, as soon as a room is closed up the lighting of the floor tile changes, as well as changing back to the “outside” value as soon as it is opened back up again.

As mentioned above, this is only a proof-of-concept for now, so the next steps will be also applying the same data for wall tiles and models, both of which will require a different way to map them to to a given tile, in order to take lighting information from it. Once that basic functionality is working in all three cases (walls, floor and models), I will look into support artificial light sources, which should result in a single implementation for all three cases.

Not mentioned in the commit message were fixing a bunch of smaller bugs and some linting warnings. 🙂 Hopefully the next commit should be a matter of days, not weeks, like this one since a fair share of research and trying went into this one. I for one can’t wait to see this topic through to finally get some sorely needed visual improvements. 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *