I have a gallery of images with the ratio forced (like this) and for some reason the images flicker when you scale them with transform. I have tried both "-webkit-transform-style: preserve-3d" and "-webkit-backface-visibility: hidden" but it didnt fix it. It seems that it only happens in chrome.
Live version with one image where you can see that the lines of the bricks flicker(chrome): https://codepen.io/Nanetten/pen/boRQVE
<div class="grid-item grid-item--width6">
<div class="item">
<div class="outer half">
<div class="inner"><img src="https://image.ibb.co/fOAxqb/1.jpg" alt="test"></div>
</div>
</div>
* {
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
body {
margin: 0;
}
.item {
display: inline-block;
width: 100%;
max-width: 100%;
overflow: hidden;
-webkit-transition: all .1s ease-in-out;
-o-transition: all .1s ease-in-out;
transition: all .1s ease-in-out;
}
.item .outer {
position: relative;
height: 0;
}
.item .inner {
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
}
.item img {
width: 100%;
height: 100%;
transition: all .5s ease-out;
display: block;
}
.item img:hover {
-webkit-transform: scale(1.15);
-ms-transform: scale(1.15);
transform: scale(1.15);
}
.half {
padding-top: calc(50%);
}
.grid-item {
float: left;
display: block;
margin: 5px;
}
.grid-item--width6 {
width: calc(50% - 10px);
}
Thanks for your help.