Marcus Aurelius Meditations
Since the beginning of the Corona crisis, I have been more and more interested in the history of ancient philosophy. The topic has grabbed me directly and no longer let go. And so I often spend my Sundays collecting second-hand books, reading and painting in them to make this abstract world a little more tangible to me.
I used to be very interested in psychology. And an interesting intersection between psychology and philisophy is represented by the philosophical schools of Hellenism. Stoicism in particular is very interesting in times of crisis. Books like the Meditations of Marcus Aurelius I have read and worked through several times. And I’ve always wondered how the knowledge from such books could be made available digitally in a useful way.
Ancient texts are almost all in the public domain, even in their translations, and so you can download them and work with them creatively. I have taken the Meditations of Marcus Aurelius, prepared the data cleanly and built a boilerplate for experiments with this work.
JSONArray json;
ArrayList<Verse> verses;
color black = #000000;
color white = #f1f1f1;
color grey = #AAAAAA;
color blue = #2700A2 ;
color green = #000000;
color FG1 = #0000FF;
color BG1 = #AAAAAA;
color FG2 = #AAAAAA;
color BG2 = #0000FF;
color FG, BG;
float offsetY = 0;
float padding = 10;
PFont font;
float txtSize = 150;
String txt, book, verse;
int verseAmount;
int selector = 0;
void setup() {
size(1200, 900);
offsetY = height;
strokeCap(RECT);
json = loadJSONArray("meditations.json");
font = createFont("sans.otf", 1000);
verses = new ArrayList<Verse>();
for (int i = 0; i < json.size(); i++) {
JSONObject item = json.getJSONObject(i);
String txt = item.getString("english");
String book = item.getString("book");
String verse = item.getString("verse");
Verse v = new Verse(txt, book, verse);
verses.add(v);
}
}
void draw() {
background(BG);
noStroke();
verseAmount = json.size();
Verse v = verses.get(selector);
if (int(v.book) % 2 == 0) {
FG = FG1;
BG = BG1;
} else {
FG = FG2;
BG = BG2;
}
drawProgressBar(v);
v.display();
offsetY -= 10;
if (keyPressed) {
if (keyCode == 37) {
selector = selector - 1;
} else if (keyCode == 39) {
selector = selector + 1;
}
offsetY = height;
}
}
class Verse {
String txt;
int book;
int verse;
Verse(String _txt, String _book, String _verse) {
txt = _txt;
book = int(_book);
verse = int(_verse);
}
void display() {
push();
translate(padding, padding + offsetY);
fill(BG);
rect(0, 0, width, height*100-50);
textFont(font);
textSize(txtSize);
textLeading(txtSize);
textAlign(LEFT, TOP);
if (book % 2 != 0) {
fill(#F1F1f1);
} else {
fill(#000000);
}
text(txt, 0, 0, width - padding*2, height * 10);
pop();
}
}
void drawProgressBar(Verse v) {
fill(FG);
textFont(font);
textSize(txtSize);
textLeading(txtSize);
textAlign(LEFT, TOP);
text("marcus aurelius\nmeditations\nbook " + v.book + "\n" + "verse " + v.verse, 10, 10);
float posX = map(selector, 0, verseAmount, 0, width);
push();
noStroke();
fill(FG);
rect(0, height-20, posX, 20);
pop();
}
Enjoying the content?
Since 2018, I have published 244 interviews, case studies, and tutorials, along with over 359 lessons in 22 online courses – and there's more to come! If you want to get full access or simply support my work and help keep this platform thriving, please consider supporting me on Patreon. Thank you very much!

Related

In the two years I lived in Barcelona, one person in particular fascinated and inspired me. His name is Kris […]

One of the most beautiful books I have ever held in my hands is “Lo–TEK” by Julia Watson, an architect, […]

Hi! This is a work in progress version of a set of principles that trcc follows as a school. Any […]

Let’s begin here: A myriad of new technologies is accelerating our world at a breathtaking pace. I’m not interested in […]

Below is the written version of my talk at DEMO Festival in Amsterdam, January 2025. I’ve also recorded an audio […]

The Magic Triangle is a powerful creativity technique that can be applied to many different areas.

I have been observing developments in design for 40 years. That may sound strange, as I’m only forty myself, but […]

I met Omid Nemaldhabib quite coincidentally in Rotterdam in 2022. He comes from Tehran and ran a design studio there […]