I need to record a webcam from a house desktop pc (a simple usb webcam) and streaming it in a website, allowing people visiting the website to interact with a chat which will be visible from both website and transmission pc (the one with the webcam put on).
The pc with the webcam which will transmit the images is linked across the internet with a 384 kbps upstreaming connection (Adsl) so this should be sufficient for the transmission to a single machine (I think).
My idea was to use an intermediate server (with a fixed ip and at least 4-5 Mbps flatband) which would grab the webcam images and transmit it to the various website surfers. The website should be using a flash applet connecting to the server where a C++ program would accept connections, send data, and get data back regarding the chat.
Now regarding the C++ program, should it open multiple ports (one for every client connecting) or what? I've never worked with multiple streaming clients (if you have suggestions about a great guide to start with I'd appreciate it very much, I'm just willingful to learn).
Can someone please provide me a good point to start?
Are you sure it is possible to to make connections from a Flash applet to anything but the webserver from which it was loaded? I would not expect that.
I would consider using a CGI of FastCGI program, or maybe even use something like http://www.red5.org/.
Thank you for you answer, you're right I suppose but I'm new to this topic and I can't figure out how to realize such a system. A server is needed (I'm sure of this), but how does the website connect and visualize audio/video streams?
I can't use flash well so I just skipped the flash part thinking "i'll find a way about it". I looked at your link too, but I don't think it's what I need (and a lot of documentation is lacking like the forum link)
Well, I'm far from an expert on video streaming, but here is what I think you should consider:
If you are going to use a webbrowser for video recording and playback (which is what I hear you saying), then you are essentially going to choose one of the following client platforms:
1) Flash plugin
2) Java plugin
3) HTML 5 (has playback, but I'm not sure about recording)
Depending on your choice of client platform, you will have a number of possible video streaming protocols to choose between. (alternatively, if you choose Java, you will probably be free to create your own custom protocol, if you should desire that).
Anyway, you would then want to establish a connection from the browser to the webserver.
The normal choice for a webserver is Apache, and you can then run your own custom code by means of one of the extension modules. modcgi (C/C++), modjk+Tomcat (Java), etc. (alternatively you can implement your own custom webserver).
Given you choice of server side platform, you will be faced with a choice of either using a library that handles the video streaming protocol, or to code that part yourself.
Doing it all from scratch would be a lot of fun, no doubt, but also extremely labourous.
Honestly, I think you should take another look at Red5, my guess is that it does pretty much what you want. I agree that it is poorly documented, but there are a number of working examples.