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

4xMSAA doesn't work with Mali400 using Lima driver

    XMLWordPrintable

Details

    • Linux/Yocto
    • 520d755d3 (dev), 149da3331 (6.7), 4601674da (6.6), abad945c7 (tqtc/lts-6.5)

    Description

      If I understand correctly: recently, the open source Lima driver for the ARM Mali400 (codename Utgard) was updated to include support for 4x multisampling antialiasing (see https://cgit.freedesktop.org/mesa/mesa/commit/?id=24be0119016f6181f5a39e6405f17ad199bd695c) which was released in September 2022 (see https://docs.mesa3d.org/relnotes/22.2.0.html).

       

      In a project which uses this driver and an Allwinner sun7i (A20) board with a Mali400, attempting to use 4xMSAA with any of the following:

      // prior to calling window->show() or window->showFullscreen()
      QSurfaceFormat format = window->format();
      format.setSamples(4);
      window->setFormat(format);
      
      OR
      
      // prior to constructing the QGuiApplication instance
      QSurfaceFormat defaultFormat = QSurfaceFormat::defaultSurfaceFormat();
      defaultFormat.setSamples(4);
      QSurfaceFormat::setDefaultFormat(defaultFormat);
      
      OR
      
      QSG_SAMPLES=4 ./myapplication

      results in Qt complaining:

      Requested MSAA sample count 4 but supported sample counts are QList(1), using sample count 1 instead 

       

      I did a very small amount of digging and found in qrhigles2.cpp:

      caps.msaaRenderBuffer = f->hasOpenGLExtension(
              QOpenGLExtensions::FramebufferMultisample)
          && f->hasOpenGLExtension(
              QOpenGLExtensions::FramebufferBlit);

       

      So I can only assume that either the driver isn't reporting one of these properly, or the way Qt is determining feature support needs to be adjusted for Mesa drivers?

       

       

      I assume this bug will be considered low priority since the hardware being used is quite old.  But Mali400 is extremely popular, so would be nice if this were supported out of the box with the new Lima driver.

      Attachments

        Issue Links

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

          Activity

            People

              lagocs Laszlo Agocs
              chrisadams Christopher Adams
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes