I have an png image that is triangle shaped , i need this image to be more dark , i get the job done using another div with opacity 0.5 that covers it e.g
<div class ="cover_photo">
<div class ="overlay"></div>
</div>
.overlay {
background-color: #322D36 ;
bottom: 0;
left: 0;
opacity: 0.5;
position: absolute;
right: 0;
top: 0;
z-index: 1;
}
the cover_photo has said img set as background , but using this , the color from overlay will be seen on whole div , not just on the image and thas not what i want. Is there a way how to darken an image? I know about filter css property but none of them actually darken the image. Is tehre any way to achieve it?