cairo multiply values with alpha channel included
<p>I want to achieve</p>

<pre><code>source.rgba * dest.rgba
</code></pre>

<p>with cairo. Is that possible without writing the loop manually? The multiplication operator still uses alpha-over, which is not the right thing.</p>

<p>One of the operands is a possibly rotated mask, and the other one is a shadow map that is not rotated. Here are the pictures. The mask will be visible if you open it in Gimp, where multiplication does exactly what I want.</p>

<p><a href="https://i.stack.imgur.com/HKPbY.png" rel="nofollow"><img src="https://i.stack.imgur.com/HKPbY.png" alt="White mask"></a> <a href="https://i.stack.imgur.com/3DBVP.png" rel="nofollow"><img src="https://i.stack.imgur.com/3DBVP.png" alt="Shadow map"></a> <a href="https://i.stack.imgur.com/t1iX0.png" rel="nofollow"><img src="https://i.stack.imgur.com/t1iX0.png" alt="Result"></a></p>