Directional halo on 2D graphic

i will start from something like:

PImage screen;
void setup() {
  size(400, 400);  
  frameRate(25);
  screen=createImage(width, height, RGB);
  stroke(255);
  fill(255);
  rectMode(CENTER);
  background(0);
}

void draw() {
  //fade
  tint(color(255-random(34), 255-random(34), 255-random(34)), 245);
  image(screen, 4*sin(((float)frameCount)/10.0), -1);

  //main image
  rect(width/2, height/2, 55+44*sin(((float)frameCount)/30.0), 55+14*sin(((float)frameCount)/14.0));
  loadPixels();
  screen=this.copy();
}

and doing some pixels manipulation more complex than tint()

1 Like