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 rotation on constraint solving #1315

Merged
merged 7 commits into from
Oct 7, 2024

Conversation

fallenatlas
Copy link
Contributor

@fallenatlas fallenatlas commented Sep 19, 2024

Description

Adds angular velocity computation in penetration constraint solving.

Checklist

  • Self-review changes.
  • Evaluate impact on the documentation.
  • Add entry to the changelog's unreleased section.

@fallenatlas fallenatlas self-assigned this Sep 19, 2024
@fallenatlas fallenatlas linked an issue Sep 19, 2024 that may be closed by this pull request
Copy link
Contributor

github-actions bot commented Sep 19, 2024

PR Preview Action v1.4.8
🚀 Deployed preview to https://GameDevTecnico.github.io/cubos/preview/pr-1315/
on branch gh-pages at 2024-10-07 19:42 UTC

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ Clang-Tidy found issue(s) with the introduced code (1/1)

Copy link

codecov bot commented Sep 19, 2024

Codecov Report

Attention: Patch coverage is 2.80899% with 173 lines in your changes missing coverage. Please review.

Project coverage is 40.73%. Comparing base (ada20d7) to head (22dd9a0).
Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
...c/physics/solver/penetration_constraint/plugin.cpp 0.00% 134 Missing ⚠️
engine/src/collisions/narrow_phase/plugin.cpp 4.54% 21 Missing ⚠️
...src/physics/constraints/penetration_constraint.cpp 0.00% 16 Missing ⚠️
engine/src/physics/plugin.cpp 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1315      +/-   ##
==========================================
- Coverage   40.84%   40.73%   -0.12%     
==========================================
  Files         430      430              
  Lines       30409    30500      +91     
==========================================
+ Hits        12421    12423       +2     
- Misses      17988    18077      +89     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@fallenatlas fallenatlas force-pushed the 1272-add-rotation-on-constraint-solving branch from d2b5396 to 1e0fe6b Compare September 19, 2024 23:10
@fallenatlas fallenatlas marked this pull request as ready for review September 24, 2024 19:52
@RiscadoA RiscadoA added this to the 0.4 milestone Sep 26, 2024
Copy link
Member

@RiscadoA RiscadoA left a comment

Choose a reason for hiding this comment

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

Thanks for working on this 🥳 Very cool to see rotation being relevant. As usual, I don't really understand what's going on here, so I'll just trust you on the math.
The sample also runs fine on my machine, but I noticed the movement of the boxes is sometimes weird/unnatural? Is it still missing step or something? What's next?

@RiscadoA
Copy link
Member

Also, don't forget to add an entry to the changelog!

@fallenatlas
Copy link
Contributor Author

Thanks for working on this 🥳 Very cool to see rotation being relevant. As usual, I don't really understand what's going on here, so I'll just trust you on the math. The sample also runs fine on my machine, but I noticed the movement of the boxes is sometimes weird/unnatural? Is it still missing step or something? What's next?

Sometimes it still looks weird yeah, I'm not entirely sure of what the problem is, it could be because of the friction and bounciness settings in the sample which could produce something we don't naturally expect, or my guess is that it has to do with the softness parameters, which might be too strong (they limit the velocities for the solving thus making it feel less crispy and more sluggish, but it's important for stability), but I don't fully understand this part yet so it's something that I'll have to look into in the future.

@fallenatlas fallenatlas force-pushed the 1272-add-rotation-on-constraint-solving branch from f2103d5 to fa2b058 Compare September 30, 2024 09:35
@RiscadoA
Copy link
Member

RiscadoA commented Oct 7, 2024

@fallenatlas Just noticed your commit messages are not very correct:

  • when working on samples, don't use feat(samples), instead use something like docs(physics)
  • don't use penetration_constraint as a scope, use physics (the rule is to stick to the B-label names). If you want to mention it's related to that, put it in the message itself.

If you can, change this before merging!

@fallenatlas fallenatlas force-pushed the 1272-add-rotation-on-constraint-solving branch from fa2b058 to c4c6c3e Compare October 7, 2024 19:41
@fallenatlas fallenatlas force-pushed the 1272-add-rotation-on-constraint-solving branch from c4c6c3e to 22dd9a0 Compare October 7, 2024 21:58
@fallenatlas fallenatlas merged commit 0128120 into main Oct 7, 2024
11 checks passed
@fallenatlas fallenatlas deleted the 1272-add-rotation-on-constraint-solving branch October 7, 2024 22:13
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.

Add rotation on constraint solving
4 participants