Skip to content
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

Cache VoxelGrid meshing results (RenderMesh) #1414

Open
RiscadoA opened this issue Dec 16, 2024 · 0 comments
Open

Cache VoxelGrid meshing results (RenderMesh) #1414

RiscadoA opened this issue Dec 16, 2024 · 0 comments
Labels
A-Engine B-Assets B-Rendering D-Good-First-Issue Easy but interesting P-Backlog This issue isn't a priority at all S-Blocked Blocked on another issue or PR

Comments

@RiscadoA
Copy link
Member

Problem

Currently we always mesh voxel grid assets which are stored in the disk.
When shipping a game, this doesn't seem to make much sense, as it could have been already distributed as a mesh, instead of a voxel grid (or both).
In big samples/demos, this actually leads to a very slow startup, as meshing is a quite expensive algorithm.

Solution

With #1413, it would be trivial to solve this problem. We could simply change the RenderMeshBridge to check if there's a .mesh file, and use if it so. The save method could write the tesselated mesh into the .mesh file. Thus, when deploying games, if we want faster loads, we could simply save all render meshes into the assets directory by calling Assets::save on them.

@RiscadoA RiscadoA added A-Engine B-Assets B-Rendering D-Good-First-Issue Easy but interesting S-Blocked Blocked on another issue or PR P-Backlog This issue isn't a priority at all labels Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Engine B-Assets B-Rendering D-Good-First-Issue Easy but interesting P-Backlog This issue isn't a priority at all S-Blocked Blocked on another issue or PR
Projects
None yet
Development

No branches or pull requests

1 participant