I didn’t speed up this video. I hope it’s not too long
It was a simple experiment to find out how things would look like if I displaced one edge of a rectangle.
I forgot to show it without converting the edges to cubic. I leave that as an exercise for the viewer
Kudos to my colleague Kazik for implementing the zucconi6 function used to set the colors
7:14
Livecoding in nature with OPENRNDR 04
This was the first time I used a transparent window. That was pretty cool I had to run xcompmgr -o 1.0 before starting my program (I’m on Manjaro Linux). I wish it would apply blending onto whatever is on the background (in this case I was using blend mode ADD).
Anyway: the essence of this sketch is a recursive adjustContour to subdivide certain edges on a regular polygon and displace them along the normals. The displacement uses simplex noise based on the center of the segment.
Not sure this has any practical uses, but I liked how organic it looked sometimes, maybe like flames or like a freezing/melting time-lapse.
I had never been in that part of Finland before. When I arrived there was a deer looking at me for a second before it darted away.
May 8th but the metal seat was so cold that I had to sit on my backpack At least my hands were not freezing.
The coding plays at double speed because it was too long otherwise X-D
9:13
In the first four videos I did try to make a tiny bit “educational”, in the sense of showing how I built a simple program from scratch.
This video is different and probably makes no sense
It is a proof of concept and very experimental. It all started with the previous video, in which I learned I could have transparent borderless windows, which I thought was cool for live coding. But I was not happy about the fact that I could not blend my visuals on top of the code (for instance, by using the ADD blend mode). Also, my program could not “see” the text. It was basically two windows, the top one (my visuals) not knowing what is under it (the IDE).
Today I remember that it’s possible to do screen capture using VideoPlayerFFMPEG.fromScreen(). The issue with that is that my program would capture itself, creating a feedback loop, because by default it grabs the whole screen (including itself). But then I took a look at ffmpeg and realized that you can specify a -window_id parameter. So I modified the core openrndr by adding a line like av_dict_set(options, "window_id", "0x2e00045", 0) inside VideoPlayerFFMPEG.kt and this made it possible to read not the whole screen, but only the IntelliJ IDEA window texture.
That enabled me to blend and manipulate that texture in any way I want. But one more issue had to be solved: if the visuals are on top, they will catch all clicks and key presses! What then? I solved that by adding one more line that forwards any mouse click events received by my program to the IDE window using xdotool. That’s enough to have the IDE focused receiving key presses in the back, making it possible to live code It is a bit glitchy, but very fun nonetheless.
1:45
Another live coding video playing with glyphs. In this case, visualizing the Bézier segments that form a character with varying colors, thicknesses and caps.
3:21
It’s funny that I heard about marching cubes before marching squares. It’s the same idea, but the first one is in 3D and the second one in 2D. Basically, here I am generating contours based mathematical formulas. It’s like ShaderToy but for the pen plotter.
4:22