Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc')
-rw-r--r--source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc b/source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc
index 286411b7d28..eeb77abd624 100644
--- a/source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc
+++ b/source/blender/nodes/geometry/nodes/node_geo_attribute_randomize.cc
@@ -126,7 +126,7 @@ static void randomize_attribute(MutableSpan<T> span,
/* The operations could be templated too, but it doesn't make the code much shorter. */
switch (operation) {
case GEO_NODE_ATTRIBUTE_RANDOMIZE_REPLACE_CREATE:
- parallel_for(span.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(span.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
const T random_value = random_value_in_range<T>(ids[i], seed, min, max);
span[i] = random_value;
@@ -134,7 +134,7 @@ static void randomize_attribute(MutableSpan<T> span,
});
break;
case GEO_NODE_ATTRIBUTE_RANDOMIZE_ADD:
- parallel_for(span.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(span.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
const T random_value = random_value_in_range<T>(ids[i], seed, min, max);
span[i] = span[i] + random_value;
@@ -142,7 +142,7 @@ static void randomize_attribute(MutableSpan<T> span,
});
break;
case GEO_NODE_ATTRIBUTE_RANDOMIZE_SUBTRACT:
- parallel_for(span.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(span.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
const T random_value = random_value_in_range<T>(ids[i], seed, min, max);
span[i] = span[i] - random_value;
@@ -150,7 +150,7 @@ static void randomize_attribute(MutableSpan<T> span,
});
break;
case GEO_NODE_ATTRIBUTE_RANDOMIZE_MULTIPLY:
- parallel_for(span.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(span.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
const T random_value = random_value_in_range<T>(ids[i], seed, min, max);
span[i] = span[i] * random_value;
@@ -170,7 +170,7 @@ static void randomize_attribute_bool(MutableSpan<bool> span,
{
BLI_assert(operation == GEO_NODE_ATTRIBUTE_RANDOMIZE_REPLACE_CREATE);
UNUSED_VARS_NDEBUG(operation);
- parallel_for(span.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(span.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
const bool random_value = BLI_hash_int_2d_to_float(ids[i], seed) > 0.5f;
span[i] = random_value;
@@ -190,7 +190,7 @@ Array<uint32_t> get_geometry_element_ids_as_uints(const GeometryComponent &compo
BLI_assert(hashes.size() == hash_attribute->size());
const CPPType &cpp_type = hash_attribute->type();
GVArray_GSpan items{*hash_attribute};
- parallel_for(hashes.index_range(), 512, [&](IndexRange range) {
+ threading::parallel_for(hashes.index_range(), 512, [&](IndexRange range) {
for (const int i : range) {
hashes[i] = cpp_type.hash(items[i]);
}