Skip to content

First Steps

Otavio edited this page Jan 26, 2023 · 17 revisions

Introduction

To start using FGUI:

  1. Clone or download the repository: https://github.com/otvv/fgui.git
  2. Open the cloned folder: cd fgui (Or extract it if you decided to download the repository directly.)
  3. move/copy the folder 'FGUI' into your project.
  4. Include the main header file on your project.
#define FGUI_IMPLEMENTATION // make sure this is defined before
                            // you include the header file
#include <FGUI/FGUI.hpp>

Renderer helpers:

If you plan to use DirectX or OpenGL to render FGUI, make sure to use #define FGUI_USE_D3D9/10 or #define FGUI_USE_OPENGL pre-processor options inside the aliases file. (FGUI/internal/aliases.hpp)

This is how it should look like:

// library includes
#define FGUI_USE_D3D9 // tell FGUI that you are going to be using DirectX 9
#include "definitions.hpp"
#include "helpers.hpp"

What's next?

Next we will learn how to set up aliases/templates.

Clone this wiki locally