Skip to content

Vulkan: LightmapGI does not take MultiMeshes into account for baking #56027

Open
@Calinou

Description

Related to #56024 which is for VoxelGI.

Godot version

4.0.dev (1cbf394)

System information

Fedora 34, GeForce GTX 1080 (NVIDIA 470.74)

Issue description

Similar to #48909, but with the new lightmap GI implementation in master.

LightmapGI does not take MultiMeshes into account for baking. On the left, you can clearly notice the indirect lighting, but it's completely missing on the right:

Left: Individual MeshInstances, right: MultiMeshInstance:

2021-12-17_18 09 28

Steps to reproduce

Note: An imported 3D scene with UV2 generated must be used. You cannot use primitive meshes for testing this, as they do not contain a UV2 layer and it can't be generated using the MeshInstance tools. The minimal reproduction project includes a ready-to-use setup for testing this.

  • Import a 3D scene with Static Lightmaps bake mode. Click Advanced in the import dock, go to the Meshes tab and enable Save to File. Specify a path to a .tres file to save.
  • Add a MeshInstance3D node with the mesh resource loaded to act as a floor. Scale it so it can fit several objects on top. Set the global illumination mode to Baked in the inspector.
  • Add a MeshInstance3D node with the mesh resource loaded to act as a source mesh for the MultiMesh. Set the global illumination mode to Baked in the inspector.
  • Add a MultiMeshInstance3D node. Use the menu at the top of the 3D editor viewport to populate the MultiMeshInstance with BoxMeshes.
  • Add a LightmapGI, select it and click Bake at the top of the 3D editor viewport.

Minimal reproduction project

test_lightmapgi_multimesh.zip

Old MRPs

test_lightmapgi_multimesh.zip

With .godot/ included to workaround importing issue: test_lightmapgi_multimesh_1.zip

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status

      Up for grabs

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions