Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/base/StarCellularLighting.hpp
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2023-06-29 10:11:19 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2023-06-29 10:11:19 +1000
commit624c7aaaf192f2e87081a241123a8507a4718ba3 (patch)
treea54b09902da8d724f3ba740a215fd53d8a861fd9 /source/base/StarCellularLighting.hpp
parent9d67cda97fc327ca3c53e044a897fbfb196104c4 (diff)
Move lighting calculation to separate thread
Diffstat (limited to 'source/base/StarCellularLighting.hpp')
-rw-r--r--source/base/StarCellularLighting.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/base/StarCellularLighting.hpp b/source/base/StarCellularLighting.hpp
index 7579a63..54be414 100644
--- a/source/base/StarCellularLighting.hpp
+++ b/source/base/StarCellularLighting.hpp
@@ -8,6 +8,7 @@
#include "StarColor.hpp"
#include "StarInterpolation.hpp"
#include "StarCellularLightArray.hpp"
+#include "StarThread.hpp"
namespace Star {
@@ -44,6 +45,9 @@ public:
// the call to 'begin', and formatted as RGB24.
void calculate(Image& output);
+ void setupImage(Image& image, PixelFormat format = PixelFormat::RGB24) const;
+
+ ThreadFunction<Image> calculateAsync();
private:
Json m_config;
bool m_monochrome;