Skip to content
Version 2.11.0
↓ Get the launcher

RenderTextureHostElement record

Hosts a live render texture in a fixed-size box (e.g. the Entity Inspector’s 3D portrait). The framework binds the boxed UnityEngine.Texture returned by Texture onto a uGUI RawImage and re-pulls it each frame, so a texture created after the window builds still appears. Renderer-neutral — the texture crosses the boundary as Object so Abstractions names no Unity type; null = blank box.

public record RenderTextureHostElement : IEquatable<HudElement>
name description
RenderTextureHostElement(…) Hosts a live render texture in a fixed-size box (e.g. the Entity Inspector’s 3D portrait). The framework binds the boxed UnityEngine.Texture returned by Texture onto a uGUI RawImage and re-pulls it each frame, so a texture created after the window builds still appears. Renderer-neutral — the texture crosses the boundary as Object so Abstractions names no Unity type; null = blank box.
Height { get; set; } Box height in px.
OnDrag { get; set; } Optional: called with pointer-drag deltas (dx,dy in px) while the box is dragged — e.g. to orbit a 3D preview camera. Null = the box ignores drags.
OnPan { get; set; } Optional: called with pointer-drag deltas (dx,dy in px) while the box is dragged with Shift held — e.g. to pan a 3D preview camera. Null = Shift+drag falls back to OnDrag.
OnScroll { get; set; } Optional: called with the scroll-wheel delta while the cursor is over the box — e.g. to zoom a 3D preview. Null = the box ignores scrolls.
OnViewportResize { get; set; } Optional: called each frame with the box’s current pixel size (w,h) so a 3D preview can size its render texture + projection to the (resizable) pane — fills it with no letterbox/stretch.
Texture { get; set; } Supplies the boxed render texture to display (null until ready).
TransparentBackground { get; set; } When true the pane draws NO opaque backdrop behind the texture — the render texture’s own alpha shows whatever is behind the pane (the window chrome), so only the rendered subject is visible. Default false = solid dark backdrop.
Width { get; set; } Box width in px.