You can use the CSS clip-path property to display the video section.
You will need to define the built-in svg clipPath element, add a path element with coordinates, give clipPath id and use them in your CSS for the video clip ( clip-path: url(#id) ).
HTML:
<iframe id="clip-1" width="852" height="480" src="//www.youtube.com/embed/nGt_JGHYEO4" frameborder="0" allowfullscreen></iframe> <iframe id="clip-2" width="852" height="480" src="//www.youtube.com/embed/nGt_JGHYEO4" frameborder="0" allowfullscreen></iframe> <iframe id="clip-3" width="852" height="480" src="//www.youtube.com/embed/nGt_JGHYEO4" frameborder="0" allowfullscreen></iframe> <iframe id="clip-4" width="852" height="480" src="//www.youtube.com/embed/nGt_JGHYEO4" frameborder="0" allowfullscreen></iframe> <svg> <defs> <clipPath id="one"> <path d="M0,0 L640,0 L640,480 L0,480z" /> </clipPath> <clipPath id="two"> <path d="M212,0 L852,0 L852,480 L212,480z" /> </clipPath> <clipPath id="three"> <path d="M106,0 746,0 746,480 106,480z" /> </clipPath> <clipPath id="four"> <path d="M212,140 532,140 532,380 212,380z" /> </clipPath> </defs> </svg>
CSS
#clip-1 { position: absolute; -webkit-clip-path: url(#one); clip-path: url(#one); } #clip-2 { position: absolute; top: 480px; -webkit-clip-path: url(#two); clip-path: url(#two); } #clip-3 { position: absolute; top: 960px; -webkit-clip-path: url(#three); clip-path: url(#three); } #clip-4 { position: absolute; top: 1440px; -webkit-clip-path: url(#four); clip-path: url(#four); } body { margin: 0 auto; }
source share