Reputation: 2889
I need some help with the below:
Ok the scenario is this: I am contacting a server and from the server I am getting this URI:
http://<camera_ip_address>/<type_ID>/<part_ID>
The documentation of this webservice says:
"The part_ID will vary from part_start and part_end."
I got all the data needed. Now what I dont get is how this is related to HTTP video streaming?
If I have part_start = 1 and part_end = 10, that means that I will "download" 10 frames? How? with curl? wget? Rails?
Should a loop be implemented like (example):
for i=1; i<10 i++
download "http://127.0.0.1/34/i"
end
What will "http://127.0.0.1/34/10" for example be? a png/jpeg frame file? Any help will be very useful. Thanks very much.
Upvotes: 0
Views: 617
Reputation: 5880
well, rails isn't really relevant here.
It looks like you just need to utilize some flash player here, one of the most popular ones is jwplayer
See the SWFOBJECT section. basically, you have to do something like:
<script type="text/javascript">
var flashvars = { file:'http://<camera_ip_address>/<type_ID>/',autostart:'true' };
var params = { allowfullscreen:'true', allowscriptaccess:'always' };
var attributes = { id:'player1', name:'player1' };
swfobject.embedSWF('player.swf','container1','480','270','9.0.115','false',
flashvars, params, attributes);
</script>
Upvotes: 2