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

Add fill tool #4780

Merged
merged 23 commits into from
Sep 8, 2020
Merged

Add fill tool #4780

merged 23 commits into from
Sep 8, 2020

Conversation

MichaelBuessemeyer
Copy link
Contributor

@MichaelBuessemeyer MichaelBuessemeyer commented Aug 21, 2020

This PR adds a flood fill tool to the brush.

TODOS:

  • use a better shortcut for the flood fill tool. -> replace with automatic brush
  • test this with a fallback layer -> works
  • integrate with undo redo

URL of deployed dev instance (used for testing):

  • https://___.webknossos.xyz

Steps to test:

  • Open chrome (firefox is not supported)
  • Open a volume tracing and draw a circle in two strokes (not one as this would fill the whole inner area)
  • Use "win/cmd" + left mouse inside the circle
  • The area should be filled with the active cell id (should be pretty fast)

Issues:


@MichaelBuessemeyer MichaelBuessemeyer changed the title [WIP] Add fill tool Add fill tool Aug 24, 2020
@MichaelBuessemeyer MichaelBuessemeyer marked this pull request as ready for review August 24, 2020 15:31
Copy link
Member

@philippotto philippotto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very cool stuff!

Unfortunately, the feature didn't really work for me during testing. Not sure whether I produced some edge case (let me know if I should show it to you in a call), but I also left a comment regarding infinite loops which might be relevant?

Also, see my other feedback for improving code readability :)

CHANGELOG.unreleased.md Outdated Show resolved Hide resolved
frontend/javascripts/libs/utils.js Outdated Show resolved Hide resolved
@philippotto
Copy link
Member

If I don't trigger the already mentioned edge case (which I seemed to have done all the time when first checking this out), this feature is a lot of fun :) Especially in combination with volume-undo. Very well done!! 🥇

@MichaelBuessemeyer
Copy link
Contributor Author

@philippotto I just fixed the bug and applied your feedback as good as I could.

Could you please try out the newest version, once the CI has finished?

@philippotto
Copy link
Member

philippotto commented Aug 27, 2020

Hmm, it crashed again for me. (probably I got served the old version) See this screenshot:

image

with the orange color, I initiated a flood fill at the bottom left corner (one can still see the hover where I clicked). z at 512

Copy link
Member

@philippotto philippotto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, awesome, awesome 👍 I left some other minor feedback, but afterwards, this should be ready to get shipped 🚢

@MichaelBuessemeyer
Copy link
Contributor Author

MichaelBuessemeyer commented Sep 3, 2020

I think I just applied all of your feedback and tested the basic use cases. Everything should work.

@philippotto Could you please recheck this PR (after the CI is done) 🕺

Copy link
Member

@philippotto philippotto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Top notch :)

@MichaelBuessemeyer MichaelBuessemeyer merged commit 983a4d2 into master Sep 8, 2020
@philippotto philippotto deleted the add-fill-tool branch June 14, 2022 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow to split segments
2 participants