Gondwana Game Engine
Gondwana is a cross-platform 2.5D game and rendering engine written in C#/.NET 8. It provides fine-grained control over rendering, timing, and scene composition, with built-in support for parallax, z-ordering, pixel overhang, collision detection, and particle effects. Gondwana targets desktop, mobile, and web platforms using SkiaSharp for graphics and NAudio for sound.
Loading...
Searching...
No Matches
Gondwana.Drawing.Direct.IDirectDrawable Interface Reference

Represents any drawable object (movable or static) that can render directly to a RenderSurfaceHost, report its position and bounds, and optionally support movement or composition. More...

Inheritance diagram for Gondwana.Drawing.Direct.IDirectDrawable:
Gondwana.Drawing.IDrawable Gondwana.Drawing.Direct.DirectComposite Gondwana.Drawing.Direct.DirectDrawingBase Gondwana.Drawing.Direct.DirectDrawingMovableBase Gondwana.Drawing.Direct.DirectVideo Gondwana.Drawing.Direct.DirectImage Gondwana.Drawing.Direct.DirectRectangle Gondwana.Drawing.Direct.Particles.ParticleSurface Gondwana.Drawing.Direct.TextBlock

Public Member Functions

void Update (long tick)
 Updates the state of the object based on the specified tick value.
Public Member Functions inherited from Gondwana.Drawing.IDrawable
RectangleF GetDrawLocationScreen (View view)
 Computes the object's destination rectangle in SCREEN pixels for rendering on the Backbuffer, using the provided View to project from world-space.
void Draw (BackbufferBase backbuffer, RectangleF destRectScreen)
 Draws the object to the Backbuffer using the provided SCREEN-space destination rectangle. The rectangle is assumed to already be projected into screen-space; no world-to-screen conversion should occur within this method.

Properties

RenderSurfaceHostBase RenderSurfaceHost [get]
 The rendering surface to which this drawable belongs.
DirectDrawingMode Mode [get]
 Gets the drawing mode that determines where and how this drawable is rendered.
Rectangle ScreenBounds [get]
 The bounding rectangle of this drawable in SCREEN space.
Rectangle WorldBounds [get]
 The bounding rectangle of this drawable in WORLD space.
Properties inherited from Gondwana.Drawing.IDrawable
Guid Id [get]
 Auto-assigned unique identifier for the object.
string? Nickname [get]
 Optional human-readable name associated with the object.
bool Visible [get]
 Gets a value indicating whether the object is visible.
int ZOrder [get]
 Gets the z-order of the element, which determines its visual stacking order relative to other elements. Higher z-order values are drawn on top of lower ones.

Events

EventHandler< IDirectDrawable >? Disposing
 Occurs when the object is being disposed.

Detailed Description

Represents any drawable object (movable or static) that can render directly to a RenderSurfaceHost, report its position and bounds, and optionally support movement or composition.

Member Function Documentation

◆ Update()

void Gondwana.Drawing.Direct.IDirectDrawable.Update ( long tick)

Property Documentation

◆ Mode

DirectDrawingMode Gondwana.Drawing.Direct.IDirectDrawable.Mode
get

Gets the drawing mode that determines where and how this drawable is rendered.

The drawing mode defines the coordinate space and rendering lifecycle:

  • DirectDrawingMode.SceneLayer Renders in world space as part of a scene layer and is affected by camera position, zoom, and parallax.
  • DirectDrawingMode.View Renders in screen space at the view level and is independent of camera movement, making it suitable for UI, overlays, and debug visuals.

Implemented in Gondwana.Drawing.Direct.DirectComposite, and Gondwana.Drawing.Direct.DirectDrawingBase.

◆ RenderSurfaceHost

RenderSurfaceHostBase Gondwana.Drawing.Direct.IDirectDrawable.RenderSurfaceHost
get

The rendering surface to which this drawable belongs.

Implemented in Gondwana.Drawing.Direct.DirectComposite, and Gondwana.Drawing.Direct.DirectDrawingBase.

◆ ScreenBounds

Rectangle Gondwana.Drawing.Direct.IDirectDrawable.ScreenBounds
get

The bounding rectangle of this drawable in SCREEN space.

Implemented in Gondwana.Drawing.Direct.DirectComposite, and Gondwana.Drawing.Direct.DirectDrawingBase.

◆ WorldBounds

Rectangle Gondwana.Drawing.Direct.IDirectDrawable.WorldBounds
get

The bounding rectangle of this drawable in WORLD space.

Implemented in Gondwana.Drawing.Direct.DirectComposite, and Gondwana.Drawing.Direct.DirectDrawingBase.

Event Documentation

◆ Disposing

EventHandler<IDirectDrawable>? Gondwana.Drawing.Direct.IDirectDrawable.Disposing

Occurs when the object is being disposed.