Closed micahstubbs closed 7 years ago
Oh yeah, this is kind of confusing.
So the PhantomJS script (runner.js
) actually creates its own server on port 8888
to listen for user events eg click/navigate which the browser will forward to it once I get that part working. (For now I've been curling... curl http://localhost:8888 -d '{ "type": "click", "x": 25, "y": 30 }'
.
The shell script with ports 8082
and 8084
is the script borrowed from jsmpeg which Phantom streams its output to (see scripts/phantom-ffmpeg-stream.sh
) on port 8082
. This then sends the mpeg data to the browser via a Websocket on port 8084
.
You shouldn't need to worry about the details of this script or ports 8082/4 much unless you need to change the IP from 127.0.01
to your network IP.
thanks for explaining what's happening!
the docs say port
8888
https://github.com/cjroth/aframe-phantomjs-continuous-streaming/blob/master/README.md#runbut the shell script seems to use ports
8082
and8084
https://github.com/cjroth/aframe-phantomjs-continuous-streaming/blob/master/stream-server.js#L13would be nice to clarify the docs 😄