Please bookmark this page to avoid losing your image tool!

Slow Wobble 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, amplitude = 20, waveCount = 2.5, speed = 1.5) {
    // Parse parameters to ensure numbers
    amplitude = Number(amplitude);
    waveCount = Number(waveCount);
    speed = Number(speed);

    // Create a new canvas
    const canvas = document.createElement('canvas');
    const width = originalImg.width;
    const height = originalImg.height;

    // Expand the canvas width slightly so the wobbling image doesn't clip at the edges
    canvas.width = width + Math.abs(amplitude) * 2;
    canvas.height = height;
    
    const ctx = canvas.getContext('2d');

    // To ensure optimal performance on huge images, dynamically define the slice step size
    // so we cap the max number of draw calls per frame (~800 max).
    const step = Math.max(1, Math.floor(height / 800)); 
    
    // Calculate how many waves to fit in the image's height
    const freq = (Math.PI * 2 * waveCount) / height;

    let startTime = performance.now();
    let hasBeenConnected = false;

    // Animation loop
    function render(time) {
        // Simple garbage collection / memory leak prevention:
        // If the canvas was appended to the DOM and then removed, we stop the animation.
        if (canvas.isConnected) {
            hasBeenConnected = true;
        } else if (hasBeenConnected) {
            return;
        }

        // Clear previous frame
        ctx.clearRect(0, 0, canvas.width, canvas.height);
        
        const elapsed = (time - startTime) / 1000;
        const phase = speed * elapsed;

        // Slice the image horizontally and draw each slice with a sine wave offset
        for (let y = 0; y < height; y += step) {
            const sliceHeight = Math.min(step, height - y);
            const offset = Math.sin(y * freq + phase) * amplitude;
            
            ctx.drawImage(
                originalImg,
                0, y, width, sliceHeight,                // Source location & dimensions
                amplitude + offset, y, width, sliceHeight // Destination location & dimensions (with offset)
            );
        }

        // Request the next frame
        requestAnimationFrame(render);
    }

    // Start the recursive animation
    requestAnimationFrame(render);

    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 Slow Wobble Image Effect Generator creates a fluid, animated distortion effect on uploaded images by applying a sine-wave motion. Users can customize the visual output by adjusting the amplitude of the movement, the number of waves across the image, and the speed of the animation. This tool is ideal for creating eye-catching social media content, adding psychedelic or water-like textures to digital art, or generating dynamic visual elements for web design and presentations.

Leave a Reply

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

Other Image Tools:

Parrot Effect Image Generator

Talking Pierre Map Image Effect Generator

Bulge X Image Effect Generator

UN Owen Was X Image Effect Generator

Sunflowered Image Effect Generator

Doorbell Image Generator

Dewdrop Image Effect Generator

Image Crystal Drop Effect Applicator

Chess Image Generator

Cave Image Generator

Bongo Image Tool

Image Bongo Generator

Birdsong Image Generator

Image Bell Generator

Colorado Driver License Fictional Person Generator

Fake Driver License Image Generator

35mm 2960×1800 Ratio Resolution Image Resizer

The Lion King 1994 IMAX 70mm Movie Trailer Image

Big Hero 6 Character Replacement AI Tool for Video and Image

Big Hero 6 Character Replace AI Image and Video Tool

Big Hero 6 To Big Hero 6 The Series AU Replacement Tool

Big Hero 6 To Big Hero 6 The Series AU Image and Video Replacer

Slow Motion Video and Audio Playback Tool

Image Speed Reduction Tool

YouTube Stats For Nerds Audio Volume Normalization Analysis Tool

YouTube Stats For Nerds Audio Volume Normalization Information Tool

YouTube Stats For Nerds Volume Normalization Analyzer

YouTube Stats For Nerds Audio Volume Normalization Analyzer

YouTube Stats For Nerds Volume Normalization Analysis Tool

YouTube Stats For Nerds Audio Volume Normalization Information Display

YouTube Stats For Nerds Volume Normalization Information Tool

YouTube Stats For Nerds Audio Volume and Codec Information Extractor

YouTube Audio Stats Volume Normalization Tool for Mp2 Mp3 Opus and Ac3

Audio Volume Normalizer for Mp2 Mp3 Opus and Ac3 Formats

YouTube Audio Stats Volume Normalizer For Mp2 Mp3 Opus and Ac3 Formats

United States of America Federal Social Security Card Template Maker

See All →