Please bookmark this page to avoid losing your image tool!

BSOD-Troo H Major 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, mirrorStr = 'yes', distortionStr = '15', hueShiftStr = '210') {
    const mirror = String(mirrorStr).toLowerCase() === 'yes';
    const distortion = parseFloat(distortionStr) || 15;
    const hueShift = parseFloat(hueShiftStr) || 210;

    const canvas = document.createElement('canvas');
    const w = originalImg.width;
    const h = originalImg.height;
    
    canvas.width = w;
    canvas.height = h;
    const ctx = canvas.getContext('2d');
    
    // Draw original to extract pixel data
    ctx.drawImage(originalImg, 0, 0);
    const srcData = ctx.getImageData(0, 0, w, h).data;
    
    // Create new image data for the effect
    const imgData = ctx.createImageData(w, h);
    const data = imgData.data;

    // Calculate hue rotation matrix (to achieve the weird color shifts common in "Major" effects)
    const angle = hueShift * Math.PI / 180;
    const cosA = Math.cos(angle);
    const sinA = Math.sin(angle);
    const sqrt1_3 = Math.sqrt(1.0 / 3.0);
    const one_minus_cosA = 1.0 - cosA;
    const one_third_one_minus_cosA = one_minus_cosA / 3.0;

    const matrix = [
        cosA + one_third_one_minus_cosA,
        one_third_one_minus_cosA - sqrt1_3 * sinA,
        one_third_one_minus_cosA + sqrt1_3 * sinA,

        one_third_one_minus_cosA + sqrt1_3 * sinA,
        cosA + one_third_one_minus_cosA,
        one_third_one_minus_cosA - sqrt1_3 * sinA,

        one_third_one_minus_cosA - sqrt1_3 * sinA,
        one_third_one_minus_cosA + sqrt1_3 * sinA,
        cosA + one_third_one_minus_cosA
    ];

    for (let y = 0; y < h; y++) {
        for (let x = 0; x < w; x++) {
            let srcY = y;
            let srcX = x;

            // Apply wavy horizontal distortion
            if (distortion > 0) {
                let wave = Math.sin((y / h) * 10 * Math.PI * 2) * distortion;
                srcX = Math.floor(srcX + wave);
            }

            // Apply horizontal mirror (classic YTP visual effect style)
            if (mirror && x > w / 2) {
                srcX = w - x;
            }

            // Keep within bounds
            srcX = Math.max(0, Math.min(w - 1, srcX));
            
            const srcIdx = (srcY * w + srcX) * 4;
            const dstIdx = (y * w + x) * 4;

            let r = srcData[srcIdx];
            let g = srcData[srcIdx + 1];
            let b = srcData[srcIdx + 2];
            const a = srcData[srcIdx + 3];

            // 1. Invert colors (fundamental to most "Major" meme effects)
            r = 255 - r;
            g = 255 - g;
            b = 255 - b;

            // 2. Apply Hue Shift
            let outR = r * matrix[0] + g * matrix[1] + b * matrix[2];
            let outG = r * matrix[3] + g * matrix[4] + b * matrix[5];
            let outB = r * matrix[6] + g * matrix[7] + b * matrix[8];

            // 3. Emphasize Blue channel heavily for the "BSOD" (Blue Screen of Death) vibe
            outB = outB * 1.3 + 30;
            outR = outR * 0.9;
            
            // 4. Boost Contrast violently
            outR = ((outR / 255 - 0.5) * 1.6 + 0.5) * 255;
            outG = ((outG / 255 - 0.5) * 1.6 + 0.5) * 255;
            outB = ((outB / 255 - 0.5) * 1.6 + 0.5) * 255;

            // Clamp and assign exactly to new image data
            data[dstIdx] = Math.max(0, Math.min(255, outR));
            data[dstIdx + 1] = Math.max(0, Math.min(255, outG));
            data[dstIdx + 2] = Math.max(0, Math.min(255, outB));
            data[dstIdx + 3] = a;
        }
    }

    ctx.putImageData(imgData, 0, 0);

    // Apply faint BSOD-like scanline artifacts
    ctx.fillStyle = 'rgba(0, 0, 0, 0.15)';
    for (let i = 0; i < h; i += 4) {
        ctx.fillRect(0, i, w, 1);
    }
    
    ctx.fillStyle = 'rgba(255, 255, 255, 0.05)';
    for (let i = 2; i < h; i += 4) {
        ctx.fillRect(0, i, w, 1);
    }

    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 BSOD-Troo H Major Image Effect Generator is a tool designed to apply stylized, high-contrast visual distortions to images. It can transform uploaded images using color inversion, hue shifting, and heavy blue-channel emphasis to create a specific glitch-like aesthetic. The tool also offers options for horizontal mirroring, wavy geometric distortion, and the addition of scanline artifacts. This tool is ideal for users looking to create meme-style graphics, digital art with a glitch aesthetic, or experimental visual content for social media and video editing.

Leave a Reply

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