virtucamera.VCBase Server Feedback Methods - shycats/PyVirtuCamera GitHub Wiki


client_connected( vcserver, client_ip, client_port )
Optional, this method is called whenever a client app
connects to the server. Usefull to give the user
feedback about a successfull connection.

Parameters
----------
vcserver : virtucamera.VCServer object
    Instance of virtucamera.VCServer calling this method.
client_ip : str
    ip address of the remote client
client_port : int
    port number of the remote client
client_disconnected( vcserver )
Optional, this method is called whenever a client app
disconnects from the server, even if it's disconnected by calling
stop_serving() with the virtucamera.VCServer API. Usefull to give
the user feedback about the disconnection.

Parameters
----------
vcserver : virtucamera.VCServer object
    Instance of virtucamera.VCServer calling this method.
current_camera_changed( vcserver, current_camera )
Optional, this method is called when the user selects
a different camera from the app. Usefull to give the user
feedback about the currently selected camera.

Parameters
----------
vcserver : virtucamera.VCServer object
    Instance of virtucamera.VCServer calling this method.
current_camera : str
    Name of the new selected camera
server_did_stop( vcserver )
Optional, calling stop_serving() on virtucamera.VCServer
doesn't instantly stop the server, it is done in the background
due to the asyncronous nature of some of its processes.
This method is called when all services have been completely
stopped.

Parameters
----------
vcserver : virtucamera.VCServer object
    Instance of virtucamera.VCServer calling this method.

Related: VCServer.stop_serving()