본문 바로가기

video screen effect 효과 반응형

반응형
<style>
.effect-div { width:100%; background-size:cover; overflow:hidden; position:relative; }
.effect-div video { width:100%; mix-blend-mode:screen; }
</style>
<div class=effect-div style="background-image:url('https://blog.kakaocdn.net/dn/eBj8M6/btryph8yOfm/1h3qjF9e1K9SnsKfdzLChk/img.jpg')">
<video src="https://v4.cdnpk.net/videvo_files/video/free/video0485/large_watermarked/_import_61b4426beee026.13798649_FPpreview.mp4" autoplay loop muted></video>
</div>
<script>
onresize = function() {
for (effect_div of document.getElementsByClassName("effect-div")) effect_div.style.height = effect_div.offsetWidth * 9 / 16 + "px";
}
onresize();
</script>

결과

반응형

'디자인소스' 카테고리의 다른 글

Placeholder 포커스시 감추기, 글자색 변경  (0) 2023.09.21
CSS3 Loader & Spinners 모음  (0) 2023.09.20
Glowing Pulse Search Form  (0) 2023.09.20
CSS3 Checkbox Styles  (0) 2023.09.19
Candy Color Button Animation  (0) 2023.09.19
CSS Button transitions  (0) 2023.09.19
제이쿼리 CSS Digital Clock  (0) 2023.09.19
youtube 반응형 플레이어  (0) 2023.09.19

댓글


Copyright ⓒ SmartWeb All rights reserved.