views:

43

answers:

1

For example look at ninjavideo's divx player source. It is this:

src="http://127.0.0.1:64651/nv/47244"

How do they use the java applet to output the src as a divx readable file?

Source: http://beta.ninjavideo.net/video/47244 Warning: You will need to allow java applet

+1  A: 

It's not "masked" it's just running as a local HTTP proxy. It downloads the file from a HttpURLConnection and listens locally for connections and serves up the video. Here's a (not so great) example: http://stackoverflow.com/questions/1262007/please-help-me-figure-out-whats-wrong-with-this-web-proxy-code/1291686

Ry4an
So that means this url: http://127.0.0.1:64651/nv/47244 outputs a string containing a location to a video file? such as "http://videoserver.com/videos/demo.avi" ?using the command out.write ? I don't know much about java. Can you please point me further to a place where they cover this aspect of writing java applets? Thanks a lot
ninja123
No it's a http proxy. It emits the actual video data. The applet is both a web browser and a webserver all by it self. It downloads the video from the actual location and then serves it back up to the media player. Follow the link to thank other question for sample code.
Ry4an