Page 4 of 38

Tetzle says goodbye to OpenGL

Posted on June 22, 2024, under Tetzle

Many long years ago I tried using QGraphicsView to make a simple puzzle game. But I found it to be unbearably slow, possibly because I wasn’t using it correctly. Who knows. So I decided to use OpenGL to accelerate the graphics. After all, OpenGL is all about accelerating graphics! And all was good.

Well, sort of. OpenGL is not the easiest to work with. And it changed a lot over the years, forcing me to mimic my use of the old fixed-function pipeline with the newer programmable pipeline. Tetzle’s code has always been a bit hard to debug because, well, again, OpenGL is not the easiest to work with. It has also caused many issues for users over the years that I have sadly not been able to solve.

Plus, it never really sat well with me that my simple 2D puzzle game used a graphics framework that is better suited to 3D gaming. Sure, you can accelerate 2D graphics with it, but it is overkill. Especially with modern CPUs. This is just blitting 2D graphics, for sanity’s sake!

So! Every few years I would think about porting Tetzle away from OpenGL, sift through the old code I have archived, look at the mess of the QGraphicsView version and think, “Maybe later.” And, of course, later never came.

Until now.

Because Qt 6.7 doesn’t work with the current Tetzle code. Well, it does if you run Tetzle as OpenGL 1.1 or 1.3, which is just absurd. And not supported everywhere, since it’s the old fixed-function pipeline that was dropped years ago. Instead of spending time fixing it, I decided: “Now. Now is the time to finally get Tetzle free from OpenGL’s clutches.”

But…

I still didn’t like the idea of trying to clean up the ancient QGraphicsView code that bore absolutely no resemblance to the current game. And then I had a brainwave: why not just use QPainter? It has an interface close enough to how I was using OpenGL that I can reuse most of the current code, and everything should Just Work™. And… it does! 🎉

It is embarrassing just how easy it was to get Tetzle free from OpenGL. I should have looked at QPainter before, since I do use it for some of my games instead of QGraphicsView. Hindsight is 20/20, and all that. In less than 24 hours from the initial idea, I am pleased to say that future releases of Tetzle will no longer require OpenGL!

Welcome to my new website!

Posted on June 20, 2024, under Uncategorized

It has been a long time coming. I last updated the look of my website ten years ago, and even then that was only a modification of a design that I had been using for a few years already. Wow, how time flies!

Amusingly, I didn’t even set out to redesign my website, despite having wanted to update its look off and on over the years. What started this was that I wanted to add a list of download links for the release notes of previous versions. You wouldn’t believe the number of people using insecure and outdated operating systems and who want to run FocusWriter on them. 😛

After I finally extracted all of the information about the history of the downloads (which I store in a git repository, of course), I then felt I should pretty up the release notes to match. Which is something I have wanted to do for a very long time.

One thing led to another, and I found myself completely rewriting my custom static site generator to output a new website. Then I thought, while I am at it, why don’t I bring my blog back to my own domain? After all, that is also something I have wanted to do over the years…

I even took new screenshots of my programs! I last did that in the KDE 4 era, and once again I kept meaning to update them but never took the time. I used the newest KDE with the default Breeze widget and icon themes, despite vastly preferring Oxygen, because I imagine many more users will see my programs looking like this.

And here we are! Everything should even work on mobile, which is something the old site design did not handle very well. And I even threw in dark mode support. Whew. No wonder it took so long to do.

Categories