
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
Run PIXI.js on node.
Headless WebGL rendering is enabled through the GL package.
To force canvas rendering:
const app = new PIXI.Application({forceCanvas: true});
Call app.view.toBuffer() to get a node Buffer.
Supported formats:
// toBuffer returns a Promise
// JPEG: (second argument specifies quality, value in range 0 to 1)
app.view.toBuffer('jpg', 1).then(buffer => {
fs.writeFileSync('che.jpg', buffer);
}).catch(err => {
console.error(err);
});
// PNG:
app.view.toBuffer('png').then(buffer => {
fs.writeFileSync('che.png', buffer);
}).catch(err => {
console.error(err);
});
// or simply use without arguments
app.view.toBuffer().then(buffer => {
fs.writeFileSync('che.png', buffer);
}).catch(err => {
console.error(err);
});
// PDF:
app.view.toBuffer('pdf').then(buffer => {
fs.writeFileSync('che.pdf', buffer);
}).catch(err => {
console.error(err);
});
// SVG:
app.view.toBuffer('svg').then(buffer => {
fs.writeFileSync('che.svg', buffer);
}).catch(err => {
console.error(err);
});
import fs from 'fs';
import {PIXI} from 'node-pixi';
const app = new PIXI.Application({backgroundColor: 0xff0000});
PIXI.loader.add('che', 'https://www.famousbirthdays.com/headshots/che-guevara-1.jpg');
PIXI.loader.onComplete.add(() => {
const che = new PIXI.Sprite(PIXI.loader.resources.che.texture);
// Setup the position of che
che.x = app.renderer.width / 2;
che.y = app.renderer.height / 2;
// Rotate around the center
che.anchor.x = 0.5;
che.anchor.y = 0.5;
// Add che to the scene we are building
app.stage.addChild(che);
app.render();
// toBuffer returns a Promise
app.view.toBuffer('jpg', 1).then(buffer => {
fs.writeFileSync('che.jpg', buffer);
}).catch(err => {
console.error(err);
});
});
PIXI.loader.onError.add((err) => {
console.error(err);
});
PIXI.loader.load();
FAQs
server side pixi.js
The npm package node-pixi receives a total of 10 weekly downloads. As such, node-pixi popularity was classified as not popular.
We found that node-pixi demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.