Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

how to connect ip camera to opencv python

import cv2

#print("Before URL")
cap = cv2.VideoCapture('rtsp://admin:123456@192.168.1.216/H264?ch=1&subtype=0')
#print("After URL")

while True:

    #print('About to start the Read command')
    ret, frame = cap.read()
    #print('About to show frame of Video.')
    cv2.imshow("Capturing",frame)
    #print('Running..')

    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

cap.release()
cv2.destroyAllWindows()
Comment

how to connect ip camera to opencv python

import cv2
import numpy as np

cap = cv2.VideoCapture(0)

while(True):
    ret, frame = cap.read()
    cv2.imshow('frame',frame)
    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

cap.release()
cv2.destroyAllWindows()
Comment

PREVIOUS NEXT
Code Example
Python :: convert to string except missing 
Python :: python ListObjectsV2 over 1000 
Python :: rename multiple value in column in pandas 
Python :: matplotlib facet scatter 
Python :: Overwrite text in python 
Python :: rmtree (remove tree) example 
Python :: using return values python script in batch script 
Python :: Count the number of Non-Missing Values in the DataFrame 
Python :: Function to stop a while loop 
Python :: Python Tkinter Scale Widget Syntax 
Python :: post to get 
Python :: Convert PySpark RDD to DataFrame 
Python :: choose what items on python 
Python :: when to register app in django 
Python :: immutabledict working 
Python :: How to convert string to uppercase, lowercase and how to swapcase in python 
Python :: operator overloading in python 
Python :: Sending Data in Unstructured File Form 
Python :: python code to executable online converter 
Python :: sum function in python 
Python :: checking time in time range 
Python :: python Access both key and value using iteritems() Return keys or values explicitly 
Python :: how to download a website using python 
Python :: spotify meist gespielte lieder sehen 
Python :: reopen closed file python 
Python :: draw networkx graph using plt.pause 
Python :: scatter plot actual vs predicted python 
Python :: load pandas dataframe with one row per line and 1 column no delimiter 
Python :: python matplotlib fullscreen zoom 
Python :: max value from multiple columns pandas 
ADD CONTENT
Topic
Content
Source link
Name
2+6 =