I’m trying to tile an image with an alpha channel over a background image. The image is mostly transparent, as it contains only the shadow details of a button shape. I thought it would be convenient to use an ImageBrush rather than repeatedly calling drawImage. My problem is that I don’t understand the contribution of the current color (which set to transparent black).
When I use drawImage with the same source image, I get the expected result, but if I do fillAll or fillPath using an ImageBrush created from the image, this results in what appears to be transparent white filling the brushed area, and my image on top of that.
Here’s a code snippet (this is in an override of LookAndFeel::drawButtonBackground):
Confusingly, if I call setColour after setBrush, I get an entirely black rectangle! Is this expected behavior?
Thanks in advance for any insights.