Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Refactor dxDrawCircle to use primitives queue, fix it's postGui issues #618

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

Merged
ccw808 merged 3 commits into multitheftauto:master from forkerer:dxDrawCirclePrimitive
Sep 30, 2018

Conversation

@forkerer
Copy link
Contributor

@forkerer forkerer commented Sep 29, 2018
edited by botder
Loading

Fixes #432, #431.

As the title suggest, this pull request forces dxDrawCircle to use primitives drawing, and fixes it's postGui issues. It also includes a bit of general code cleanup and removal of unnecessary vertices creation. I tried to test most of the common scenarios with that, and couldn't find any issues.

Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

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

Good job.

fStartAngle = D3DXToRadian(fStartAngle);
fStopAngle = D3DXToRadian(fStopAngle);
// Calculate each segment angle
const float kfSegmentAngle = (fStopAngle - fStartAngle) / (siSegments-1);
Copy link

Choose a reason for hiding this comment

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

I remember removing -1 in (siSegments-1), and it worked without any issues. Any reason for adding it back?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Instead of floating point based loop, i made it to use exactly the amount of segments specified in dxDrawCircle call, that required adding -1 again

codenulls reacted with thumbs up emoji
@ccw808 ccw808 merged commit d28393f into multitheftauto:master Sep 30, 2018
Copy link
Member

ccw808 commented Sep 30, 2018

Thank you

@patrikjuvonen patrikjuvonen added this to the 1.5.7 milestone Jan 5, 2019
@patrikjuvonen patrikjuvonen added bug Something isn't working refactor labels Jan 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

1 more reviewer
Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Labels

bug Something isn't working refactor

Projects

None yet

Milestone

1.5.7

Development

Successfully merging this pull request may close these issues.

dxDrawCircle: Not rendered at all if postGUI is enabled

AltStyle によって変換されたページ (->オリジナル) /