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

Defualt arrow head with antialiasing #32

Open
ugwis opened this issue May 1, 2024 · 0 comments
Open

Defualt arrow head with antialiasing #32

ugwis opened this issue May 1, 2024 · 0 comments
Labels
bug Unexpected behavior / Something isn't working

Comments

@ugwis
Copy link
Member

ugwis commented May 1, 2024

Since the argument of drawLine is image.Point (a structure with x,y as integers), the floating point number is cast to an integer.
image

a := arrowPt.Mul(i)
b := a.Add(at1.Mul(al - i)).Div(al)
c := a.Add(at2.Mul(al - i)).Div(al)
l.drawLine(img, b, c)

Considering extensibility, an option is to create a Point structure with x and y as floating point numbers.

@ugwis ugwis added the bug Unexpected behavior / Something isn't working label May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected behavior / Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant