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

[REG 5.2->5.4] Windows/Angle builds : no more support for float textures

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.5.0
    • 5.4.0 Beta
    • GUI: OpenGL
    • None
    • qt-opensource-windows-x86-msvc2013_64_opengl-5.4.0-beta_2014-10-01_10-00-08-30, MSVC2013, Windows 8.1 x64, Intel HD Graphics 4400
    • ef828b89abb436d3ea97fc6d433450be75b41c4b 279317b0673438a3ede3fe38d1c68c7f7ecc5c5f f29e4ef1a625151079e1c8c7f820efe0a8ee2a6d

    Description

      I used to have float32 textures working with Angle builds of Qt 5.2.
      This is not the case anymore with Qt 5.4, it shows up as black.

      Repro: open the opengl cube example from the 5.4 SDK, change initTextures() to the following:

      void MainWidget::initTextures()
      {
          QImage image(":/cube.png");
          QVector<float> dataRgba32(image.width()*image.height()*4);
          for(qint32 scan=0; scan<image.width()*image.height()*4; scan++)
              dataRgba32[scan]=float(image.bits()[scan])/255.f;
      
          texture=new QOpenGLTexture(QOpenGLTexture::Target2D);
          if(context()->isOpenGLES() && context()->format().majorVersion()<3)
              texture->setFormat(QOpenGLTexture::RGBAFormat);
          else
              texture->setFormat(QOpenGLTexture::RGBA32F);
          texture->setSize(image.width(),image.height());
          texture->allocateStorage();
          texture->setData(QOpenGLTexture::RGBA,QOpenGLTexture::Float32,dataRgba32.data());
      
          texture->setMinificationFilter(QOpenGLTexture::Linear);
          texture->setMagnificationFilter(QOpenGLTexture::Linear);
          texture->setWrapMode(QOpenGLTexture::Repeat);
      }
      

      Here's the log from Qt 5.2.0:
      GPU: Google Inc. / ANGLE (Intel(R) HD Graphics Family Direct3D9Ex vs_3_0 ps_3_0)
      OGL: OpenGL ES 2.0 (ANGLE 1.2.0.2446)

      and from Qt 5.4.0 beta:
      GPU: Google Inc. / ANGLE (Intel(R) HD Graphics Family Direct3D11 vs_5_0 ps_5_0)
      OGL: OpenGL ES 2.0 (ANGLE 2.1.abce76206141)

      NB: this works on the OpenGL builds. Just Angle builds are affected.

      Attachments

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

        Activity

          People

            peppe Giuseppe D'Angelo
            divide Robin Lobel
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes