import cv2 as cv
import numpy as np

cap = cv.VideoCapture(1)

print(cap.get(cv.CAP_PROP_FRAME_WIDTH))
print(cap.get(cv.CAP_PROP_FRAME_HEIGHT))

cap.set(3,3000)
cap.set(4,3000)

print(cap.get(cv.CAP_PROP_FRAME_WIDTH))
print(cap.get(cv.CAP_PROP_FRAME_HEIGHT))

while (cap.isOpened()):
    ret , frame = cap.read()

    if (ret == True):
        cv.imshow("camVid", frame)
        if cv.waitKey(25) & 0xFF == ord('q'):
          break
    else:
        break

cap.release()
cv.destroyAllWindows()

[((4, 6, 4, 24), 'cv2.VideoCapture', 'cv.VideoCapture', ({(4, 22, 4, 23): '1'}, {}), '(1)', True, 'import cv2 as cv\n'), ((26, 0, 26, 22), 'cv2.destroyAllWindows', 'cv.destroyAllWindows', ({}, {}), '()', True, 'import cv2 as cv\n'), ((19, 8, 19, 34), 'cv2.imshow', 'cv.imshow', ({(19, 18, 19, 26): '"""camVid"""', (19, 28, 19, 33): 'frame'}, {}), "('camVid', frame)", True, 'import cv2 as cv\n'), ((20, 11, 20, 25), 'cv2.waitKey', 'cv.waitKey', ({(20, 22, 20, 24): '(25)'}, {}), '(25)', True, 'import cv2 as cv\n')]