Hi,
I’m developing a space sim, and I’m trying to build a 1:1 scale environment using large worlds.
Using 1:1 scale is a non-negotiable requirement
Everything works fine, planet placement, movement, skybox.
For visual effect, I’d like to improve the standard lens flare, especially for the main star of the solar system.
I see that this is usually done by using certain (complex) materials, for example in this package found on the marketplace: https://www.unrealengine.com/marketplace/en-US/product/lens-flares
The custom lens flares in this package work perfectly… until a certain distance.
They seem to work for about 100km or so, which is a perfectly adequate distance for most games, but for large worlds this does not work at all.
This issue is a limitation of the engine. It is confirmed also by the author of the package (see the “Questions” section).
I don’t know which material functions are the limiting factor, but likely some functions are using still 32bit floats instead of 64bit doubles. I tried to play around with the material, but with no luck.
I would need these lens flares to work for an infinite distance.
I tried to fake the effect by placing the lens flare attached to a movable object in between the player camera and the star, but the distances are so great that this object takes a non-zero time to update in the correct position, causing the effect to look very silly
I did not try particles yet, but they should have the same issue. The underlying material would not get visualized at far distance.
So the question is: how to make a custom lens flare when using Large Worlds?
Thanks for any input!