Module |
|
Header |
/Engine/Source/Runtime/UMG/Public/Blueprint/WidgetLayoutLibrary.h |
Include |
#include "Blueprint/WidgetLayoutLibrary.h" |
Source |
/Engine/Source/Runtime/UMG/Private/WidgetLayoutLibrary.cpp |
static bool ProjectWorldLocationToWidgetPosition
(
APlayerController * PlayerController,
FVector WorldLocation,
FVector2D & ScreenPosition,
bool bPlayerViewportRelative
)
Gets the projected world to screen position for a player, then converts it into a widget position, which takes into account any quality scaling.
true if the position projects onto the screen.
Parameter |
Description |
---|---|
PlayerController |
The player controller to project the position in the world to their screen. |
WorldLocation |
The world location to project from. |
ScreenPosition |
The position in the viewport with quality scale removed and DPI scale remove. |
bPlayerViewportRelative |
Should this be relative to the player viewport subregion (useful when using player attached widgets in split screen or when aspect-ratio constrained) |