-
-
Notifications
You must be signed in to change notification settings - Fork 98
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
Default float=64 to be on (double precision emulation) #5610
Comments
I would appreciate this being the default, but I don't know if this is the right approach for the engine as a whole, yet it's totally possible that it could be. It's what Unreal 5 did (well, they made double-precision the only option). If the performance penalty is low, it might be worth it to default to this for official builds and then if someone is making a high-end game in a small space then they can choose to use single-precision instead. Also, even if we switch back later for release, it might be beneficial to get a large amount of users testing double-precision in beta. |
On the other hand, Unreal Engine 5 is not known for its support for low-end/mobile hardware and web platforms 🙂 There are still a lot of people using Godot to target low-end mobile, web platforms, and sometimes both at the same time. We should avoid making people pay for performance features they'll never see the benefit of. Feel free to create some benchmarks with physics and basic rendering1, but also make sure to benchmark it on mobile hardware and web platforms, not just desktop hardware. What we can do however is distribute official builds with double-precision enabled. These would not be the recommended option for most projects, but this would allow you to use double-precision physics without recompiling anything. Footnotes
|
PR review meeting: basically Calinou's comment, this would likely negatively impact more games than it would help due to physics, performance etc. |
PR review meeting:
|
This would be a good alternative to fix this enhancement and it will surface the extension bugs. |
As Calinou mentioned, distributing official 64 bit builds would be a good compromise, no? This really is the kind of feature that you either absolutely need or is completely useless (potentially even harmful). |
@Calandiel On the topic of combinatorial explosions, note that there isn't much of a point of producing 32-bit builds with double support. If you are targeting very old 32-bit systems you probably don't want to use doubles. Conversely, if you are using doubles you probably don't care about targeting very old 32-bit systems (note: there is one exception, WebAssembly, which is currently 32-bit only). So it would increase the amount of builds by 1.5x to have 32-bit arch & floats, 64-bit arch & floats, and 64-bit arch & doubles. |
Note that doing so will require modifying the editor's export dialog to support situations where not all architectures have a matching binary. I assume double-precision export templates use their own folder already (within the (This may have been done already, I haven't checked this for a while.) |
Describe the project you are working on
V-Sekai social virtual reality.
Describe the problem or limitation you are having in your project
We would like to use emulated doubles for unified grids in an open world. Like loading the multiple parts of the world but only transferring lod'ed network entities.
We would also like Godot Engine to be more user friendly and avoid two different default extension_api jsons.
If it's possible, I would request we emulate double support by default for 4.0. Enable emulate double support by default for 4.1 might be more difficult.
Emulating doubles came up in my discussion about why don't we enable emulate doubles by default for 4.1 or 4.0.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Enable float=double by default.
This would avoid two different json extension apis. tefusion/godot-subdiv#21 (Crash with float=64)
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Set float=64 by default in scons and build this for releases.
If this enhancement will not be used often, can it be worked around with a few lines of script?
Emulating double support is not a small script change. It is massively invasive and changes function signatures.
Is there a reason why this should be core and not an add-on in the asset library?
float=64 is a core feature.
The text was updated successfully, but these errors were encountered: