Final Project: Emotions in Color

Concept

With my project I am attempting to translate human emotions into color. It is a personal experience during which a participant is asked to input 5 colors for 5 different emotions. The colors are then used to generate a personal generative artwork that portrays the unique color gradient of the participant.

In addition to its primary goal, the project carries an educational aspect. I aim to provide participants with a deeper understanding of the interplay between RGB values and the diverse outcomes arising from various color mixtures. This dual-purpose project invites individuals to explore their emotions creatively while gaining insights into the fascinating world of color.

Pictures and Videos

Interaction Design

Regarding the interaction design, I wanted the setup to be simple and minimalistic: 3 potentiometers and one button. The color input happens through the potentiometers each of which represent Red, Green and Blue color channel values (RGB). The button is used to progress through the experience.

The visual design in P5 is also quite simple, following a simple color palette. It is structured and clean, guiding the participant through the experience. The feedback on the color input is provided instantly, ensuring a seamless and responsive interaction that enhances the overall engagement.

Arduino code

My Arduino code reads values from three potentiometers and a button and sends it to P5. The potentiometers provide analog input representing different color channels (Red, Green, and Blue) by measuring voltage. The button is used as a digital input.

const int potPin1 = A0;  // Potentiometer connected to A0
const int potPin2 = A1;  // Potentiometer connected to A1
const int potPin3 = A2;  // Potentiometer connected to A2
const int buttonPin = 4; // Button connected to digital pin 4

void setup() {
  Serial.begin(9600);  // Initialize serial communication at 9600 bps
  pinMode(buttonPin, INPUT_PULLUP); // Set the button pin as input with pull-up resistor
}

void loop() {
  // Read values from potentiometers
  int value1 = analogRead(potPin1);
  int value2 = analogRead(potPin2);
  int value3 = analogRead(potPin3);

  // Read the state of the button
  int buttonState = digitalRead(buttonPin);

  // If the button is pressed, send a button message
  if (buttonState == LOW) {
    Serial.println("BUTTON_PRESSED");
  } else {
    // Send potentiometer values as usual
    Serial.print(value1);
    Serial.print(',');
    Serial.print(value2);
    Serial.print(',');
    Serial.println(value3);
  }

  delay(500);  // Add a delay for stability, adjust as needed
}
P5 code

The P5 code controls the different stages of the experience. The project unfolds through different stages, each focusing on a specific emotion, such as nostalgia, serenity, courage, curiosity, and resilience. P5 is receiving the data from the Arduino, and the combined color choices are stored in an array, which is used to create a generative artwork based on the personalized color gradients.

One of the more challenging parts was the storing of the final input colors in an array. I had to create additional flag variables or else the storing would be continuous and the array would expand super quickly. However, with the flags I was able to store the last value before the press of the button:

hasPushedColors = false;
if (buttonPressed && !hasPushedColors) {
  // Add the last values of R, G, and B to the array
  p_colors.push([R, G, B]);
  console.log("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
  console.log("color" + p_colors);
  hasPushedColors = true; // Set the flag to true to prevent multiple pushes
  buttonPressed = false;
Parts I am proud of

I am particularly proud of my concept. I find it to be very simple, yet it has a sense of discoverability, anticipation and surprise, especially with the reveal of the gradient. Even after completing the experience multiple times, each time I am curious to put it different colors to see what final gradient will be generated. I am also happy that it has a deeper psychological context and how unconsciously we do tend to connect certain colors to certain feelings. I already made some observations, for instance, a big part of my participants tended to associate red with resilience.

I am also quite satisfied with my interaction design. It was a great learning experience for me to better understand color through color combinations, and the potentiometers are quite an accurate choice for input. They are easy to control and provide good precision.

Future Improvements

An improvement I would be most keen to explore would be to provide an interpretation for the color choices of participants. Either at every stage, or at with the final result. It would be interesting to perhaps incorporate machine learning into analysing the color selections and generating insights into the potential emotional or psychological significance behind each choice. This could involve training a machine learning model on a dataset of color-emotion associations, allowing the system to recognize patterns and correlations. By providing participants with personalized feedback on their color selections, the project could become a more insightful and introspective experience.

Leave a Reply