We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6897fc4 commit 858c146Copy full SHA for 858c146
programming/sr/vision/index.md
@@ -71,6 +71,24 @@ R = Robot()
71
marker_ids = R.camera.save(R.usbkey / "initial-view.png")
72
~~~~~
73
74
+capture
75
+: Take a photo through the webcam, and return the image data as an OpenCV array.
76
+
77
+<div class="info">
78
+This feature is only available on version 2022.1.0 or later of the kit.
79
+</div>
80
81
+~~~~~ python
82
+import cv2
83
+from sr.robot3 import *
84
+R = Robot()
85
86
+frame = R.camera.capture()
87
88
+# Flip the image with OpenCV
89
+flipped = cv2.flip(frame, 0)
90
+~~~~~
91
92
[Field of View](#fov) {#fov}
93
-------------------
94
0 commit comments