import numpy as np
import cv2
cap = cv2.VideoCapture(0) # ๋
ธํธ๋ถ ์น์บ ์ ์นด๋ฉ๋ผ๋ก ์ฌ์ฉ
cap.set(3, 640) # ๋๋น
cap.set(4, 480) # ๋์ด
ret, frame = cap.read() # ์ฌ์ง ์ดฌ์
frame = cv2.flip(frame, 1) # ์ข์ฐ ๋์นญ
cv2.imwrite('./test.png', frame) # ์ฌ์ง ์ ์ฅ
cap.release()
cv2.destroyAllWindows()
'๐ > capstone1' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
์ฝ๋ฉ ์ฐ๊ฒฐ ์ ์ง (colab ๋ฐํ์ ์ ์ง) (0) | 2022.04.21 |
---|---|
Google Colaboratory ์ด์ฉํ YOLOv5 ๋ฐ์ดํฐ ํ์ต (3) | 2022.04.07 |
labelImg ์ด์ฉํด์ ๋ฐ์ดํฐ ๋ง๋ค๊ณ YOLOv5 ํ์ต์ํค๊ธฐ (0) | 2022.04.01 |
MacOS M1 - labelImg ์ค์น (0) | 2022.03.30 |
YOLOv5 ์ค์น (4) | 2022.03.24 |