Skip to content

[node-hub] opencv-plot: allow specifying encoding and bbox format in uppercase letters#1075

Merged
haixuanTao merged 1 commit intodora-rs:mainfrom
dieu-detruit:node_hub-opencv_plot-allow_uppercase_encoding_and_bbox_format
Jul 21, 2025
Merged

[node-hub] opencv-plot: allow specifying encoding and bbox format in uppercase letters#1075
haixuanTao merged 1 commit intodora-rs:mainfrom
dieu-detruit:node_hub-opencv_plot-allow_uppercase_encoding_and_bbox_format

Conversation

@dieu-detruit
Copy link
Copy Markdown
Contributor

Target

opencv-plot on node-hub.

Problem

Another node on hub like kornia-v4l-capture may output encoding in uppercase (e.g. RGB8)

The current code only allows lower case (rgb8) and causes error between kornia-v4l-capture and this node.

This PR

Take lowercase string for encodings and bbox formats before compairing them.

@dieu-detruit
Copy link
Copy Markdown
Contributor Author

I've tested with this dataflow.yaml and it works.

nodes:
  - id: camera
    build: cargo install --git https://github.com/kornia/dora-nodes-hub kornia-gst-capture
    path: kornia-gst-capture
    inputs:
      tick: dora/timer/millis/30
    outputs:
      - frame
    env:
      SOURCE_TYPE: "webcam"
      SOURCE_URI: "/dev/video0"
      IMAGE_COLS: "640"
      IMAGE_ROWS: "480"
      SOURCE_FPS: "30"
      PIXEL_FORMAT: "YUYV"
  - id: opencv-plot
    build: uv add --branch node_hub-opencv_plot-allow_uppercase_encoding_and_bbox_format git+https://github.com/dieu-detruit/dora.git#subdirectory=node-hub/opencv-plot
    path: opencv-plot
    inputs:
      image: camera/frame

@haixuanTao haixuanTao merged commit 015368d into dora-rs:main Jul 21, 2025
128 checks passed
@haixuanTao
Copy link
Copy Markdown
Collaborator

Thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants