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

DropShadow renders differntly in 6.4.x

    XMLWordPrintable

Details

    Description

      The DropShadow of Qt5Compat.Graphical effects look the same in Qt 5 and 6 up to version 6.3.2. But starting with 6.4.beta, the shadow is bigger and "pixelated"... see attachments.

      Here is the code to produce it:

      // Qt 5
      //import QtQuick 2.15
      //import QtQuick.Window 2.15
      //import QtGraphicalEffects 1.15
      
      // Qt 6
      import QtQuick
      import QtQuick.Window
      import Qt5Compat.GraphicalEffects
      
      Window {
          width: 640
          height: 480
          visible: true
          title: 'Shadow'
      
          Rectangle {
              id: card
              width: 100
              height: 100
              anchors.centerIn: parent
              color: '#F5F5F5'
              radius: 12
          }
      
          Item {
              anchors.fill: card
      
              DropShadow {
                  id: layer3
                  source: card
                  radius: 32
                  verticalOffset: 20
                  color: Qt.rgba(102 / 255, 102 / 255, 102 / 255, 0.32)
                  transparentBorder: true
                  anchors.fill: parent
                  spread: 0
              }
          }
      }
      

      Attachments

        1. foo.png
          foo.png
          15 kB
        2. shadowbox.tgz
          2 kB

        Activity

          People

            qt.team.graphics.and.multimedia Qt Graphics Team
            moerkb Markus Bader
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: