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

Is it possible to find intersection area? #59

Open
victoriaSh opened this issue Mar 26, 2021 · 1 comment
Open

Is it possible to find intersection area? #59

victoriaSh opened this issue Mar 26, 2021 · 1 comment

Comments

@victoriaSh
Copy link

Just a question. I have Paths with strokeWidth. I want to find area of grey and black paths (on screenshot) and compare it to their intersection area to detect that user draw a letter.
Intersection of paths doesn't include information about strokeWidth. it seems that converting path to rectangle will not work for curved paths.
Is it possible to find intersection area with kdl-intersection package?
IMG_5350
IMG_5351

@jkufner
Copy link

jkufner commented Mar 26, 2021

I would rather render both letters to a bitmap and compare them pixel by pixel. Assuming, that you want to calculate some kind of similarity score.

If you wish to calculate how well a kid writes, then go with completely different approach: compare strokes, not the intersection with the template. Imagine the drawn A is just a little bit bigger than the template. The two (almost) vertical strokes are both just next to the template. Therefore, the grey area is huge, but the kid created almost a perfect letter.

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

No branches or pull requests

2 participants