Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/UPlayerInput
Description
- Smooth mouse movement, because mouse sampling doesn't match up with tick time.
-
if we got sample event for zero mouse samples (so we didn't have to guess whether a 0 was caused by no sample occuring during the tick (at high frame rates) or because the mouse actually stopped)
| Name | SmoothMouse |
| Type | function |
| Header File | /Engine/Source/Runtime/Engine/Classes/GameFramework/PlayerInput.h |
| Include Path | #include "GameFramework/PlayerInput.h" |
| Source | /Engine/Source/Runtime/Engine/Private/UserInterface/PlayerInput.cpp |
virtual float SmoothMouse
(
float aMouse,
uint8 & SampleCount,
int32 Index
)
the smoothed mouse axis movement
Parameters
| Name | Remarks |
|---|---|
| aMouse is the mouse axis movement received from DirectInput | |
| SampleCount is the number of mouse samples received from DirectInput | |
| Index is 0 for X axis, 1 for Y axis |