update gradle project, parallel for-loop based on std::thread on android, fix mipmaps on TextureManager
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include "canvas.h"
|
||||
#include "app.h"
|
||||
#include "image.h"
|
||||
#include "util.h"
|
||||
|
||||
Node* NodePanelGrid::clone_instantiate() const
|
||||
{
|
||||
@@ -388,7 +389,7 @@ void NodePanelGrid::bake_uvs()
|
||||
dispatch_queue_t queue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0);
|
||||
dispatch_apply((size_t)fb.getHeight(), queue, ^ (size_t y)
|
||||
#else
|
||||
for (int y = 0; y < fb.getHeight(); y++)
|
||||
parallel_for(fb.getHeight(), [&](int y)
|
||||
#endif
|
||||
{
|
||||
for (int x = 0; x < fb.getWidth(); x++)
|
||||
@@ -428,10 +429,7 @@ void NodePanelGrid::bake_uvs()
|
||||
out = glm::lerp(glm::vec4(255, 255, 255, 255), glm::vec4(50, 50, 50, 255), hit / (float)samples);
|
||||
}
|
||||
pb_value++;
|
||||
}
|
||||
#if _WIN32 || __IOS__ || __OSX__
|
||||
);
|
||||
#endif
|
||||
});
|
||||
}
|
||||
);
|
||||
while (pb_value < fb.getHeight())
|
||||
|
||||
Reference in New Issue
Block a user