Nodes/KJNodes for ComfyUI/ImageTransformByNormalizedAmplitude
ComfyUI Node Runs on cloud

ImageTransformByNormalizedAmplitude

Make an image zoom and pan to the music

By kijai·Created 3 years ago·Updated about 9 hours ago· 2,930
ImageTransformByNormalizedAmplitude
  • normalized_amp
  • image
  • IMAGE
zoom_scale0.000
x_offset0
y_offset0
cumulativefalse

Audio-reactive visuals - the classic "zoom pulses on the beat" effect - need two pieces working together: something that turns an audio track into a per-frame amplitude signal, and something that turns that signal into an actual visual transform. This node is the second half. It's built specifically as a bridge to the separate ComfyUI-AudioScheduler pack by a1lazydog, which does the audio analysis; this node takes the amplitude values that pack produces and applies them as zoom and pan to an image, frame by frame.

Worth knowing up front: this is one half of a two-pack setup. If you don't already have AudioScheduler installed, this node has nothing meaningful to consume as its normalized_amp input.

How it works

For each frame, the node reads the corresponding normalized amplitude value and uses it to scale zoom_scale, x_offset, and y_offset - louder moments push the transform further, quieter moments pull it back. With cumulative enabled, each frame's offset builds on the previous one rather than resetting, so the image can drift progressively across a whole clip instead of just pulsing in place.

The inputs and outputs that matter

  • normalized_amp (type NORMALIZED_AMPLITUDE) - the amplitude signal from an AudioScheduler node. This is the entire reason the node exists; without a real audio-driven signal here, the transform has nothing meaningful to react to.
  • image - the image being transformed, per frame.
  • zoom_scale (default 0, range -1 to 1) - how much the amplitude drives zoom. Positive values zoom in on louder moments, negative values zoom out.
  • x_offset / y_offset (both default 0) - how much amplitude drives horizontal and vertical pan.
  • cumulative (default false) - whether each frame's transform accumulates on top of the previous frame's, rather than being computed fresh from the amplitude alone each time.

Output is a single IMAGE - the transformed batch, one frame per amplitude value, ready to feed a video-combine node.

How to install it

Via ComfyUI Manager: search "KJNodes for ComfyUI," install, restart. You'll also need ComfyUI-AudioScheduler installed separately through the same Manager, since this node only consumes its output type. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/kijai/ComfyUI-KJNodes
pip install -r ComfyUI-KJNodes/requirements.txt
git clone https://github.com/a1lazydog/ComfyUI-AudioScheduler

then restart ComfyUI.

Common issues & troubleshooting

normalized_amp won't connect to anything, or the node can't find a source for it. That type comes exclusively from AudioScheduler nodes - if that pack isn't installed, there's nothing producing it. Install it first, then come back to this node.

The effect is barely visible. zoom_scale and the offsets default to 0, meaning no transform at all - you have to explicitly dial them away from zero. Small values go a long way once you're driving a full clip's worth of frames, so start conservative and increase gradually.

The image drifts off-canvas over a long clip. That's cumulative doing exactly what it's meant to - offsets keep compounding frame over frame. If you want a bounded pulse effect rather than a runaway drift, turn cumulative off so each frame's transform is computed fresh from the amplitude alone.

This pairing (KJNodes plus AudioScheduler) is a narrow, community-assembled combination - modidex doesn't have dedicated coverage of audio-reactive ComfyUI workflows yet, so treat the AudioScheduler pack's own README as the source of truth for how amplitude extraction itself is tuned.

CategoryKJNodes/audio

Inputs (6)

NameTypeDefaultDescription
normalized_ampNORMALIZED_AMPLITUDE
zoom_scaleFLOAT0.000-1–1
x_offsetINT0-16383–16384
y_offsetINT0-16383–16384
cumulativeBOOLEANfalse
imageIMAGE

Outputs (1)

NameTypeDescription
IMAGEIMAGE