我做了这样的设计
如何使用CSS遮罩背景?
我尝试了以下代码:
我使用的遮罩图像是:
我尝试了以下代码:
.img-poster {
display: block;
max-width: 100%;
-webkit-mask-image: url(https://cdn.pbrd.co/images/GYiCod1.png), url(https://cdn.pbrd.co/images/GYiCQsM.png);
-webkit-mask-position: bottom center, center center;
-webkit-mask-repeat: no-repeat, no-repeat;
}
.add {
-webkit-mask-composite: add;
}
<section class="section poster-container">
<img src="https://imagejournal.org/wp-content/uploads/bb-plugin/cache/23466317216_b99485ba14_o-panorama.jpg" alt="" class="img-poster add img-responsive">
</section>
https://istack.dev59.com/fg2k5.webp
https://istack.dev59.com/zmylJ.webp
你们能告诉我代码中有什么问题吗?我知道可以直接导入png,但我尝试使用css