
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
A GPU-accelerated image processing library for the web, powered by WebGL and REGL. Perform real-time image transformations with blur, color adjustments, LUTs, and more.
⚠️ Beta software: SharpGPU is actively under development and not yet ready for production workloads.
Buffer, ReadableStream, filesystem paths)SharpGPU.frommetadata())Buffer outputs (toFile, toBuffer)toCanvas)toBlob)fit: cover, background)lut())pipeline(), clone() semantics for concurrency)queue(), limitInputPixels)bun add sharp-gpu
import { SharpGPU } from "sharp-gpu";
// Load an image and apply transformations
const canvas = document.getElementById("output") as HTMLCanvasElement;
const image = await SharpGPU.from("/path/to/image.png");
await image
.blur(10)
.modulate({
brightness: 1.2,
saturation: 1.5,
hue: 30,
})
.toCanvas(canvas);
// Or export as a blob
const blob = await image.blur(5).grayscale().toBlob("image/png");
// Blur with radius
.blur(radius: number)
// Color modulation
.modulate({
brightness?: number, // 0-2 (default: 1)
saturation?: number, // 0-2 (default: 1)
hue?: number, // 0-360 degrees (default: 0)
lightness?: number, // -1 to 1 (default: 0)
tint?: [r, g, b] // 0-1 normalized RGB (default: [1, 1, 1])
})
// Linear adjustment (scale + offset per channel, optional alpha)
.linear(multiply: number | [r, g, b] | [r, g, b, a], add?: number | [r, g, b] | [r, g, b, a])
// Gamma correction (default gamma=2.2, gammaOut=1.0)
.gamma(gamma?: number | [r, g, b], gammaOut?: number | [r, g, b])
// Channel inversion
.negate()
// Grayscale (shorthand for saturation: 0)
.grayscale()
// Tint (helper around linear scaling)
.tint([r, g, b])
// Look-Up Table (custom color grading)
.lut((x: number) => number) // Function mapping
.lut([...values]) // Array of values
// Resize
.resize({ width: number, height: number })
# Install dependencies
bun install
# Build the library
bun run build
# Watch mode for development
bun run dev
# Type checking
bun run typecheck
# Run example
cd example && bun install && bun run dev
Check out the example/ folder for a working interactive demo with Tweakpane controls.
MIT
FAQs
GPU-accelerated image processing library for the web
The npm package sharp-gpu receives a total of 3 weekly downloads. As such, sharp-gpu popularity was classified as not popular.
We found that sharp-gpu demonstrated a healthy version release cadence and project activity because the last version was released less than 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.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.