0
import numpy as np
import cv2

#holder for the camera object
cap = cv2.VideoCapture(0)


while(True):

    # Capture frame-by-frame
    ret, frame = cap.read()

    # Our operations on the frame come here (color)
    color = cv2.cvtColor(frame, 1)

    # Display the frame
    cv2.imshow('LiveCam',color)
    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

'''When everything done, release the capture'''
cap.release()
cv2.destroyAllWindows()

This code will display my own live frames on my own screen. I want to send my live frames to another computer,and to receive the other's computer own live in order to display it. Can I get some help please?

Ishara Madhawa
  • 3,549
  • 5
  • 24
  • 42
Guy Cohen
  • 1
  • 1
  • Your question is a bit underspecced. I think it'll probably be voted down the way it is now. Why can't you just use off-the-shelf software like VLC or even Google Hangouts? – sneep Apr 29 '18 at 09:13
  • because it is a PYTHON project for school.. – Guy Cohen Apr 29 '18 at 10:37
  • Well, surely your assignment has rules about what you can and can't do, and perhaps you even had pointers on what libraries etc. to use? I'm not sure if I should post this link or not, but here's a solution to pretty much the exact same problem: https://stackoverflow.com/questions/30988033/sending-live-video-frame-over-network-in-python-opencv – sneep Apr 29 '18 at 15:40

0 Answers0