You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/components/camera/transform.md
+69-39
Original file line number
Diff line number
Diff line change
@@ -122,8 +122,7 @@ The following attributes are available for `transform` views:
122
122
123
123
The following are the transformation objects available for the `pipeline`:
124
124
125
-
{{< tabs >}}
126
-
{{% tab name="Classifications" %}}
125
+
### Classifications
127
126
128
127
Classifications overlay text from the `GetClassifications` method of the [vision service](/services/vision/) onto the image.
129
128
@@ -151,12 +150,13 @@ Classifications overlay text from the `GetClassifications` method of the [vision
151
150
-`max_classifications`: _Optional_. The maximum number of classifications to display on the camera stream at any given time. Default: `1`.
152
151
-`valid_labels`: _Optional_. An array of labels that you to see detections for on the camera stream. If not specified, all labels from the classifier are used.
153
152
154
-
{{% /tab %}}
155
-
156
-
{{% tab name="Crop" %}}
153
+
### Crop
157
154
158
155
The Crop transform crops takes an image and crops it to a rectangular area specified by two points: the top left point (`(x_min, y_min)`) and the bottom right point (`(x_max, y_max)`).
-`x_min_px`: The x coordinate or the relative proportion of the top left point of the rectangular area to crop the image to.
230
+
-`y_min_px`: The y coordinate or the relative proportion of the top left point of the rectangular area to crop the image to.
231
+
-`x_max_px`: The x coordinate or the relative proportion of the bottom right point of the rectangular area to crop the image to.
232
+
-`y_max_px`: The y coordinate or the relative proportion of the bottom right point of the rectangular area to crop the image to.
233
+
-`overlay_crop_box`: Set to `true` to not actually carry out the crop, but instead overlay the cropping box on the original image and visualize where the crop would be applied.
234
+
235
+
### Depth edges
187
236
188
237
The Depth Edges transform creates a canny edge detector to detect edges on an input depth map.
189
238
@@ -209,8 +258,7 @@ The Depth Edges transform creates a canny edge detector to detect edges on an in
209
258
-`low_threshold_pct`: The low threshold value: between 0.0 - 1.0.
210
259
-`blur_radius_px`: The blur radius used to smooth the image before applying the filter.
211
260
212
-
{{% /tab %}}
213
-
{{% tab name="Depth Preprocess" %}}
261
+
### Depth preprocess
214
262
215
263
Depth Preprocessing applies some basic hole-filling and edge smoothing to a depth map.
216
264
@@ -230,9 +278,7 @@ Depth Preprocessing applies some basic hole-filling and edge smoothing to a dept
230
278
231
279
- None.
232
280
233
-
{{% /tab %}}
234
-
235
-
{{% tab name="Depth to Pretty" %}}
281
+
### Depth to pretty
236
282
237
283
The Depth-to-Pretty transform takes a depth image and turns it into a colorful image, with blue indicating distant points and red indicating nearby points.
238
284
The actual depth information is lost in the transform.
@@ -253,9 +299,7 @@ The actual depth information is lost in the transform.
253
299
254
300
- None.
255
301
256
-
{{% /tab %}}
257
-
258
-
{{% tab name="Detections" %}}
302
+
### Detections
259
303
260
304
The Detections transform takes the input image and overlays the detections from a given detector configured within the [vision service](/services/vision/).
261
305
@@ -281,9 +325,7 @@ The Detections transform takes the input image and overlays the detections from
281
325
-`confidence_threshold`: Specify to only display detections above the specified threshold (decimal between 0 and 1).
282
326
-`valid_labels`: _Optional_. An array of labels that you to see detections for on the camera stream. If not specified, all labels from the classifier are used.
283
327
284
-
{{% /tab %}}
285
-
286
-
{{% tab name="Identity"%}}
328
+
### Identity
287
329
288
330
The Identity transform does nothing to the image.
289
331
You can use this transform to change the underlying camera source's intrinsic parameters or stream type, for example.
@@ -303,9 +345,7 @@ You can use this transform to change the underlying camera source's intrinsic pa
303
345
304
346
- None
305
347
306
-
{{% /tab %}}
307
-
308
-
{{% tab name="Overlay" %}}
348
+
### Overlay
309
349
310
350
Overlays the depth and the color 2D images.
311
351
Useful to debug the alignment of the two images.
@@ -341,9 +381,7 @@ Useful to debug the alignment of the two images.
341
381
-`fx`: The image focal x.
342
382
-`fy`: The image focal y.
343
383
344
-
{{% /tab %}}
345
-
346
-
{{% tab name="Resize" %}}
384
+
### Resize
347
385
348
386
The Resize transform resizes the image to the specified height and width.
349
387
@@ -367,9 +405,7 @@ The Resize transform resizes the image to the specified height and width.
367
405
-`width_px`: Specify the expected width for the aligned image. Value must be >= 0.
368
406
-`height_px`: Specify the expected width for the aligned image. Value must be >= 0.
369
407
370
-
{{% /tab %}}
371
-
372
-
{{% tab name="Rotate" %}}
408
+
### Rotate
373
409
374
410
The Rotate transformation rotates the image by the angle specified in `angle_deg`. Default: 180 degrees.
375
411
This feature is useful for when the camera is installed upside down or sideways on your machine.
@@ -392,9 +428,7 @@ This feature is useful for when the camera is installed upside down or sideways
392
428
393
429
-`angle_deg`: Rotate the image by a specific angle in degrees.
394
430
395
-
{{% /tab %}}
396
-
397
-
{{% tab name="Undistort" %}}
431
+
### Undistort
398
432
399
433
The Undistort transform undistorts the input image according to the intrinsic and distortion parameters specified within the camera parameters.
400
434
Currently only supports a Brown-Conrady model of distortion (20 September 2022).
@@ -444,10 +478,6 @@ For further information, please refer to the [OpenCV docs](https://docs.opencv.o
0 commit comments