I’m writing an Android app where device 1 connects to device 2 through a socket and starts streaming live video to it. In this situation, who is the server and who is the client?
In my app, device 2 would be listening for a connection. Once it accepts(), device 1 streams video to device2.
What I am asking is where does the ServerSocket go and where does the regular Socket go?
ServerSocket should go on Device 1 (Server), Device 2 (Client) would consume the video.
Heres an examples:
http://www.exampledepot.com/egs/java.net/CreateClientSocket.html