Skip to content

Reduce compile time by removing geometry_3d.h include from rendering_server.h#115452

Merged
Repiteo merged 1 commit into
godotengine:masterfrom
Ivorforce:rendering-server-no-geometry
Jan 27, 2026
Merged

Reduce compile time by removing geometry_3d.h include from rendering_server.h#115452
Repiteo merged 1 commit into
godotengine:masterfrom
Ivorforce:rendering-server-no-geometry

Conversation

@Ivorforce

@Ivorforce Ivorforce commented Jan 27, 2026

Copy link
Copy Markdown
Member

The change reduces compile time, especially if geometry_3d.h or delauney_3d.h are edited.

I needed to change Geometry3D from class to namespace to make it happen, otherwise it would be impossible to forward-declare Geometry3D::MeshData. There are no further changes to this file (most of the changelog is whitespace).

This makes sense anyhow since Geometry3D does not need to be instantiated.

@Ivorforce Ivorforce added this to the 4.x milestone Jan 27, 2026
@Ivorforce Ivorforce requested review from a team as code owners January 27, 2026 14:12
@Ivorforce Ivorforce requested a review from a team as a code owner January 27, 2026 14:12
@Ivorforce Ivorforce requested a review from a team January 27, 2026 14:12
@Ivorforce Ivorforce requested a review from a team as a code owner January 27, 2026 14:12
@Ivorforce Ivorforce force-pushed the rendering-server-no-geometry branch from efd6b78 to 8e05fd3 Compare January 27, 2026 14:14
@Ivorforce Ivorforce requested review from a team and removed request for a team January 27, 2026 14:14

@clayjohn clayjohn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me. It looks like there are no class members or private functions or really any reason not to make Geometry3D a namespace.

The only thing that isn't clear to me on the face of the code is how this affects GDScript/GDExtension bindings/doc generation. Is there any reason to think that bindings may be impacted by this change?

@Ivorforce

Ivorforce commented Jan 27, 2026

Copy link
Copy Markdown
Member Author

The only thing that isn't clear to me on the face of the code is how this affects GDScript/GDExtension bindings/doc generation. Is there any reason to think that bindings may be impacted by this change?

Nope! Geometry3D is bound via CoreBind::Geometry3D, which is a separate class we don't use internally.
That means Geometry3D will continue to be a class in GDScript / godot-cpp / GDExtension.

Comment thread core/math/geometry_3d.h Outdated
@akien-mga akien-mga modified the milestones: 4.x, 4.7 Jan 27, 2026

@clayjohn clayjohn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds great! Thanks for the quick response

…pile time.

Change `Geometry3D` from class to namespace.
@Ivorforce Ivorforce force-pushed the rendering-server-no-geometry branch from 8e05fd3 to c56c297 Compare January 27, 2026 17:12
@Repiteo Repiteo merged commit c161d13 into godotengine:master Jan 27, 2026
20 checks passed
@Repiteo

Repiteo commented Jan 27, 2026

Copy link
Copy Markdown
Contributor

Thanks!

@Ivorforce Ivorforce deleted the rendering-server-no-geometry branch January 27, 2026 21:30
rivie13 pushed a commit to rivie13/Phoenix-Agentic-Engine that referenced this pull request Feb 16, 2026
…-no-geometry

Reduce compile time by removing `geometry_3d.h` include from `rendering_server.h`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment