Ejemplo n.º 1
0
def eventsource_request_sent(session, result, _data):
    print("request sent")
    input_stream = session.send_finish(result)
    if input_stream:
        data_input_stream = Gio.DataInputStream.new(input_stream)
        read_eventstream_line(data_input_stream)
    else:
        print("error")
        Owr.quit()
Ejemplo n.º 2
0
def reset():
    global LOCAL_SOURCES, TRANSPORT_AGENT, ALL_SESSIONS
    print("Reset")
    for session, session_data in ALL_SESSIONS:
        session.set_send_source(None)
    ALL_SESSIONS = []
    TRANSPORT_AGENT = None
    LOCAL_SOURCES = []
    Owr.get_capture_sources(Owr.MediaType.VIDEO, got_local_sources)
Ejemplo n.º 3
0
def eventsource_request_sent(session, result, _data):
    print("request sent")
    input_stream = session.send_finish(result)
    if input_stream:
        data_input_stream = Gio.DataInputStream.new(input_stream)
        read_eventstream_line(data_input_stream)
    else:
        print("error")
        Owr.quit()
Ejemplo n.º 4
0
def reset():
    global LOCAL_SOURCES, TRANSPORT_AGENT, ALL_SESSIONS
    print("Reset")
    for session, session_data in ALL_SESSIONS:
        session.set_send_source(None)
    ALL_SESSIONS = []
    TRANSPORT_AGENT = None
    LOCAL_SOURCES = []
    Owr.get_capture_sources(Owr.MediaType.VIDEO, got_local_sources)
Ejemplo n.º 5
0
def main():
    mc = GLib.MainContext.get_thread_default()
    if not mc:
        mc = GLib.MainContext.default()
    Owr.init(mc)
    Owr.get_capture_sources(Owr.MediaType.VIDEO, got_local_sources)
    Owr.run()
    print("exiting")
Ejemplo n.º 6
0
def main():
    mc = GLib.MainContext.get_thread_default()
    if not mc:
        mc = GLib.MainContext.default()
    Owr.init(mc)
    Owr.get_capture_sources(Owr.MediaType.VIDEO, got_local_sources)
    Owr.run()
    print("exiting")