Piping pi's opencv video to ffmpeg for Youtube streaming
问题 This is a small python3 script reading off picam using OpenCV : #picamStream.py import sys, os from picamera.array import PiRGBArray from picamera import PiCamera import time import cv2 # initialize the camera and grab a reference to the raw camera capture camera = PiCamera() camera.resolution = (960, 540) camera.framerate = 30 rawCapture = PiRGBArray(camera, size=(960, 540)) # allow the camera to warmup time.sleep(0.1) # capture frames from the camera for frame in camera.capture_continuous