-
-
Notifications
You must be signed in to change notification settings - Fork 22.9k
Allow building the editor with 3D disabled, or without 3D Physics/Navigation. #105579
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
9b0dbd5
to
3f600da
Compare
I’m not sure I see the need for this. Why would you want to build the editor with 3D disabled? It doesn’t offer any real advantage for final projects, since those can already be built without 3D. This change just adds unnecessary checks in the editor code without a clear benefit. I’d recommend creating a proposal to clearly explain the motivation and potential benefits before moving forward with this PR. |
This is not just about removing 3D, it’s about giving developers more control over their tools, improving performance, and reducing unnecessary overhead when it’s not needed. |
@WhalesState this is a significant change, it needs a proper proposal. |
I understand your concerns, and I'd like to link the PR when it's finished to the proposal if no one ever proposed it. And it's not significant yet, just one more commit to allow building with |
For projects using C# but not 3D, it offers some advantages: the C# bindings are generated by the editor, which cannot disable 3D. This means C# will inevitably generate bindings related to 3D, leading to certain issues after export. For example, |
The C# side is something that should probably be fixed by other means rather than tweaking the editor, especially since you might want to build different versions of the bindings for different exports etc., and there's various other things you can't disable for the editor and that likely won't ever be possible to disable for the editor (like advanced UI) |
I can find a workaround for the advanced gui but it's not related to this change, we have a real issue that you just said it should be fixed, and soon it will :) |
See #103315 I agreed that this PR adds too much complexity and maintenance cost if the reason is just for C# bindings generation. The editor feature profile can already cover the need to disable certain editor features, and the pursuit of the minimum export template size doesn't need the editor stripped anyway. If anyone wishes to fix the C# bind-gen issue, I would recommend implementing such functionality directly in |
You shouldn't have to build the editor with all the different configurations you want for any specific export template, that's not really fixing any issue, so I think it's best to not focus on the C# bindings side and instead focus on the need and demand for this specific editor build (it's enough work to keep a few different export templates around for each platform + configuration) |
This PR is starting to attract some discussion and it's the exact reason, I wanted it to have a proposal attached. So, it can be discussed properly. |
Please do, I'm the less experienced one here and I'm just adding some |
You can then open the proposal in https://github.com/godotengine/godot-proposals and link it to this PR. |
Someone asked what benefits this PR would bring. I listed the C# example, but you guys said C# should use a better solution and not expect this PR. Hmm, alright, after all, I might be the only one here who's been troubled by that issue for months. |
This comment was marked as outdated.
This comment was marked as outdated.
Let's wait with any further discussion until we have a proposal to not bog this down in off topic |
Hello @aaronfranke, I resolved the requested changes five days ago. Could you please dismiss the review? You also can approve it but I don't expect it to be merged any where soon, Just let me know if there’s anything else needed. Thank you! |
If you want the files moved in the editor to be part of this change I'd suggest opening a separate PR as it's far more unlikely to get that merged in 4.6 and later given how disruptive it is, but the window for restructure in 4.5 as a follow-up to my restructure is still open, see: |
Thank you, I will open a PR with the last 4 files that are related to 3D, but for the 22 files related to physics gizmos I don't know if they should be changed now or to be kept inside this PR until the team gets time to review the changes. |
I'd say they have a very low chance of being approved for move once 4.5 is released, we prefer one noisy period, so I'd say either they should be moved now or not for a long while (a minor version at least, so not in 4.6) |
3084b6e
to
e16a335
Compare
@aaronfranke has been working towards this with the move to folders. So I think there is some interest from the other maintainers. I think that it isn't possible to disable 3d due to 3d rendering architecture but we can definitely disable code that is specially 3d related or 3d physics etc. |
Much thanks to all the Godot developers! I'd prefer to wait until the team has time to review it properly, and I’d really appreciate it if someone could co-author or collaborate on this. |
#include "scene/resources/animation.h" | ||
#include "scene/resources/mesh.h" | ||
#else | ||
#define Shape3D RefCounted |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer modern C++ using
to avoid polluting the global preprocessor namespace.
#define Shape3D RefCounted | |
using Shape3D = RefCounted; |
9b0b84c
to
0432d2c
Compare
4a4091a
to
5189f41
Compare
a7a65a0
to
8e33542
Compare
Allows building the editor using
disable_navigation_3d=yes
,disable_physics_3d=yes
ordisable_3d=yes
.I just have submitted my answers for Godot Community poll, noticing that the majority of Godot users focus on 2D games and GUI applications, but yet only 6% are recompiling the engine so I do agree that the cost is more the benefits, but it worth to be updated for those who needs it and until many users be familiar with building 2D templates.
Size Comparison: https://github.com/mounirtohami/godot/actions/runs/16565434882
