+1 vote

I have vertices that I'm adding to an ArrayMesh and then a MeshInstance and they are offset a certain amount from <0,0,0>. I find that if I don't attempt to undo this offset then my points get rendered in a slightly off fashion.

image

When I offset the set of vertices by the position of the first vertex I get this.

image

The coordinates that I'm offsetting by are a little high, but certainly nowhere close to the float32 ceiling.

The bounding box for the entire point cloud when it isn't shifted to the origin is 409001, 0.957346, 3660087.5 - 0.6875, 0.2037, 0.5

Anyone know what's causing this?

Godot version 3.5.1
in Engine by (39 points)

I think in the documentation there's a hint about the problem that's coming up here. https://docs.godotengine.org/en/stable/tutorials/performance/optimizing_3d_performance.html#large-worlds They remark that when numbers are too large they suffer from floating point errors. This could be the issue, so by shifting we essentially are moving the whole world closer to the camera starting position so the rendering has fewer rounding errors placing points in the same spot?

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.