Niepce February 2023 updates

This is the February 2023 update.

Not as much direct progress as I wished.

One big change is that now the binary is linked from Rust. And at the same time the autotools buid system is gone. The latter came first, as to not have to ignore it when doing the former.

Several challenges presented themselves with linked the app from Rust.

  1. We have to invert the dependency. We'd build the Rust code as a library, generate the headers for the cxx bridge and then build the C++ code, and link it. Instead we generate the headers, build the C++ code as libraries and then the Rust code.
  2. We have to figure some tricks: the Rust executable needs to link to some system libraries called directly from the C++ code, and also need to link to asan if needed.

Otherwise, for the two previous topics, namely the importer and the previewer.

The importer

The importer hasn't really moved much, sadly.

The previewer

For the previewer, I implemented a cache backed by a database. Currently it only handles the embedded thumbnails, but I'm working on reworking the image renderer (a simple pipeline based in GEGL) to work aynchronously, its design being hopefully suited for the use case.

UI toolkit and dependencies

I wrote a couple of macros to help with some of the UI patterns, like declaring actions to send an event. And the higher order action groups with all the actions. Less code to write, less possible errors.


An update of the bindings came out so I had to upgrade. Some code changes, but on overall it was eventless. Congrats to the team.


Investigating how libpanel can help me implement the UI designs I have in mind. Straight from gnome-builder, libpanel offers a bunch of widgets to implement dockable panels, in a way I imagined earlier ideas for Niepce UI. While it has Rust bindings, it lacked documentation, so I've addressed this, at least enough for further contributions.

Also addressed some issues with improper annotations that caused floating references to have improper ownership and being dropped too early by the Rust binding. The annotations are part of gir and used by the bindings generation tools.

I think it should be in good shape now to use it here ; I tested it in compiano. I need to come up with a UI design to change the few things I want to change ; but I need more feature first.

Other side quest

Like in any good RPG campaigns there are side quests that will help you fullfilling the main goals


Did some work on libopenraw, which is used for thumbnailing. This include vendoring the crates for the mp4parse crate (forked from Mozilla's), when generating the tarball. (Release to come)

Also did some work on the Rust port, including speed ups (BufReader is a simple boost as by default I/O are not buffered in Rust), with benchmarking to measure performance gains, and a few others.


Another side project, needed to download GPS logging data from my GPS logger after an excursion. It happens that the current code for GPSAmi was broken, so I had to fix it. I have to admit I carelessly changed including porting to gtk4 without testing.

Also another issue I want to fix is to no longer use gpsbabel. Two reasons for that:

  1. it's a command line tool, so interfacing with it is what it is.
  2. it requires Qt5. That latter part it really a bummer with Flatpak because I have to either use the KDE SDK and build gtk4 or use the GNOME SDK and build Qt. It's 2023 you you still can't build QtCore separately it seems.

So I started writing a crate (in Rust) to support downloading from my GPS logger, which in turn make me realize that serial port management is complicated with permissions. And that's putting aside bluetooth serial: it doesn't work on my laptop but work on the desktop.

I think that's what we call full stack. More on that later.

Thank you reading.