Geometry Nodes: Make plane primitive size consistent

This means the "Size" input is treated as a "diameter" instead of
a "radius", just like the 3D view primitives.
This commit is contained in:
Hans Goudey
2021-03-23 11:05:18 -04:00
parent 29c0b34b20
commit 83df354524

View File

@@ -73,8 +73,8 @@ static Mesh *create_plane_mesh(const int verts_x, const int verts_y, const float
MutableSpan<MPoly> polys{mesh->mpoly, mesh->totpoly};
{
const float dx = size * 2.0f / edges_x;
const float dy = size * 2.0f / edges_y;
const float dx = size / edges_x;
const float dy = size / edges_y;
float x = -size;
for (const int x_index : IndexRange(verts_x)) {
float y = -size;