-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Add support for multiple atlases to the CPU lightmapper (already implemented in 3.x
)
#2147
Comments
It should be doable, yes. I will take a look at it when I'm done with the more pressing issues :) |
This is exactly what I was hoping to see in new lightmaper in 3.3, unfortunately the way it currently works is kind of useless for actual projects with relatively large interior scenes. I understand that this approach is more complex but in the end this is the only correct way to do this. |
@KoxaKoxama To optimize frustum culling opportunities, you need to split the level into several meshes anyway. If your entire level is a single mesh, the level will always be rendered in full. Splitting each room into its own mesh is usually a good way to proceed for interior levels. For large open world scenes, you can split with a grid-based approach. |
Allowing for multiple atlases would be nice, and I added it to my backlog, but it's not very high priority, so I won't be working on it in the near future. If anyone wants to give it a go, I'm happy to give pointers on what needs to be changed and where :) In the meantime, remember that you can have multiple lightmaps in the same scene, so big scenes with multiple rooms can have one lightmap per room. Splitting big meshes into smaller ones also helps as @Calinou mentioned, and you All in all, I think this is a good feature to have, just not high priority right now. |
Any progress on multiple atlases? |
As far as I know, nobody has started on working on multiple atlas support yet. JFonS is currently busy with other tasks, so it's not likely to happen for 3.5. |
Here is the PR for this proposal: godotengine/godot#58102 I haven't tested it thoroughly, so any testing is welcome. |
This is now implemented by godotengine/godot#58102 in |
3.x
)
Forward ported to master by godotengine/godot#61861. |
Describe the project you are working on
Playing with the new lightmapper
Describe the problem or limitation you are having in your project
With large levels you cannot fit all objects on a single atlas this means you need to have 1 lightmap per object. in the tps demo this is over 1000 textures.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
It would be great if when atlas is enabled it would put as many textures in an atlas a possible then roll over to a new atlass texture once it can not fit anymore in the current one. This way you can have maybe 20 4k textures instead 1000s of small textures.
I think 20 4k textures would be more efficient than 1000 smaller textures but if they have equal efficiency then this proposal isn't as important.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
I described a bit how it should work above. I think this is always desirable so it should be always on. It could be made to be an option though
If this enhancement will not be used often, can it be worked around with a few lines of script?
No
Is there a reason why this should be core and not an add-on in the asset library?
Lightmapper is in core, as this is an enhancement to the lightmapper it would also need to be in core
The text was updated successfully, but these errors were encountered: