An exploration of Thomas Edisons films

edited May 2016 in Share Your Work

Hi guys,

I've been playing around with processing a lot lately and I made my first video with it. Let me know what you think, I'd really appreciate some feedback.

Not sure if the video is showing up, but here's the link https://vimeo.com/166587599

Comments

  • Looks really neat. Is the video done in real time? Would be nice to give an overview of how you did it so others can experiment with the technique.

  • Thanks! The video is not run in real time, it's actually pretty slow at that resolution so I had to export every frame and use the movie maker. It can be run at real time in lower resolution. Might be a problem with the code as well, as I'm not a very experienced programmer.

    The gist of it is very simple. There may be better ways (way way better) to achieve this. A

    1. I load a video. Every frame, I go through every pixel, skipping x,y amount (whatever looked good, I think in this case it was every 4 pixels). I store the x,y coordinates as I go through each frame into a list. I also store the brightness of every pixel. I use a PVector object to do so PVector(x,y,brightness). In other words (in python):

      def fetchPixels(): pixelcollection = []

      for x in range(0,tSource.width,skip):
         for y in range(0,tSource.height,skip):
             loc = x + y * tSource.width 
             if brightness(tSource.pixels[loc]) < minBright or tSource.pixels[loc] > maxBright:
                 pixelcollection.append(PVector(x,y,map(brightness(tSource.pixels[loc]),minBright,maxBright, minDepth,maxDepth)))
      
      return pixelcollection 
      
    2. I create a grid of boxes and place into the canvas. I use the information I stored in pixelcollection to set the x,y,z values, where minBright and maxBright are thresholds regarding the brightness I actually am interested in . So say I stores the information for every pixel that has more than 100 in brigthness, and less than 255 (max, anyway) I map it to some depth, (minDepth, maxDepth). I played around with these values until I got a result that was interesting to me. In other words, the brightness value is used to map the z axis of every box.

    3. I clean pixelcollection after eachframe, and refresh the output. I also used a blending mode which allowed for the small trails that are left after every frame. I scale the output to the desired size. I export every frame and then compile them using the built in processing movie maker. I then went into premiere and put in the music and sound.

    Hope it's clear enough :)

Sign In or Register to comment.