Cannot access webcam with opencv2 in python

Hi,

cap = cv2.VideoCapture(0)

Please input the corresponding pipeline instead of 0.
You can find some examples below:

Thanks.