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

Ascension / Tilt does not adhere to Rotation / Flip #1423

Open
t3hm00kz opened this issue Jan 11, 2025 · 4 comments
Open

Ascension / Tilt does not adhere to Rotation / Flip #1423

t3hm00kz opened this issue Jan 11, 2025 · 4 comments
Assignees
Labels
bug Something is not working as intended

Comments

@t3hm00kz
Copy link

When applying Ascension / Tilt to a brush, it will not adhere to any Rotation / Flip.
image

REPRO:

  1. Set up a brush to utilize Ascension / Tilt in some way
    - I.E.: Elliptical dab : angle > Ascension > Value: 90.00 > Output 180 / Min -180 / Max 180
    - Brushes attached are set up for Ascension / Tilt: TILT BRUSHES.zip

  2. Set: 0% Rotation / Horizontal Flip disabled

  3. confirm the brush adheres to the user's Ascension / tilt.

  4. Set: Any non-0% Rotation or Flip enabled

  5. confirm the brush adheres to the user's Ascension / tilt.

EXPECTED:
Ascension / Tilt will adhere to any Rotation / Flip

RESULTS:
Ascension / Tilt does not adjust to fit user's current Rotation / Flip

IMPACT:
User cannot effectively utilize Ascension / Tilt at any non-0% Rotation / Flip

Video attached:
https://github.com/user-attachments/assets/07e1fcd7-17e7-4c18-b868-f1ae7c12a6ad

@askmeaboutlo0m askmeaboutlo0m added the bug Something is not working as intended label Jan 11, 2025
@askmeaboutlo0m askmeaboutlo0m self-assigned this Jan 11, 2025
askmeaboutlo0m added a commit that referenced this issue Jan 11, 2025
By passing the view rotation into the MyPaint engine and flipping the x
and y tilt as appropriate.

Relates to #1423.
@askmeaboutlo0m
Copy link
Member

I've made an attempted fix. Mirroring and flipping the canvas now flip the tilt inputs, so that should now work I think. The canvas rotation is also now passed into the brush engine, which seems like it should lead to correct behavior, given what the internal values end up being, but testing it I don't know if it really is working properly. I may be misunderstanding the intended behavior though, since I never use tilt dynamics myself.

Can you test how this is working? It's available in the alpha release https://github.com/drawpile/Drawpile/releases/tag/continuous

If it doesn't behave properly, can you also try how the brushes behave in MyPaint? That is where the brush engine comes from and would help figure out if it's working properly there: https://mypaint.app/

I unfortunately can't test MyPaint properly myself because the only device I have that supports tilt is an Android tablet.

@amoruwu
Copy link

amoruwu commented Jan 11, 2025

Just tested Angular Offset: View
and Angular Offset Mirrored: View
View means it offsets based on the view's rotation.
Both work great now which is great.

@t3hm00kz
Copy link
Author

t3hm00kz commented Jan 11, 2025

Behavior between both MyPaint and DrawPile now appear to be in parity.

... which means I've just found a bug in both
image

  • H-Flip now functions as expected for both.
  • Tilt via Angular Offset: Ascension > Random behaves as expected.
    -Brush: FanTilt.zip
  • Tilt via Elliptical Dab: Angle > Ascension does not.
    - Brush: FlatTilt.zip

Apologies for morphing the bug a bit. If you'd rather I log a separate one lmk.

@askmeaboutlo0m
Copy link
Member

Alright thanks for testing, that confirms my suspicions. I guess I'll try to pre-rotate the tilt inputs then, since the engine evidently doesn't handle it properly. It'd be consistent with how I solved mirroring and flipping since there's no other way to tell the brush engine about it. It may have knock-on effects in cases where the MyPaint engine does correctly apply the view rotation, but those are pretty obvious in the code and can be removed.

It's fine to keep it all in one ticket, since the user-facing issue is still the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working as intended
Projects
None yet
Development

No branches or pull requests

3 participants