Hard Light Productions Forums

Off-Topic Discussion => General Discussion => Topic started by: Sandwich on April 18, 2007, 06:14:00 am

Title: Looking for a webcam script
Post by: Sandwich on April 18, 2007, 06:14:00 am
OK, the place where I work got a "webcam" of sorts (it's actually a networked security camera). They want to use it as a proper webcam, but there's one problem: when the camera uploads images to a specified directory, it creates subfolders based on the date, and names the JPG files based on the time. :-/ So I can't just put one JPG filename into a webpage and have the page refresh every 5 seconds or anything.

Does anyone know of a script of some sort, be it Flash, Java/Javascript, or whatever, that is able to deal with this kind of situation (constantly changing filenames)? Preferably it would also be able to delete the previous day's folder of images.

If it helps any, here's a sample of the directory structure the camera creates:



[attachment deleted by admin]
Title: Re: Looking for a webcam script
Post by: Descenterace on April 18, 2007, 11:20:12 pm
Looks like you need a webservice which returns the latest image, an IMG tag pointing to said service, and Javascript that refreshes the page every X seconds.