I made this effect with two divs using z-index.
<div class="picture-wrapper"> <div class="mask"> </div> <div class="picture"> <img src="" /> </div> </div>
Set the background image on the mask to the red borders using middle cut (png), then use z-index to place it above the image separator.
A cross browser should work, the only thing that it does not take into account the dynamic width / height of the images, it assumes that all the images are the same. And you make a request for this additional mask image.
To you.
Christopher marshall
source share