Skip to content

Mesh Attributes

App: apps/mesh_attributes/

A single triangle with per-vertex animation: each vertex’s position (px, py, pz) and color (r, g, b, a) are updated every frame via setVertexAttribute. Also shows a small GUI (window size, “Log” button) and terminal commands (help, reload) using #!command.

Terminal window
% ./plume3d mesh_attributes

or

Terminal window
% ./../plume3d .
  • Mesh — Three vertices; in update, vertex 0: animate X and red; vertex 1: Y and green; vertex 2: Z, blue, and alpha. No explicit flush() in this app; add _mesh.flush() after attribute updates if your backend requires it for dynamic data.
  • GUI — Window with current width/height and a “Log” button that logs mouse position with Logger.info.
  • Terminal#!command(description = "Print help message") help() lists commands (help, reload).
  • GraphicsloadShader, newMesh, drawMesh.
  • MeshsetVertexAttribute (e.g. "px", "py", "pz", "r", "g", "b", "a").
  • GuibeginWindow, layoutRowDynamic, label, buttonLabel, endWindow.
  • Window, Input, Logger.
  • Terminal: #!command on Game methods.