← All scene elements
SCENE ELEMENT / 03

Image

Static textures from the scene asset directory.

LIVE WEB PLAYER

See it respond.

The same raylib runtime, compiled to WebAssembly. Load this example, inject MQTT messages and watch its published events.

Loading WebAssembly…
MQTT I/O
Waiting for runtime…

The browser requires a user action before the scene is loaded. Click Load demo scene first. MQTT is emulated and never leaves this page. Shaders are disabled in the web build; GPIO is hardware-only.

Draws a texture from media/assets/ into a rectangle.

Configuration

FieldDescription
typeimage
filePNG/JPG/BMP asset filename
posTop-left position
sizeOutput width and height
layerDraw order

Copy-and-paste JSON

json
{
  "type": "image",
  "id": "logo",
  "pos": [60, 40],
  "size": [320, 180],
  "file": "logo.png",
  "layer": 2
}

MQTT

Image has no file-switch command. It supports common visibility control:

text
ergs/rpi01/visible/logo                  OFF
ergs/rpi01/visible/logo                  ON