Skip to content

Fix overlay not drawing in cross-variant pipelines#53

Merged
ferjm merged 1 commit into
mainfrom
multi-variant-overlay
May 27, 2026
Merged

Fix overlay not drawing in cross-variant pipelines#53
ferjm merged 1 commit into
mainfrom
multi-variant-overlay

Conversation

@ferjm

@ferjm ferjm commented May 27, 2026

Copy link
Copy Markdown
Member

In multi-variant pipelines (e.g. videoinfer_34 → videoinfer_35 →
overlay_34), two bugs prevented the overlay from rendering:

  1. VideoRegionOfInterestMeta (bounding boxes) was silently dropped when passing through a downstream NeverInPlace videoinfer element. GStreamer's default transform_meta rejects metas with API tags (video, size), while tagless custom metas survived. Override transform_meta to preserve all upstream metadata.

  2. The overlay's typed meta::() lookup matched by GType, so overlay variant 34 could never find classification metadata registered by variant 35. Replace with name-prefix iteration over all buffer metas and unsafe cast to the shared repr(C) layout.

  In multi-variant pipelines (e.g. videoinfer_34 → videoinfer_35 →
  overlay_34), two bugs prevented the overlay from rendering:

  1. VideoRegionOfInterestMeta (bounding boxes) was silently dropped
     when passing through a downstream NeverInPlace videoinfer element.
     GStreamer's default transform_meta rejects metas with API tags
     (video, size), while tagless custom metas survived. Override
     transform_meta to preserve all upstream metadata.

  2. The overlay's typed meta::<VideoClassificationMeta>() lookup matched
     by GType, so overlay variant 34 could never find classification
     metadata registered by variant 35. Replace with name-prefix iteration
     over all buffer metas and unsafe cast to the shared repr(C) layout.
@ferjm ferjm merged commit cd771c3 into main May 27, 2026
1 of 2 checks passed
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.

1 participant