FSlateDrawElement is the building block for Slate's rendering interface. 更多...
#include <DrawElements.h>
Public 类型 | |
| enum | ERotationSpace { RelativeToElement , RelativeToWorld } |
Public 成员函数 | |
| void | ApplyPositionOffset (const FVector2D &InOffset) |
| Update element cached position with an arbitrary offset 更多... | |
静态 Public 成员函数 | |
| static SLATECORE_API void | MakeBox (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FSlateBrush *InBrush, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Creates a box element based on the following diagram. 更多... | |
| static SLATECORE_API void | MakeCubicBezierSpline (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FVector2D &P0, const FVector2D &P1, const FVector2D &P2, const FVector2D &P3, float InThickness=0.0f, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Creates a Bezier Spline element 更多... | |
| static SLATECORE_API void | MakeCustom (FSlateWindowElementList &ElementList, uint32 InLayer, TSharedPtr< ICustomSlateElement, ESPMode::ThreadSafe > CustomDrawer) |
| Creates a custom element which can be used to manually draw into the Slate render target with graphics API calls rather than Slate elements 更多... | |
| static SLATECORE_API void | MakeDebugQuad (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FLinearColor &InTint=FLinearColor::White) |
| Creates a wireframe quad for debug purposes 更多... | |
| static SLATECORE_API void | MakeDrawSpaceGradientSpline (FSlateWindowElementList &ElementList, uint32 InLayer, const FVector2D &InStart, const FVector2D &InStartDir, const FVector2D &InEnd, const FVector2D &InEndDir, const TArray< FSlateGradientStop > &InGradientStops, float InThickness=0.0f, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None) |
| Just like MakeSpline but in draw-space coordinates. 更多... | |
| static SLATECORE_API void | MakeDrawSpaceSpline (FSlateWindowElementList &ElementList, uint32 InLayer, const FVector2D &InStart, const FVector2D &InStartDir, const FVector2D &InEnd, const FVector2D &InEndDir, float InThickness=0.0f, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Just like MakeSpline but in draw-space coordinates. 更多... | |
| static SLATECORE_API void | MakeGradient (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, TArray< FSlateGradientStop > InGradientStops, EOrientation InGradientType, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None) |
| Creates a gradient element 更多... | |
| static SLATECORE_API void | MakeLines (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const TArray< FVector2D > &Points, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White, bool bAntialias=true, float Thickness=1.0f) |
| Creates a line defined by the provided points 更多... | |
| static SLATECORE_API void | MakeShapedText (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FShapedGlyphSequenceRef &InShapedGlyphSequence, ESlateDrawEffect InDrawEffects, const FLinearColor &BaseTint, const FLinearColor &OutlineTint) |
| Creates a text element which displays a series of shaped glyphs on the screen 更多... | |
| static SLATECORE_API void | MakeSpline (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FVector2D &InStart, const FVector2D &InStartDir, const FVector2D &InEnd, const FVector2D &InEndDir, float InThickness=0.0f, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Creates a Hermite Spline element 更多... | |
| static SLATECORE_API void | MakeText (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, const FString &InText, const int32 StartIndex, const int32 EndIndex, const FSlateFontInfo &InFontInfo, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Creates a text element which displays a string of a rendered in a certain font on the screen 更多... | |
| static SLATECORE_API void | MakeViewport (FSlateWindowElementList &ElementList, uint32 InLayer, const FPaintGeometry &PaintGeometry, TSharedPtr< const ISlateViewport > Viewport, ESlateDrawEffect InDrawEffects=ESlateDrawEffect::None, const FLinearColor &InTint=FLinearColor::White) |
| Creates a viewport element which is useful for rendering custom data in a texture into Slate 更多... | |
友元 | |
| class | FSlateWindowElementList |
FSlateDrawElement is the building block for Slate's rendering interface.
Slate describes its visual output as an ordered list of FSlateDrawElement s
| void FSlateDrawElement::ApplyPositionOffset | ( | const FVector2D & | InOffset | ) |
Update element cached position with an arbitrary offset
| Element | Element to update |
| InOffset | Absolute translation delta |
|
static |
Creates a box element based on the following diagram.
Allows for this element to be resized while maintain the border of the image If there are no margins the resulting box is simply a quad ___LeftMargin ___RightMargin / / +–+----------—+–+ | |c1 |c2| ___TopMargin +–o----------—o–+ | | | | | |c3 |c4| +–o----------—o–+ | | | | ___BottomMargin +–+----------—+–+
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InBrush | Brush to apply to this element |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
|
static |
Creates a Bezier Spline element
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InStart | The start point of the spline (local space) |
| InStartDir | The direction of the spline from the start point |
| InEnd | The end point of the spline (local space) |
| InEndDir | The direction of the spline to the end point |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
|
static |
Creates a custom element which can be used to manually draw into the Slate render target with graphics API calls rather than Slate elements
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| CustomDrawer | Interface to a drawer which will be called when Slate renders this element |
|
static |
Creates a wireframe quad for debug purposes
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
|
static |
Just like MakeSpline but in draw-space coordinates.
This is useful for connecting already-transformed widgets together.
|
static |
Just like MakeSpline but in draw-space coordinates.
This is useful for connecting already-transformed widgets together.
|
static |
Creates a gradient element
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InGradientStops | List of gradient stops which define the element |
| InGradientType | The type of gradient (I.E Horizontal, vertical) |
| InDrawEffects | Optional draw effects to apply |
|
static |
Creates a line defined by the provided points
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| Points | Points that make up the lines. The points are joined together. I.E if Points has A,B,C there the line is A-B-C. To draw non-joining line segments call MakeLines multiple times |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
| bAntialias | Should antialiasing be applied to the line? |
| Thickness | The thickness of the line |
|
static |
Creates a text element which displays a series of shaped glyphs on the screen
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InShapedGlyphSequence | The shaped glyph sequence to draw |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
|
static |
Creates a Hermite Spline element
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InStart | The start point of the spline (local space) |
| InStartDir | The direction of the spline from the start point |
| InEnd | The end point of the spline (local space) |
| InEndDir | The direction of the spline to the end point |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
|
static |
Creates a text element which displays a string of a rendered in a certain font on the screen
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| InText | The string to draw |
| StartIndex | Inclusive index to start rendering from on the specified text |
| EndIndex | Exclusive index to stop rendering on the specified text |
| InFontInfo | The font to draw the string with |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |
|
static |
Creates a viewport element which is useful for rendering custom data in a texture into Slate
| ElementList | The list in which to add elements |
| InLayer | The layer to draw the element on |
| PaintGeometry | DrawSpace position and dimensions; see FPaintGeometry |
| Viewport | Interface for drawing the viewport |
| InScale | Draw scale to apply to the entire element |
| InDrawEffects | Optional draw effects to apply |
| InTint | Color to tint the element |