I've been presented with a seemingly straightforward task in JavaScript that I'm not very familiar with. The challenge is to take an IP camera stream and display it on a three.js canvas.
To start, I came across an example that uses a webcam instead of an IP camera. You can see the example here:
In this example, there's a video tag that looks like this:
<video id="monitor" autoplay width="160" height="120" style="visibility: hidden; float:left;"></video>
Later on, it's referenced as follows:
video = document.getElementById( 'monitor' );
Despite my limited knowledge of JavaScript, I attempted to replace the call to the webcam with a call to an IP camera. In my attempt, I replaced the existing video tag with a new one:
<video controls src="http://[wowza-address]:1935/live/camera.stream/playlist.m3u8">
</video>
However, that change didn't yield the expected result. It seems like the process is more complex than I initially thought. Does anyone have any guidance or suggestions to help point me in the right direction?