Video recorded through OpenCV not loading on html

I am recording videos with the help of OpenCV. Now after the video is saved, I am trying to load that video into HTML, with the help of video and iframe tags, but it is not loading in either of the tags. I have saved the video in .avi/.mp4 format. Locally in VLC the videos are playing fine, but are not loading in HTML.
For recording video with openCV, I have referred to :

Answers: 0