Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-113164

Crash when you have two models with same mesh in the scene, one with BakedLightmap and one without

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 6.5.4, 6.6.1, 6.7.0 FF
    • 6.5.1
    • Quick: 3D
    • None
    • 9dba9d7f5 (dev), 964da0807 (6.5), 450850498 (6.6)

    Description

      If you have two models with same mesh (e.g. "#Cube") in the same scene, and one model has BakedLightmap specified and one doesn't, this can crash depending on the order of the models in the scene, if the baking is not yet done and thus the baked mesh with UVs doesn't yet exist.

      My guess is that the problem is related to QSSGBufferManager::loadRenderMesh. If non-baked model is loaded first, and then the baking-enabled model, those loads have different options but same mesh, so the regularly loaded mesh is released and replaced with baking-enabled mesh. However, since we haven't baked yet, this somehow corrupts the mesh for the non-baked model:

      Debug trace: QSSGLayerRenderData::prepareModelForRender , theMesh->subsets.size()= 2333695256432

      This is an issue for QDS, where puppet can crash while you are setting up the baking properties for the scene before baking.

      See attached standalone example, running it will result in crash.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              inho Inho Lee
              e0348803 Miikka Heikkinen
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes