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

Polygon display #128

Closed
wants to merge 1 commit into from
Closed

Conversation

will-moore
Copy link
Collaborator

@will-moore will-moore commented Nov 3, 2021

See #127

Since this is a feature I expect to be of use to OME and others, I started to look at supporting viewing Polygons in vizarr.

Initially this uses query params e.g. ?polygons=[[[100,100],[100,200],[110,180],[200,250]],[[10,0],[50,120],[75,0]]]&strokeColor=ff0000 in the screenshot below or try: https://deploy-preview-128--vizarr.netlify.app/?source=https://minio-dev.openmicroscopy.org/idr/v0.3/datasets/idr0062/8dc4707/7754.zarr/B1_C1.tif/&polygons=[[[100,100],[100,200],[110,180],[200,250]],[[10,0],[50,120],[75,0]]]&strokeColor=ff0000

That has the obvious limitation of all Polygons being the same colour and same line width. Fill Colour isn't supported either.

Screenshot 2021-11-03 at 18 07 08

I'll look at adding methods to the notebook API...

@manzt
Copy link
Member

manzt commented Nov 4, 2021

Thanks @will-moore. Exactly the layer I had in mind. Perhaps SolidPolygonLayer if we wanted filled polygons.

I would however like to wait on this being defined first in OME-NGFF if that is ok.

In general, I'd like to avoid inventing more "vizarr concepts" (by adding query parameters for example) since it isn't clear how these parameters should be parsed for the various views of OME-NGFF. For example, what is the behaviour of ?polygon do if we were viewing a plate?

@will-moore
Copy link
Collaborator Author

Agreed. Closing for now...

@will-moore will-moore closed this Nov 8, 2021
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