Fix: add ffmpeg_output_width and ffmpeg_output_height parameters to client.py#4371
Open
Vishwa2684 wants to merge 2 commits into
Open
Fix: add ffmpeg_output_width and ffmpeg_output_height parameters to client.py#4371Vishwa2684 wants to merge 2 commits into
ffmpeg_output_width and ffmpeg_output_height parameters to client.py#4371Vishwa2684 wants to merge 2 commits into
Conversation
…earing of output in rtsp sink
Removed conditional handling for RTSP output stream parameters and simplified StreamClient initialization.
ffmpeg_output_width and ffmpeg_output_height parameters to client.py
ffmpeg_output_width and ffmpeg_output_height parameters to client.pyffmpeg_output_width and ffmpeg_output_height parameters to client.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🛠 Summary
@atobiszei , @dtrawins
This PR adds ffmpeg_output_width and ffmpeg_output_height parameters to the RTSP output backend in client.py.
Previously, the FFmpeg output sink assumed that the output frame dimensions matched the input stream. MediaPipe graphs that resize or transform frames (for example, object detection graphs) can produce annotated frames whose dimensions differ from those assumed by the FFmpeg writer. This mismatch results in corrupted RTSP output (tearing, repeated tiles, or distorted frames).
By exposing the output dimensions as configurable parameters, the FFmpeg sink can be initialized with the correct frame size for each graph, avoiding these artifacts.