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

QRhi OpenGL backend does not destructure mat3 correctly

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Done
    • Affects Version/s: 5.14, 5.15
    • Fix Version/s: 5.15.0 Alpha
    • Component/s: Qt RHI
    • Labels:
      None
    • Commits:
      53804f553d446c962764ba3365a8b390436fceb4 (qt/qtbase/5.15)

      Description

      In a uniform buffer a mat3 has 4 floats per column (or row, if row-major), even though only 3 is used and the 4th is ignored. So 12 floats altogether, not 9.

      The OpenGL backend should take this into account when destructuring a uniform buffer and issuing individual glUniform* (e.g. glUniformMatrix3fv) calls. Otherwise shaders will work with invalid normal matrices (the typical mat3), in Qt Quick 3D for instance.

        Attachments

          Issue Links

          For Gerrit Dashboard: QTBUG-80655
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              lagocs Laszlo Agocs
              Reporter:
              lagocs Laszlo Agocs
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes