vanvalenlab / deepcell-label

Cloud-based data annotation tools for biological images
https://label.deepcell.org
Other
76 stars 14 forks source link

edit mode visual improvements #52

Closed geneva-miller closed 3 years ago

geneva-miller commented 5 years ago

Miscellaneous small improvements would give the pixel-editing mode a nicer feel. These include:

geneva-miller commented 4 years ago

Changed brush color to red until we get it to match the value being edited.

jannieyu commented 4 years ago

Segmented masks and user-added edit annotations are now uniformly transparent in edit mode. Brush has also been made transparent by lowering ctx.globalAlpha right before drawing brush view on top of cells/annotations.

geneva-miller commented 4 years ago

For setting the color of the brush, I think we may need to send the colormap in the payload. (I don't think it would necessarily be the linear colormap version of it--just some way to have get the RGB value from colormap[label].) Then, when adjusting the brush value, the color would get set to colormap[new_value]. Even if we could base some of the colors off of what's in the image, I think we'd run into problems when setting the brush value to something not currently in the image.

I probably won't be working on this particular aspect of it, if you want to give this a try.

geneva-miller commented 4 years ago

Re: adjustable transparency, I think I'm going to have that be a variable that can be modified by scrolling. This would only take effect in edit mode and when not drawing raw (so that the contrast of the raw image can still be adjusted while in edit mode). I will probably take a stab at this in the near future.

geneva-miller commented 4 years ago

Changing direction with this. Brush now has transparent white interior and red or white solid outline to indicate status of eraser. Transparency of brush unlikely to change but adjustable opacity of annotations overlaid in edit mode is still a stretch goal (it will likely become its own issue).