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

Auto rotate over a square #12823

Merged
merged 1 commit into from
Apr 14, 2020
Merged

Conversation

iota97
Copy link
Contributor

@iota97 iota97 commented Apr 14, 2020

At first I thought the analog would get only to 1/sqrt(2) at the corner as the HW was a circle, after seeing #11552 this is probabbly safer for QTE.

@hrydgard
Copy link
Owner

/home/travis/build/hrydgard/ppsspp/UI/GamepadEmu.cpp:206:71: error: no matching function for call to ‘max(float, double)’
   __CtrlSetAnalogX(std::min(1.0f, std::max(-1.0f, 1.42f*cos(now*speed))), 0);

The two arguments to std::min (and std::max) need to be of the same type, easily fixed by changing cos to cosf and sin to sinf.

@hrydgard hrydgard merged commit 30eebe2 into hrydgard:master Apr 14, 2020
@fu8765
Copy link

fu8765 commented Apr 14, 2020

v1.9.3-664-g30eebe2f1 doesn't fix it for me. (if that was the intention)

@iota97
Copy link
Contributor Author

iota97 commented Apr 14, 2020

This is for the auto analog rotation only (it allow to rotate the analog with a key press to help with QTE on keyboard and touch control), so it's expected not to fix that, sorry for the confusion :)

@unknownbrackets unknownbrackets added this to the v1.10.0 milestone Apr 15, 2020
@iota97 iota97 deleted the analog-rot-square branch April 16, 2020 10:03
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

Successfully merging this pull request may close these issues.

4 participants