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

layer.smooth is ignored

    XMLWordPrintable

Details

    • 6f02d6fc56551cac309235ba920e062c0a465e1a

    Description

      I'm trying to apply a graphical effect to an image that should not be smoothly scaled (hence smooth: false. I see that when an effect is assigned and layer.enabled is set to true, the image is smoothly scaled, regardless of whether layer.smooth is set to true or not.

      Here's an example of an effect that should have no visual impact on the image whatsoever, yet it turns out blurry:

      import QtQuick 2.9
      import QtQuick.Controls 2.3
      import QtGraphicalEffects 1.0
      
      ApplicationWindow {
          width: 800
          height: 800
          visible: true
      
          Image {
              id: root
              source: "http://upload.wikimedia.org/wikipedia/commons/f/f0/Pixelart-tv-iso.png"
              smooth: false
              scale: 16
              anchors.centerIn: parent
      
              layer.enabled: true
              layer.smooth: false
              layer.effect: ColorOverlay {
                  anchors.fill: root
                  source: root
                  color: "#00000000"
              }
          }
      }
      

      http://doc.qt.io/qt-5/qml-qtquick-item.html#layer.smooth-prop says:

      Holds whether the layer is smoothly transformed.

      I believe that this means that it should have the same visual result as Item::smooth.

      Attachments

        1. after-patch.png
          90 kB
          Mitch Curtis
        2. before-patch.png
          145 kB
          Mitch Curtis
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            mitch_curtis Mitch Curtis
            mitch_curtis Mitch Curtis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes