Skip to content

Conversation

@adrian-koretski-unity3d
Copy link
Contributor

Description

Added documentation in Mouse.cs to specify the independent behaviour between position and delta. This is to help clarify ISXB-819

Changes made

Added a few comment lines in Mouse.cs

Testing

Risk

Docs only change. No technical risk.

Checklist

Before review:

  • Changelog entry added.
    • Explains the change in Changed, Fixed, Added sections.
    • For API change contains an example snippet and/or migration example.
    • JIRA ticket linked, example (case %%). If it is a private issue, just add the case ID without a link.
    • Jira port for the next release set as "Resolved".
  • Tests added/changed, if applicable.
    • Functional tests Area_CanDoX, Area_CanDoX_EvenIfYIsTheCase, Area_WhenIDoX_AndYHappens_ThisIsTheResult.
    • Performance tests.
    • Integration tests.
  • Docs for new/changed API's.
    • Xmldoc cross references are set correctly.
    • Added explanation how the API works.
    • Usage code examples added.
    • The manual is updated, if needed.

During merge:

  • Commit message for squash-merge is prefixed with one of the list:
    • NEW: ___.
    • FIX: ___.
    • DOCS: ___.
    • CHANGE: ___.
    • RELEASE: 1.1.0-preview.3.

After merge:

  • Create forward/backward port if needed. If you are blocked from creating a forward port now please add a task to ISX-1444.

…between position and delta. This is to help clarify ISXB-819

/// <summary>
/// Screen-space position of the mouse in pixels.
/// Screen-space position of the mouse in pixels. Updated independently from delta using WM. At high framerates, certain frames might not receive any new position data.
Copy link
Collaborator

Choose a reason for hiding this comment

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

We need to remember this is a platform-agnostic API. I would suggest changing "Updated", which is given, to "May be updated independently from delta depending on the platform."

Then you may add to remarks: "On Windows, delta originates from RAWINPUT API." or leave that out.

Copy link
Collaborator

Choose a reason for hiding this comment

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

"If a delta is needed that correlates with position, compute it based on the last reported position".


/// <summary>
/// Screen-space motion delta of the mouse in pixels.
/// Screen-space motion delta of the mouse in pixels. Updated independently from position using raw mouse input. At high framerates, certain frames might not receive any new delta data.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggest changing this similarly.

Copy link
Collaborator

@ekcoh ekcoh left a comment

Choose a reason for hiding this comment

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

LGTM

Moved new docs to <remarks> section, and improved wording.
Copy link
Contributor

@duckets duckets left a comment

Choose a reason for hiding this comment

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

Approved with changes applied direct to branch.

@adrian-koretski-unity3d adrian-koretski-unity3d merged commit 9ab25ab into develop Nov 12, 2024
77 checks passed
@adrian-koretski-unity3d adrian-koretski-unity3d deleted the DOCS__Specifying_mouse_position_and_delta_behaviour branch November 12, 2024 15: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.

3 participants