In my website there is page with many videos. The videos should autoplay when the iframe video is completely visible in the viewport. When the videos move above the viewport means, the video should pause as we are seeing in facebook.

**Note:** I'm using `iframe`, but not `html5` video element.