Please bookmark this page to avoid losing your image tool!

IO Nightmare Image Effect Generator

(Free & Supports Bulk Upload)

Drag & drop your images here or

The result will appear here...
You can edit the below JavaScript code to customize the image tool.
function processImage(originalImg, intensity = 50, glitchAmount = 20, addScanlines = 1) {
    // Ensure parameters are numbers
    intensity = Number(intensity) || 50;
    glitchAmount = Number(glitchAmount) || 20;
    addScanlines = Number(addScanlines);

    const canvas = document.createElement('canvas');
    const width = originalImg.width;
    const height = originalImg.height;
    canvas.width = width;
    canvas.height = height;
    
    const ctx = canvas.getContext('2d');
    
    // Draw the original image to our canvas
    ctx.drawImage(originalImg, 0, 0);

    // Apply standard IO Error Glitch (block shifting)
    const numGlitchBlocks = Math.floor((glitchAmount * width * height) / 80000);
    for (let i = 0; i < numGlitchBlocks; i++) {
        // Random dimensions for the glitch blocks
        const blockW = Math.random() * (width / 4) + 10;
        const blockH = Math.random() * 30 + 2;
        const blockX = Math.random() * width;
        const blockY = Math.random() * height;
        
        // Random offsets based on amount
        const offsetX = (Math.random() - 0.5) * glitchAmount * 4;
        const offsetY = (Math.random() - 0.2) * glitchAmount;
        
        // Copy-paste blocks slightly offset to create data-corruption look
        ctx.drawImage(
            canvas, 
            blockX, blockY, blockW, blockH, 
            blockX + offsetX, blockY + offsetY, blockW, blockH
        );
    }

    // Process pixels for the "Nightmare" color grading and effects
    const imgData = ctx.getImageData(0, 0, width, height);
    const data = imgData.data;
    
    // Create an intermediate array to avoid overwriting during offset fetching
    const outData = new Uint8ClampedArray(data.length);

    // Calculate chromatic aberration offsets
    const offsetR = Math.floor(glitchAmount / 3) * 4;
    const offsetB = -Math.floor(glitchAmount / 3) * 4;
    
    const centerX = width / 2;
    const centerY = height / 2;
    const maxDist = Math.sqrt(centerX * centerX + centerY * centerY);

    for (let y = 0; y < height; y++) {
        for (let x = 0; x < width; x++) {
            const i = (y * width + x) * 4;
            
            // Chromatic aberration
            let rIndex = i + offsetR;
            let bIndex = i + offsetB;
            
            // Bounds check
            if (rIndex < 0 || rIndex >= data.length) rIndex = i;
            if (bIndex < 0 || bIndex >= data.length) bIndex = i;

            let r = data[rIndex];
            let g = data[i + 1]; // Green stays in center
            let b = data[bIndex + 2];
            const a = data[i + 3];

            // Nightmare Vignette & Contrast
            const dx = x - centerX;
            const dy = y - centerY;
            const dist = Math.sqrt(dx * dx + dy * dy);
            // Vignette factor (1 at center, drops towards edges)
            const vignette = Math.max(0, 1 - (dist / maxDist) * (1 + intensity / 100));

            // Intensity affects how deep the red grading goes
            const redFactor = intensity / 25;
            
            // Deep red emphasis, suppress green and blue
            r = Math.min(255, r + 40 * redFactor);
            g = Math.max(0, g - 20 * redFactor);
            b = Math.max(0, b - 20 * redFactor);

            // Calculate luminance
            const luma = 0.299 * r + 0.587 * g + 0.114 * b;

            // Thresholding to create a stark, creepy visual style
            if (luma < 80) {
                // Crush shadows mainly into dark reds and blacks
                r = r * 0.6; 
                g = g * 0.2; 
                b = b * 0.2;
            } else if (luma > 180) {
                // Highlighting edges / inverted peaks
                r = 255; 
                g = g * 0.8; 
                b = b * 0.8;
            }

            // Occasional dead/inverted pixel (Digital IO Nightmare Noise)
            if (Math.random() < (glitchAmount / 1000)) {
                r = 255 - r;
                g = 0;
                b = 0; // Blood red dead pixels
            }

            // Apply Scanlines
            if (addScanlines > 0 && y % 3 === 0) {
                r *= 0.5;
                g *= 0.5;
                b *= 0.5;
            }

            // Apply Vignette overlay
            r *= vignette;
            g *= vignette;
            b *= vignette;

            outData[i] = r;
            outData[i + 1] = g;
            outData[i + 2] = b;
            outData[i + 3] = a;
        }
    }

    // Apply processed pixels back
    for(let i = 0; i < data.length; i++) {
        data[i] = outData[i];
    }
    
    ctx.putImageData(imgData, 0, 0);

    return canvas;
}

Free Image Tool Creator

Can't find the image tool you're looking for?
Create one based on your own needs now!

Description

The IO Nightmare Image Effect Generator is an image processing tool designed to apply a dark, distorted, and glitchy aesthetic to your photos. It utilizes digital corruption effects such as block shifting, chromatic aberration, and scanlines to simulate an IO error or data corruption look. Additionally, it features specialized color grading that emphasizes deep reds, high-contrast shadows, and vignetting to create a creepy, high-intensity atmosphere. This tool is ideal for creators looking to produce horror-themed visuals, glitch art, or experimental digital aesthetics for social media, gaming assets, or creative projects.

Leave a Reply

Your email address will not be published. Required fields are marked *