reckfellENGINE

SubViewportContainer

A container used for displaying the contents of a SubViewport.

On this page
class SubViewportContainerReckfellSharpInherits Container

A container used for displaying the contents of a SubViewport.

A container that displays the contents of underlying SubViewport child nodes. It uses the combined size of the SubViewports as minimum size, unless SubViewportContainer.Stretch is enabled. Note: Changing a SubViewportContainer's Control.Scale will cause its contents to appear distorted. To change its visual size without causing distortion, adjust the node's offset properties instead (if it's not already in a container). Note: The SubViewportContainer forwards mouse-enter and mouse-exit notifications to its sub-viewports.

Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.

Constructors1

SubViewportContainerConstructor
# SubViewportContainer
C#
public SubViewportContainer();

Creates a container displaying child SubViewports. Add a SubViewport as a direct child; an ordinary Control is not a viewport-image source.

Properties3

MouseTargetProperty
# MouseTarget
C#
public bool MouseTarget { get; set; }

Selects mouse-feature targets such as cursors and drag-and-drop. true targets the container itself; false permits Controls inside child SubViewports. Not a switch for all event forwarding; use _PropagateInputEvent to filter.

StretchProperty
# Stretch
C#
public bool Stretch { get; set; }

Stretches the displayed texture and controls direct child SubViewport output Size from the container size and StretchShrink. Disable Stretch to change a child Size manually.

StretchShrinkProperty
# StretchShrink
C#
public int StretchShrink { get; set; }

Integer divisor of child SubViewport resolution when Stretch is enabled, at least 1. For example, a 128 by 96 container at 2 uses a 64 by 48 target. Does not shrink the container itself; changes target quality and cost.

Methods7

GetStretchShrinkint
# GetStretchShrink
C#
public int GetStretchShrink();

Returns the requested StretchShrink value. Integer divisor of child SubViewport resolution when Stretch is enabled, at least 1. For example, a 128 by 96 container at 2 uses a 64 by 48 target. Does not shrink the container itself; changes target quality and cost.

Returns int

Value of StretchShrink; account for the documented distinction between a setting and its effective result.

IsMouseTargetEnabledbool
# IsMouseTargetEnabled
C#
public bool IsMouseTargetEnabled();

Selects mouse-feature targets such as cursors and drag-and-drop. true targets the container itself; false permits Controls inside child SubViewports. Not a switch for all event forwarding; use _PropagateInputEvent to filter.

Returns bool

Selects mouse-feature targets such as cursors and drag-and-drop. true targets the container itself; false permits Controls inside child SubViewports. Not a switch for all event forwarding; use _PropagateInputEvent to filter.

IsStretchEnabledbool
# IsStretchEnabled
C#
public bool IsStretchEnabled();

Returns the requested Stretch value. Stretches the displayed texture and controls direct child SubViewport output Size from the container size and StretchShrink. Disable Stretch to change a child Size manually.

Returns bool

Value of Stretch; account for the documented distinction between a setting and its effective result.

SetMouseTargetvoid
# SetMouseTarget
C#
public void SetMouseTarget(bool amount);

Selects mouse-feature targets such as cursors and drag-and-drop. true targets the container itself; false permits Controls inside child SubViewports. Not a switch for all event forwarding; use _PropagateInputEvent to filter.

Parameters
NameTypeDefault
amountbool—
amount

true targets the container for mouse features; false targets nested Controls.

SetStretchvoid
# SetStretch
C#
public void SetStretch(bool enable);

Sets Stretch. Stretches the displayed texture and controls direct child SubViewport output Size from the container size and StretchShrink. Disable Stretch to change a child Size manually.

Parameters
NameTypeDefault
enablebool—
enable

Stretches the displayed texture and controls direct child SubViewport output Size from the container size and StretchShrink. Disable Stretch to change a child Size manually.

SetStretchShrinkvoid
# SetStretchShrink
C#
public void SetStretchShrink(int amount);

Sets StretchShrink. Integer divisor of child SubViewport resolution when Stretch is enabled, at least 1. For example, a 128 by 96 container at 2 uses a 64 by 48 target. Does not shrink the container itself; changes target quality and cost.

Parameters
NameTypeDefault
amountint—
amount

Integer divisor of child SubViewport resolution when Stretch is enabled, at least 1. For example, a 128 by 96 container at 2 uses a 64 by 48 target. Does not shrink the container itself; changes target quality and cost.

_PropagateInputEventbool
# _PropagateInputEvent
C#
public virtual bool _PropagateInputEvent(InputEvent @event);

Return true to permit event forwarding to child viewports, false to stop it. Applies to positional and nonpositional input paths. Do not assume the base C# method permits the event: its default bool is false. Do not dispose the supplied InputEvent.

Parameters
NameTypeDefault
eventInputEvent—
event

Borrowed input event; true permits forwarding.

Returns bool

Return true to permit event forwarding to child viewports, false to stop it. Applies to positional and nonpositional input paths. Do not assume the base C# method permits the event: its default bool is false. Do not dispose the supplied InputEvent.

Reckfell Engine documentationBack to top ↑
QUICK LINKSGetting startedEntity hierarchyC# & .NET 10Scenes and prefabs
Reckfell guides and full API K
reckfellENGINE
RECKFELL ACCOUNT

Sign in

Sign in to your Reckfell account.

One account for the entire Reckfell platform.