Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
pixijs avatar

Pixijs Scene Mesh

  • 2.9k installs
  • 293 repo stars
  • Updated June 4, 2026
  • pixijs/pixijs-skills

pixijs-scene-mesh documents PixiJS v8 Mesh, MeshGeometry, and specialized mesh subclasses for custom textured geometry.

About

The pixijs-scene-mesh skill covers rendering custom geometry in PixiJS v8 using Mesh with MeshGeometry plus specialized subclasses MeshSimple, MeshPlane, MeshRope, and PerspectiveMesh. The base Mesh requires hand-built positions, uvs, indices, and topology while subclasses build geometry internally from texture and shape parameters. Decision guidance maps use cases: deformable rectangles use MeshPlane, rope trails use MeshRope, 2.5D tilted cards use PerspectiveMesh, per-frame vertex animation uses MeshSimple, and custom shaders need base Mesh with pixijs-custom-rendering. Meshes are leaf nodes that cannot have children; grouping uses Container wrappers. Batching applies only under auto rules with MeshGeometry, no custom shader, and at most one hundred vertices. Common mistakes include using removed v7 SimpleMesh names, wrong topology placement on geometry not mesh, and expecting true 3D depth from PerspectiveMesh UV-level perspective correction only in 2D scenes.

  • Mesh subclasses: MeshSimple, MeshPlane, MeshRope, PerspectiveMesh for common shapes.
  • Base Mesh needs MeshGeometry with positions, uvs, indices, and topology.
  • Meshes are leaf nodes; wrap multiple meshes in a Container.
  • Batching requires MeshGeometry, no custom shader, and auto batchMode rules.
  • Sprite covers simple quads; meshes handle deformation, ropes, and perspective.

Pixijs Scene Mesh by the numbers

  • 2,926 all-time installs (skills.sh)
  • +211 installs in the week ending Jul 28, 2026 (Skillselion tracking)
  • Ranked #177 of 2,277 Frontend Development skills by installs in the Skillselion catalog
  • Security screen: LOW risk (skills.sh audit)
  • Data as of Jul 28, 2026 (Skillselion catalog sync)
At a glance

pixijs-scene-mesh capabilities & compatibility

Capabilities
mesh subclass selection guide for common shapes · meshgeometry vertex buffer configuration · batching rules for meshes without custom shaders · perspective and rope deformation patterns · v7 simplemesh to v8 mesh rename migration warnin
Use cases
frontend · ui design
From the docs

What pixijs-scene-mesh says it does

Topology is on the geometry, not the mesh
SKILL.md
npx skills add https://github.com/pixijs/pixijs-skills --skill pixijs-scene-mesh

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs2.9k
repo stars293
Security audit3 / 3 scanners passed
Last updatedJune 4, 2026
Repositorypixijs/pixijs-skills

How do I render deformed rectangles, rope trails, or perspective cards with textures in PixiJS v8?

Render custom textured geometry in PixiJS v8 with Mesh, MeshPlane, MeshRope, and PerspectiveMesh variants.

Who is it for?

PixiJS v8 projects needing custom geometry beyond Sprite for games and interactive graphics.

Skip if: Skip for simple textured quads use Sprite, or true 3D rendering use a dedicated 3D library.

When should I use this skill?

User asks about Mesh, MeshPlane, MeshRope, PerspectiveMesh, MeshGeometry, or custom PixiJS geometry.

What you get

Correct mesh subclass or base Mesh with MeshGeometry, topology, and batching-aware configuration.

  • PerspectiveMesh scene object
  • Perspective-projected textured plane

By the numbers

  • Example PerspectiveMesh configuration uses verticesX: 20 and verticesY: 20
  • PerspectiveMesh requires four corner coordinate pairs for projection

Files

SKILL.mdMarkdownGitHub ↗

Meshes render arbitrary 2D (or perspective-projected) geometry with a texture or custom shader. PixiJS ships the base Mesh class plus four specialized subclasses for common shapes: MeshSimple, MeshPlane, MeshRope, and PerspectiveMesh. Pick the subclass that matches your shape; drop to the base Mesh when you need full vertex-level control or a custom shader.

Assumes familiarity with pixijs-scene-core-concepts. Meshes are leaf nodes; they cannot have children. Wrap multiple meshes in a Container to group them.

Quick Start

const texture = await Assets.load("pattern.png");

const geometry = new MeshGeometry({
  positions: new Float32Array([0, 0, 100, 0, 100, 100, 0, 100]),
  uvs: new Float32Array([0, 0, 1, 0, 1, 1, 0, 1]),
  indices: new Uint32Array([0, 1, 2, 0, 2, 3]),
  topology: "triangle-list",
});

