Skip to content

Commit 9671786

Browse files
committed
docs: add usage examples for drawing bounding boxes and labels in bbox-visualizer
1 parent f34e9fb commit 9671786

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

docs/usage.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ To use bbox-visualizer in a project:
1515
# Load an image
1616
image = cv2.imread('image.jpg')
1717
18+
# Draw a bounding box
19+
bbox = (100, 100, 200, 200) # (x1, y1, x2, y2) format
20+
image = bbv.draw_rectangle(image, bbox)
21+
22+
# Add a label
23+
image = bbv.add_label(image, "Object", bbox)
24+
1825
Warning Control
1926
-------------
2027

0 commit comments

Comments
 (0)