Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose setAutoResizeCanvas API #5901

Open
whatisor opened this issue Mar 12, 2025 · 0 comments
Open

Expose setAutoResizeCanvas API #5901

whatisor opened this issue Mar 12, 2025 · 0 comments
Assignees
Labels
platform:javascript MediaPipe Javascript issues task:image segmentation Issues related to image segmentation: Locate objects and create image masks with labels type:feature Enhancement in the New Functionality or Request for a New Solution

Comments

@whatisor
Copy link

whatisor commented Mar 12, 2025

MediaPipe Solution (you are using)

tasks-vision -> ImageSegmenter

Programming language

Typescript

Are you willing to contribute it

Yes

Describe the feature and the current behaviour/state

When using webgltexture as output. Canvas size is forced inside tasks-vision which prohibit application rendering from handling rendering buffer size such as device pixel ratio usage.

Will this change the current API? How?

Yes. Expose new api.

Who will benefit with this feature?

All web application who render directly on canvas which passed into tasks-vision.

Please specify the use cases for this feature

Init ImageSegmenter with canvas and gpu mode, then setup canvas to render result with device pixel ratio.

Any Other info

Issue: Cannot resize canvas to apply device pixel ratio for better rendering quality.
Other option is setting default as False.

@whatisor whatisor added the type:feature Enhancement in the New Functionality or Request for a New Solution label Mar 12, 2025
@kuaashish kuaashish added task:image segmentation Issues related to image segmentation: Locate objects and create image masks with labels platform:javascript MediaPipe Javascript issues labels Mar 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform:javascript MediaPipe Javascript issues task:image segmentation Issues related to image segmentation: Locate objects and create image masks with labels type:feature Enhancement in the New Functionality or Request for a New Solution
Projects
None yet
Development

No branches or pull requests

2 participants