const mesh = new Mesh({
  geometry,
  texture,
  roundPixels: false,
});
app.stage.addChild(mesh);

Every Mesh subclass takes a single options object. The base Mesh requires a geometry; subclasses (MeshSimple, MeshPlane, MeshRope, PerspectiveMesh) build the geometry internally and require a texture instead. See each variant's reference for the full field list.

Variants

VariantUse whenTrade-offsReference
MeshFull control, custom geometry, custom shadersYou build the MeshGeometry yourselfreferences/mesh.md
MeshSimpleQuick textured shapes with per-frame vertex animationThin wrapper; auto-updates the vertex bufferreferences/mesh-simple.md
MeshPlaneSubdivided textured rectangle for distortion effectsFixed topology; verticesX/verticesY control densityreferences/mesh-plane.md
MeshRopeTexture following a polyline pathBent at each point; needs many points for smooth curvesreferences/mesh-rope.md
PerspectiveMesh2D plane with perspective cornersNot true 3D; UV-level perspective correction onlyreferences/mesh-perspective.md

When to use what

  • "I need a textured quad"Sprite (see pixijs-scene-sprite), not a mesh. Meshes are for cases Sprite can't express.
  • "I need to deform a textured rectangle"MeshPlane. Set verticesX/verticesY for the desired smoothness.
  • "I need a rope or trail that follows points"MeshRope. Control thickness with width; use textureScale: 0 to stretch or > 0 to repeat.
  • "I need a tilted 2D card or floor"PerspectiveMesh. Pass four corner positions; not real 3D but good enough for 2.5D effects.
  • "I need per-frame animated vertices with a simple shape"MeshSimple. It handles the buffer-update dance for you.
  • "I need a custom shader or unusual geometry" → Base Mesh with a hand-built MeshGeometry. See pixijs-custom-rendering for shader authoring.
  • "I need true 3D rendering" → Use a dedicated 3D library. PerspectiveMesh simulates perspective at the UV level but has no depth buffer.

Quick concepts

MeshGeometry owns the vertex data

MeshGeometry holds the positions, uvs, indices, and topology. You can share one geometry across multiple Mesh instances; positions are reference-counted.

Batching

A mesh batches (combines with other draw calls) only if it uses MeshGeometry, has no custom shader, no depth or culling state, and the 'auto' rule (batchMode = 'auto' and ≤100 vertices). Custom shaders always render independently.

Topology is on the geometry, not the mesh

new MeshGeometry({ topology: 'triangle-strip' }); topology is a geometry property. The default is 'triangle-list'; set it explicitly if your data is organized differently.

Extra knobs

  • new MeshGeometry({ shrinkBuffersToFit: true }) — trims GPU buffer storage to the actual vertex count on creation. Use it when feeding large, one-shot geometries.
  • Mesh.containsPoint(point) — topology-aware hit test that walks the triangles. Works with any MeshGeometry, including custom layouts.
  • new Mesh({ geometry, state }) — pass a State object to control blend, depth, and culling. Batching is disabled automatically if depth or culling flags are set. Defaults to State.for2d() when omitted.

Common Mistakes

[HIGH] Using old SimpleMesh / SimplePlane / SimpleRope names

Wrong:

import { SimpleRope } from "pixi.js";
const rope = new SimpleRope(texture, points);

Correct:

import { MeshRope } from "pixi.js";
const rope = new MeshRope({ texture, points });

Renamed in v8: SimpleMeshMeshSimple, SimplePlaneMeshPlane, SimpleRopeMeshRope. All switched to options-object constructors.

[HIGH] Positional constructor args for MeshGeometry

Wrong:

const geom = new MeshGeometry(vertices, uvs, indices);

Correct:

const geom = new MeshGeometry({
  positions: vertices,
  uvs,
  indices,
  topology: "triangle-list",
});

v8 uses an options object. Note the property is positions, not vertices; the vertices name is only used by MeshSimple.

[MEDIUM] Adding children to a mesh

Wrong:

mesh.addChild(otherMesh);

Correct:

const group = new Container();
group.addChild(mesh, otherMesh);

Mesh sets allowChildren = false. Adding children logs a deprecation warning. Group meshes inside a plain Container.

API Reference

Related skills

How it compares

Pick pixijs-scene-mesh over generic PixiJS sprite skills when textures must distort with perspective across four arbitrary corner points.

FAQ

When should I use Sprite instead of Mesh?

Use Sprite for simple textured quads; meshes are for deformation, ropes, perspective, or custom shaders.

Where does topology belong in v8?

Topology is a MeshGeometry property such as triangle-list, not a Mesh property.

Can meshes have child display objects?

No. Meshes are leaf nodes; wrap them in a Container to group with other objects.

Is Pixijs Scene Mesh safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.