-
Notifications
You must be signed in to change notification settings - Fork 300
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
PAINTROID-432: Implement clipping tool to erase background more easily #1125
Conversation
81317fe
to
732483f
Compare
a190a70
to
fb90bb4
Compare
Paintroid/src/main/java/org/catrobat/paintroid/controller/DefaultToolController.kt
Outdated
Show resolved
Hide resolved
Paintroid/src/main/java/org/catrobat/paintroid/controller/DefaultToolController.kt
Outdated
Show resolved
Hide resolved
Paintroid/src/main/java/org/catrobat/paintroid/controller/DefaultToolController.kt
Outdated
Show resolved
Hide resolved
Paintroid/src/main/java/org/catrobat/paintroid/ui/tools/DefaultSmudgeToolOptionsView.kt
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls change the requested changes.
e804abd
to
520c87e
Compare
Implemented new "clipping" tool where user can mark one or several areas and then apply the tool which erases everything except the marked areas.
520c87e
to
7642c30
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
This PR is the main work of my GSoC 2022.
I've Implemented a new tool called "clip area/clipping tool" with which the user is able to mark an area and when applying the tool or switching to another tool with a marked area already drawn, everything except the marked area will be erased. The path for the marked area can have any color but depending on the tool color, the path either has a white contour (when black is the current tool color) or black otherwise.
In order to have an actual closed area to properly clip I decided to do the same as i.e. Photoshop and just draw a last line from the last coordinate (where the user released the finger) to the initial coordinate to have an actual closed marked area to clip. I did not find out yet why sometimes the line is an actual line and sometimes the patheffect of the toolpaint actually applies and a dashed line will be drawn.
Click for demo on black bitmap with undo and redo:
Click for demo on pink bitmap with redrawing marked area and color change:
Click for demo on actual face:
https://jira.catrob.at/browse/PAINTROID-432