I'm trying to use a PlasmaCore.IconItem as the MaskSource for a MaskedBlur. Instead of the icon's visible alpha channel acting as a mask as desired, the whole thing appears opaque so there is no mask. The same happens more trivially using just `source:` For example: Image { id: imageFromIcon source: icon anchors.fill: icon } PlasmaCore.IconItem { id: icon visible: false icon.source: "preferences-desktop-color" } imageFromIcon will be invisible rather than a QML Image representation of the icon. This is currently blocking the blur component of https://phabricator.kde.org/D16031
Relevant API to do it natively is QSGTextureProvider *QQuickItem::textureProvider() const Never done it before, but it doesn't seem too difficult. We generate QSGTextures elsewhere in that same code; we just need to make this interim class. But in any case, what you're looking for is ShaderEffectSource which will work for any item(s). Not as performant as the above as it effectively renders then captures the content, but it's fine for small cases.
ShaderEffectSource was just what I needed, thanks! ShaderEffectSource { id: renderedIcon visible: false sourceItem: icon }