Time for action – self-updating car dashboard

In the next exercise, we will implement a car dashboard that can be used in a racing game and will show a number of parameters such as current speed and motor revolutions per minute. The final result will look similar to the following image:

Time for action – self-updating car dashboard

We will start with the C++ part. Set up a new Qt Quick Application. Choose the most recent Qt Quick version for the Qt Quick component set. This will generate a main function for you that instantiates QGuiApplication and QQmlApplicationEngine and sets them up to load a QML document.

Use the File menu to create New file or Project and create a new C++ class. Call it ...

Get Game Programming Using Qt 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.