Jul-04-2017, 09:58 AM
Hi!
I was hoping you could help me with a short script that will likely take you guys 5 Minutes to put together while I would spend 20 nights and get inferior results.
The goal is to provide a sequence of values that will enable Arduino users to animate a drop on an addressable LED strip. I will upload a video of the result to youtube and provide the values to anyone who wants to do something similar.
The physics of free falling are simple but for the formation of a new drop, I'd like to use this real life example: youtube.com/watch?v=c4MUTij8f6I&t=202s
Of course I will center the video and clip it to contain only one drop, coming from the top (like around the 3:30 mark).
I believe Python is ideal for the task but my knowledge is very basic. I can read most code and fix simple stuff that doesn't work but I don't know any of the libraries' capabilities so I'd be searching forever to do this. Algorithm looks like this:
Script that accepts 3 parameters: (x, y, Path and Filename to a video file)
Can you help me with that?
Thank you very much!
Hajo
I was hoping you could help me with a short script that will likely take you guys 5 Minutes to put together while I would spend 20 nights and get inferior results.
The goal is to provide a sequence of values that will enable Arduino users to animate a drop on an addressable LED strip. I will upload a video of the result to youtube and provide the values to anyone who wants to do something similar.
The physics of free falling are simple but for the formation of a new drop, I'd like to use this real life example: youtube.com/watch?v=c4MUTij8f6I&t=202s
Of course I will center the video and clip it to contain only one drop, coming from the top (like around the 3:30 mark).
I believe Python is ideal for the task but my knowledge is very basic. I can read most code and fix simple stuff that doesn't work but I don't know any of the libraries' capabilities so I'd be searching forever to do this. Algorithm looks like this:
Script that accepts 3 parameters: (x, y, Path and Filename to a video file)
Take every xth frame from a given video (or sequence of pictures, if that is easier) Convert picture to black and white Every yth line (row) in the picture report back the first occurance from the left (column) of a black pixel. (-1 if no black pixel in that line). output on stdout: current X [tab] current Y [tab] Position of black pixelOnce I have the data, I will analyse if it can be approximated by a 3D function or whether a look-up table will be better and make the arduino part public.
Can you help me with that?
Thank you very much!
Hajo