Rendering holographic labels

If you have been following along, your project should now be successfully capturing and analyzing frames. Our next task is to create something to render the results on. We will simply do this using a quad and texture, both of which have been included in the starter project.

Start by declaring the variables to hold references to the classes TextRenderer and QuadRenderer; add the following lines to your FaceTagMain class:

 TextRenderer textRenderer; QuadRenderer quadRenderer;

The TextRenderer creates and holds references to an in-memory texture; we can write to this texture via the RenderTextOffscreen method, passing the text we would like rendered. The QuadRenderer uses this texture to render. As these are DirectX ...

Get Microsoft HoloLens By Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.