Inspiration

For my wife's birthday, I have been building a photobox (wooden box with camera and laptop inside) but struggled with the available software. There is no good open-source/free software. The one I used on the event was a commercial Windows-based application. It did it's job but did not offer a lot of choices I cared for. E.g. giving the user the option if he wants to take a single shot or make a series of 4 photos to produce a collage.

What it does

The software allows to drive a photobox by connecting a DSLR camera via the Gphoto2 library or a plain Webcam. It also allows to connect a photo-printer. The main application runs full-screen in a browser and guides the user to take either a single shot or 4-photo-series. Afterwards, the image (or generated collage) is presented to the user with a choice to print it on the connected printer.

Additionally, the software has a second Web-UI that allows to control the photobox. Currently, it allows to change the used camera or language settings. It is built as a Web-UI so it can be opened on a photo.

How I built it

I built the software as a combination of different technologies I always wanted to try to combine:

  • Quarkus-based backend that exposes restful interfaces to control the camera or download images
  • HTML4 / Lit-Html-based UI for the photobox frontend
  • JSF-based admin interface (using Quarkus MyFaces extension)

Challenges I ran into

The main challenge (and important requirement) currently is the performance of the preview-feed for the camera. The camera shows a live preview stream to the users. The GPhoto2 library allows to access the DSLR-cameras live-feed only by saving it to disk and then accessing it from there. For a stream/feed, this is a lot of IO and it would be better to stream it from the camera to memory. I will try to experiment with using a ramdisk or if it is necessary to directly access the camera interface without GPhoto2. The advantage of GPhoto2 is that it supports a lot of camera-types, but the delay of the feed on screen is noticeable; ~1-2 seconds.

Accomplishments that I'm proud of

I am proud of what i was able to achieve in a few days. I.e. bringing together the backend with a rather nice-looking frontend; and even get JSF working for the admin-interface.

What I learned

I learned a lot about Quarkus, LitHtml and that even nowadays, performance is important. The live-feed runs fine on my modern PC; but on the old laptop in the photobox, the software shows a noticable delay for the live-feed.

What's next for imgbooth

This is basically only a proof-of-concept at the current stage. It needs a lot of error-handling in the front-end and proof that is can run for a whole evening without constant monitoring (the admin interface will help with it though). I might be setting it up on a neighborhood event next weekend to see how it performs. The admin-interface still needs a simple way to restart the whole application so i dont have to fiddle with the laptop in the photobox directly.

Built With

Share this project:

Updates