@@ -3,8 +3,7 @@ layout: page
3
3
title : Vision
4
4
---
5
5
6
- Vision
7
- ======
6
+ # Vision
8
7
9
8
Your robot is able to use a webcam to detect [ fiducial markers] ( https://en.wikipedia.org/wiki/Fiducial_marker ) .
10
9
Specifically it can detect [ AprilTags] ( https://april.eecs.umich.edu/software/apriltag ) , using the ` 36H11 ` marker set.
@@ -17,8 +16,8 @@ Using the marker poses and their locations, we can either calculate the location
17
16
18
17
For information on markers, see the [ markers page] ( ./markers ) .
19
18
20
- [ Camera ] ( #camera ) {#camera}
21
- ===========================
19
+
20
+ ## Camera
22
21
23
22
The interface to the vision system is through the camera, accessible through ` R.camera ` .
24
23
@@ -69,8 +68,8 @@ frame = robot.camera.capture()
69
68
flipped = cv2.flip(frame, 0 )
70
69
~~~~~
71
70
72
- [ Frame argument ] ( #frame_args ) {#frame_args}
73
- -------------------------------------------
71
+
72
+ ### Frame argument
74
73
75
74
The slowest part of vision is capturing the image.
76
75
You can use a frame with the other vision commands to avoid recapturing.
@@ -92,8 +91,8 @@ robot.camera.save("photo.jpg", frame=frame)
92
91
# Do some other vision algorithm with the OpenCV frame here
93
92
~~~~~
94
93
95
- [ Field of View ] ( #fov ) {#fov}
96
- ----------------------------
94
+
95
+ ### Field of View
97
96
98
97
The Logitech C500 has a [ field of view] [ fov ] of 72° ; and the C270 has a field of view of 60° ; .
99
98
@@ -104,8 +103,8 @@ Note that the axes are all defined relative to the camera.
104
103
Since we have no way to know how you've mounted your camera, you may need to account for that in your usage of the vision system's data.
105
104
</div >
106
105
107
- [ Marker ] ( #marker ) {#marker}
108
- ===========================
106
+
107
+ ## Marker
109
108
110
109
A ` Marker ` object contains information about a * detected* marker.
111
110
It has the following attributes:
@@ -117,10 +116,10 @@ size
117
116
: The physical size of the marker, as the vision system expects it.
118
117
119
118
pixel_centre
120
- : A [ ` PixelCoordinates ` ] ( #PixelCoordinates ) describing the position of the centre of the marker in the image.
119
+ : A [ ` PixelCoordinates ` ] ( #pixelcoordinates ) describing the position of the centre of the marker in the image.
121
120
122
121
pixel_corners
123
- : A list of 4 [ ` PixelCoordinates ` ] ( #PixelCoordinates ) instances, each representing the position of a corner of the marker in the image.
122
+ : A list of 4 [ ` PixelCoordinates ` ] ( #pixelcoordinates ) instances, each representing the position of a corner of the marker in the image.
124
123
125
124
position
126
125
: A ` Position ` instance describing the position of the marker.
@@ -161,10 +160,7 @@ orientation
161
160
Zero values have the marker facing the camera square-on.
162
161
163
162
164
- <a id =" Coordinate " />
165
-
166
- [ ` PixelCoordinates ` ] ( #PixelCoordinates ) {#PixelCoordinates}
167
- ---------
163
+ ### PixelCoordinates
168
164
169
165
A named tuple of ` x ` and ` y ` coordinates for the point, in pixels relative to the top left of the image.
170
166
0 commit comments