0

I've been playing around with Linux lately. The last time I did that was 2005-2010. One of the things I enjoyed doing back then was ricing the vt. Back then, you could apply Splashutils, which was a patch to the in-kernel vt which gave it margins, a background image, and some simple compositing. Today, you have to use fbterm, which is essentially abandonware. It also has a lot of problems and zero support 1 2 3. I was also unable to find an AppImage for fbterm from a time when it didn't suck.

Other framebuffer terminals exist. There's the excellent and abandoned kmscon, which has no support for background images. fbpad is another person's passion project which is wonderful and doesn't do any of those things either.

So, I'm kicking around the idea of writing a terminal for this purpose. I like Clojure personally, so I'm looking for libraries which fit that bill. For shell integration, I found the excelent pty4j, and Jediterm has links to all the specifications, manuals, and an old testing utility.

I still need an easy way to render ttf/otf fonts and images to the linux framebuffer, using hardware acceleration when possible. I will need to do basic compositing as well.

After looking for several days, here are some of the things I've found:

  1. JavaFX has framebuffer support on some embedded devices by using Monocle. This doesn't fit my use-case.
  2. fb4j. Despite claiming to be 'The BEST lightweight, Java-based, framebuffer interface for Linux in existence.', a quick glance at the code shows a lot of problems. No way to interface to eg fb1 in the case of multiple monitors. My understanding of synchronized in function definitions tells me the developer hasn't considered all possible cases where race conditions can occur.
  3. This library appears completely broken. I couldn't get it to build.
  4. linuxio4j currently looks like the best option. The code is decent but could use some love. It exposes a Graphics2D object and handles translation to the framebuffer. Basically, all you need to know is AWT, which I believe gives me everything I'm looking for except hardware acceleration. However, there is no maven artifact, and my local build gave me some issues 1 2. No responses from the maintainer yet.
  5. I've reached out to the lwjgl community because I think pygame can use different framebuffer drivers. Since they target a similar audience I wonder if lwjgl can target the framebuffer too. Nothing yet.

Starting to feel like I'm spinning my wheels here. I don't want to maintain two projects. So I'm asking if anyone knows of a library which fits the bill and can get me started (with eg a small example).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.