Skip to content

Commit

Permalink
fix to ensure generated light probes do not get placed too close to m…
Browse files Browse the repository at this point in the history
…anual light probes
  • Loading branch information
grenappels committed Oct 17, 2023
1 parent a574c02 commit 97205ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scene/3d/lightmap_gi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@ void LightmapGI::_gen_new_positions_from_octree(const GenProbesOctree *p_cell, f
const Vector3 *pp = probe_positions.ptr();
bool exists = false;
for (int j = 0; j < ppcount; j++) {
if (pp[j].is_equal_approx(real_pos)) {
if (pp[j].distance_to(real_pos) < (p_cell_size * 0.5f)) {
exists = true;
break;
}
Expand Down

0 comments on commit 97205ea

Please sign in to comment.