I have created a grid of DirectShapes and I am attempting to change their material based on the brightness values of the pixels of a black & white image. In other words, I am trying to recreate an image with different materials assigned to a grid of geometric shapes in Revit.
It is my understanding that the Color.Brightness node returns a (more-or-less) infinite number of values between 0 and 1. My ultimate goal is to assign each DirectShape with 1 of 3 different materials, so I am trying to create a logic that says, "Where a pixel’s Color.Brightness is less than .33, assign the corresponding DirectShape the “White Plastic” material. Values greater than .33 but less than .66 get assigned the “Pine” material, and lastly values greater than .66 get the “Plastic-Gen-Black” material. I have started this script, but have taken it as far as I can and am now a bit stuck.
I am fairly new to Dynamo… is this the simplest way to achieve my goal? Also, I am trying to do this without the use of Code Blocks so that I can force myself to learn the tools native to Dynamo first. Any help would be appreciated.