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

QRhi GL backend should handle basic structs and arrays of struct in a uniform block

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Done
    • Icon: P2: Important P2: Important
    • 5.15.0 Alpha
    • None
    • Qt RHI
    • None
    • e6de661a8aa96b5905ea7ba4cd5d76bd06da3f93 (qt/qtbase/5.15)

      Needed for Quick3D.

      With uniform blocks disabled in the output (SPIRV-Cross), the following

      struct LightSource
      {
          vec4  position;
          ...
      };
      
      layout (std140, binding = 1) uniform cbBufferLights
      {
          int uNumLights;
          LightSource lights[MAX_NUM_LIGHTS];
      };
      

      translates to

      struct LightSource {
          vec4 position;
          ...
      }
      
      struct cbBufferLights {
          int uNumLights;
          LightSource lights[16];
      };
      
      uniform cbBufferLights _N;
      

      which means the decomposition of uniform buffers to plain uniforms must be able to deal with at least a simple array of struct.

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

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

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes