Skip to content

Commit 2dbc336

Browse files
authored
Merge pull request #1 from almarouk/patch-1
Fix impact computation
2 parents a751a33 + 6f596ff commit 2dbc336

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

cuda_rasterizer/forward.cu

+3-2
Original file line numberDiff line numberDiff line change
@@ -441,13 +441,14 @@ renderCUDA(
441441
biliniar_texture_sampler(sampled_color, s.x, s.y, texture_color + texture_offset, texture_size, 3);
442442
for (int ch = 0; ch < CHANNELS; ch++)
443443
C[ch] += (sampled_color[ch] + features[collected_id[j] * CHANNELS + ch]) * alpha * T;
444+
445+
atomicAdd(&(impact[ collected_id[j] ]), alpha * T);
446+
444447
T = test_T;
445448

446449
// Keep track of last range entry to update this
447450
// pixel.
448451
last_contributor = contributor;
449-
450-
atomicAdd(&(impact[ collected_id[j] ]), alpha * T);
451452
}
452453
}
453454

0 commit comments

Comments
 (0)