OSD Design Studio, from the idea to a working module
Why I built an application for designing on-screen displays, what it generates, and a short guide to designing your first overlay with it.

On this page
The idea
On a project where I was providing digital design and consultancy services, one of the tasks was designing an OSD menu and text readouts overlaid on the video of an imaging system. There was no video processor in the system apart from the main FPGA, so the OSD had to be implemented in RTL. It had a wide variety of elements, such as text, numbers and menus, all overlaid on the streamed image.
I had done similar OSD designs before and I remember really enjoying them. Still, each one took quite some time, because I was building them almost from scratch. This time I wondered how I could make the process more enjoyable and at the same time quicker and easier. That is how the idea of an OSD designer app came about. One application where I could design every aspect of an OSD. I decided to give it a shot, and so I joined the AI train, where new applications and tools come out every day, with my OSD Design Studio. With it, designing an OSD and exporting it as RTL is now quick and easy.
What elements can be overlaid with OSD Design Studio?
An overlay is built from nine element types. Every element you place becomes its own small block in the generated module, with its own ROM for the glyphs or pixels it needs, so the hardware grows with the design rather than with the feature list.
















Every tile above is drawn by the tool's own renderer, the same one that produces the golden frames, so this is what the RTL puts on the screen.
A live input can also be the value of a menu item instead of a binding, so a menu setting can drive the overlay directly, the way the Target box item in the example switches the marker on and off.
A few properties apply to every element:
- Screens. An element belongs to one or more screens, and a binding selects the active screen at run time, the way the example switches between its main view and a diagnostics page.
- Visibility. Up to two conditions, combined with AND or OR, decide when an element shows: a flag, the menu being open, or a particular menu page. An element can also blink at one of the project's blink rates.
- Blend mode. Opaque paints the whole box, keyed skips transparent pixels, and half averages the overlay with the video. Invert, contrast and shift derive the colour from the video underneath, so the element stays readable on bright and dark scenes alike.
- Palette and z-order. Colours come from a palette of up to 16 entries, and where elements overlap the one with the higher rank is drawn on top.
The design flow with the app
The flow has three parts: you design the overlay in the app, export it as one RTL module, and the export proves that module against the picture you designed.
1. Design in the app
The app is organised the way a design comes together. You describe the video the module will sit on, lay the overlay out, build the menu, choose the fonts and export. Until the export there is no RTL yet, but the Designer and the Menu page already run the same renderer and menu logic that go into the module, so what you see on the canvas is what the hardware will draw.
2. Exported RTL
The export is a single synthesizable module, in Verilog or SystemVerilog, with four kinds of connection:
- Video in and video out. The stream passes through in the format and timing it arrived in, parallel or AXI4-Stream, and leaves a fixed number of clock cycles later with the overlay drawn on it. There is no frame buffer and no line buffer.
- Bindings. The live values the overlay shows, such as a temperature readout, a recording flag or a target position. Your design drives them as plain ports, or writes them through an AXI4-Lite register map that the export generates.
- Buttons. Up, down, enter and back go into the generated menu controller, which handles debounce, long-press repeat and timeouts.
- Menu outputs. Each menu setting, brightness or mode for example, comes out as a port, so the rest of your design can act on it.
3. Verification
Every export comes with a self-checking testbench. It needs no expected values written by hand: the golden frames (plain-text hex files, one pixel per line, loaded with $readmemh) come from the same renderer you designed with, so the RTL is compared against the picture you saw.
The tool writes a scenario of frames and run-time states next to the testbench. By default it has six frames: the defaults, the OSD switched off, extreme binding values, the menu opened, the cursor moved and an item activated. Button presses and binding changes are applied between frames, and the reference model goes through the same events. A frame fails if a single pixel differs or the pixel count is wrong, and a failing frame is written to a text file so you can see where it went wrong.
The testbench also tries to break the module on purpose. With AXI4-Stream it pulls TREADY low at intervals, so the pipeline has to handle stalls. With parallel video it uses its own blanking, which the module must not depend on. It is written to be simulator-neutral, the command-line edition runs it under Verilator, and it ends with one PASS or FAIL line and a matching exit status, so it drops into a regression flow. For the example camera project, the whole check (generate, build in Verilator, simulate six 640x480 frames) takes about eight seconds:
frame 0: PASS
frame 1: PASS
frame 2: PASS
frame 3: PASS
frame 4: PASS
frame 5: PASS
RESULT: PASS (6 frames)
The result
You lay the overlay out over a sample frame, run the menu with on-screen buttons, and export a synthesizable module. Video goes in, the same video comes out with the overlay drawn on it, after a fixed number of clock cycles, with no frame buffer and no line buffer.

A short guide
The tool runs in the browser at linebuffer.com/tools/osd-design-studio, with nothing to install. File > Open example (also offered on the welcome screen) loads a camera project, which is a good place to start: every picture below comes from it. The left rail has five pages, and a design moves through them roughly in this order.
1. Project: the video and the budgets
Set the active area, the colour mode, the pixel clock and the stream interface so they match the bus the module will sit on. The budgets (latency, ROM, RAM, logic) are limits the tool checks the design against as you work. Bindings, the live values the overlay shows, and the menu buttons are declared on the tabs at the top.

2. Designer: lay out the overlay
Add text, readouts, enumerated text, rectangles, lines, crosshairs, bitmaps and bars over the sample frame, and connect each one to a binding. The run-time panel on the right changes the binding values and presses the buttons, so you see the overlay react before any RTL exists.

3. Menu: pages and items
A menu is a set of pages, and each page a list of items: numbers, enums, toggles, sub-pages, actions and an exit. The preview underneath runs the real navigation logic, the same one that is generated into the module.

4. Assets: fonts, bitmaps and the palette
Seven fixed-width fonts are built in. Your own come in as BDF files or PNG glyph sheets, and bitmaps the same way. Every glyph you keep costs ROM, which the budget on the Project page counts.

5. Export: the module and its testbench
The Export page shows the resource estimate, a block diagram of the module and every port before you write anything. The export itself, the RTL and the self-checking testbench, is a licensed feature; write to me for a trial.

What's coming next
Two follow-ups are on the way:
- What it costs in an FPGA. Typical resource use for a few common overlay designs, from a couple of readouts to a full menu, taken from Yosys synthesis of the exported RTL.
- On a real board. The generated module verified live on an FPGA, in a real video path driving a monitor.
Subscribe to the RSS feed to get them when they are out.