Navigation
API > API/Runtime > API/Runtime/Slate
| Name | SViewport |
| Type | class |
| Header File | /Engine/Source/Runtime/Slate/Public/Widgets/SViewport.h |
| Include Path | #include "Widgets/SViewport.h" |
Syntax
class SViewport : public SCompoundWidget
Inheritance Hierarchy
- FSharedFromThisBase → TSharedFromThis → SWidget → SCompoundWidget → SViewport
- FSlateControlledConstruction → SWidget → SCompoundWidget → SViewport
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
SViewport() |
Default constructor. | Widgets/SViewport.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~SViewport() |
Widgets/SViewport.h |
Structs
| Name | Remarks |
|---|---|
| FArguments |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| ActiveTimerHandle | TWeakPtr< FActiveTimerHandle > | The handle to the active EnsureTick() timer | Widgets/SViewport.h | |
| bEnableBlending | bool | Whether or not to blend this viewport with the background. | Widgets/SViewport.h | |
| bEnableGammaCorrection | bool | Whether or not to apply gamma correction on the render target supplied by the ISlateViewport. | Widgets/SViewport.h | |
| bEnableStereoRendering | bool | Whether or not to enable stereo rendering. | Widgets/SViewport.h | |
| bIgnoreTextureAlpha | bool | Whether or not to allow texture alpha to be used in blending calculations. | Widgets/SViewport.h | |
| bPreMultipliedAlpha | bool | True if the viewport texture has pre-multiplied alpha | Widgets/SViewport.h | |
| bRenderDirectlyToWindow | bool | Whether or not this viewport renders directly to the window back-buffer. | Widgets/SViewport.h | |
| bReverseGammaCorrection | bool | Whether or not to reverse the gamma correction done by the texture in this viewport. | Widgets/SViewport.h | |
| CachedParentWindow | TWeakPtr< SWindow > | The parent window during this viewport's last activation | Widgets/SViewport.h | |
| CustomHitTestPath | TSharedPtr< ICustomHitTestPath > | Widgets/SViewport.h | ||
| ShowDisabledEffect | TSlateAttribute< bool, EInvalidateWidgetReason::Paint > | Whether or not to show the disabled effect when this viewport is disabled. | Widgets/SViewport.h | |
| ViewportSize | TSlateAttribute< FVector2D, EInvalidateWidgetReason::Layout > | Size of the viewport. | Widgets/SViewport.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Construct
(
const FArguments& InArgs |
Construct the widget. | Widgets/SViewport.h | |
void EnableStereoRendering
(
const bool bInEnableStereoRendering |
Sets whether stereo rendering is allowed for this viewport. Advanced use only | Widgets/SViewport.h | |
const TSharedPtr< SWidget > GetContent() |
Widgets/SViewport.h | ||
TSharedPtr< ICustomHitTestPath > GetCustomHitTestPath() |
Widgets/SViewport.h | ||
bool GetIgnoreTextureAlpha() |
Widgets/SViewport.h | ||
TWeakPtr< ISlateViewport > GetViewportInterface() |
Sets the interface to be used by this viewport for rendering and I/O | Widgets/SViewport.h | |
bool IsStereoRenderingAllowed() |
Widgets/SViewport.h | ||
FReply OnViewportActivated
(
const FWindowActivateEvent& InActivateEvent |
A delegate called when the viewports top level window is activated | Widgets/SViewport.h | |
void OnViewportDeactivated
(
const FWindowActivateEvent& InActivateEvent |
A delegate called when the viewports top level window is deactivated | Widgets/SViewport.h | |
void OnWindowClosed
(
const TSharedRef< SWindow >& InWindowBeingClosed |
A delegate called when the viewports top level window is being closed | Widgets/SViewport.h | |
void SetActive
(
bool bActive |
Sets whether this viewport is active. | Widgets/SViewport.h | |
void SetContent
(
TSharedPtr< SWidget > InContent |
Sets the content for this widget | Widgets/SViewport.h | |
void SetCustomHitTestPath
(
TSharedPtr< ICustomHitTestPath > CustomHitTestPath |
Widgets/SViewport.h | ||
void SetIgnoreTextureAlpha
(
const bool bInIgnoreTextureAlpha |
If true, the viewport's texture alpha is ignored when performing blending. | Widgets/SViewport.h | |
void SetRenderDirectlyToWindow
(
const bool bInRenderDirectlyToWindow |
Sets whether this viewport can render directly to the back buffer. Advanced use only | Widgets/SViewport.h | |
void SetViewportInterface
(
TSharedRef< ISlateViewport > InViewportInterface |
Sets the interface to be used by this viewport for rendering and I/O | Widgets/SViewport.h | |
bool ShouldRenderDirectly() |
Widgets/SViewport.h |
Overridden from SWidget
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual FVector2D ComputeDesiredSize
(
float |
Computes the ideal size necessary to display this widget. | Widgets/SViewport.h | |
virtual FReply OnAnalogValueChanged
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual void OnArrangeChildren
(
const FGeometry& AllottedGeometry, |
Widgets/SViewport.h | ||
virtual FCursorReply OnCursorQuery
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual void OnFinishedPointerInput() |
Widgets/SViewport.h | ||
virtual void OnFocusLost
(
const FFocusEvent& InFocusEvent |
Widgets/SViewport.h | ||
virtual FReply OnFocusReceived
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnKeyChar
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
| Widgets/SViewport.h | |||
| Widgets/SViewport.h | |||
virtual TOptional< TSharedRef< SWidget > > OnMapCursor
(
const FCursorReply& CursorReply |
Widgets/SViewport.h | ||
virtual FReply OnMotionDetected
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnMouseButtonDoubleClick
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnMouseButtonDown
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnMouseButtonUp
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual void OnMouseEnter
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual void OnMouseLeave
(
const FPointerEvent& MouseEvent |
Widgets/SViewport.h | ||
virtual FReply OnMouseMove
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnMouseWheel
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FNavigationReply OnNavigation
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual int32 OnPaint
(
const FPaintArgs& Args, |
Widgets/SViewport.h | ||
virtual FPopupMethodReply OnQueryPopupMethod() |
Widgets/SViewport.h | ||
virtual TOptional< bool > OnQueryShowFocus
(
const EFocusCause InFocusCause |
Widgets/SViewport.h | ||
virtual FReply OnTouchEnded
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnTouchFirstMove
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnTouchForceChanged
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnTouchGesture
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnTouchMoved
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual FReply OnTouchStarted
(
const FGeometry& MyGeometry, |
Widgets/SViewport.h | ||
virtual bool SupportsKeyboardFocus() |
SViewport wants keyboard focus | Widgets/SViewport.h | |
virtual void Tick
(
const FGeometry& AllottedGeometry, |
Widgets/SViewport.h | ||
virtual TOptional< FVirtualPointerPosition > TranslateMouseCoordinateForCustomHitTestChild
(
const SWidget& ChildWidget, |
Widgets/SViewport.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
EActiveTimerReturnType EnsureTick
(
double InCurrentTime, |
Empty active timer meant to ensure a tick/paint pass while this viewport is active | Widgets/SViewport.h |