Skip to content

Commit 57ed1f7

Browse files
committed
Update README.
1 parent 86a7f96 commit 57ed1f7

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

README.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# ImGui CMake as a Library
1+
# ImGui as a Library
22

33
CMake cross platform module for building [Dear ImGui](https://github.com/ocornut/imgui) as a library.
44

@@ -7,6 +7,7 @@ CMake cross platform module for building [Dear ImGui](https://github.com/ocornut
77

88
```bash
99
git clone https://github.com/giladreich/ImGui-CMake-Installer
10+
cd ImGui-CMake-Installer
1011
git submodule update --init --recursive
1112

1213
mkdir build && cd build
@@ -19,19 +20,19 @@ By default it would build ImGui as a static library, but if you would like to bu
1920
cmake .. -DIMGUI_WITH_IMPL=OFF -DIMGUI_STATIC_LIBRARY=OFF
2021
```
2122

22-
There are few things you want to know when you build `Dear ImGui`:
23+
There are few things you want to know when you build `Dear ImGui`:<br>
2324
ImGui comes with examples that already takes care of the way people should interact with the library, i.e `imgui_impl_win32.cpp`, `imgui_impl_vulkan.cpp`, `imgui_impl_osx.mm` `imgui_impl_sdl.cpp` etc...
2425

2526
Basically the author of the library didn't want it to be dependent on any kind of graphic API's, therefore he expects that you'll provide your own implementation for that part(even though they're already exists in the `examples`).
2627

2728
That being said, before you build the library, you want to have a look at `CMakeOptions.cmake` file to see which options are available.
2829

29-
If you want to include one of the examples in the library build, when you generate the cmake project, you'll want to pass which graphic API you want to include in your build. Exmaple:
30+
If you want to include one of the examples in the library build, when you generate the cmake project, you'll want to pass which graphic API you want to include in your build. Example:
3031
```bash
3132
cmake .. -DIMGUI_IMPL_DX11=ON
3233
```
3334

34-
That would basically copy and include in your library build the following files:
35+
That would basically copy and include in your library build the following files:<br>
3536
`imgui_impl_win32.cpp` `imgui_impl_win32.h`, `imgui_impl_dx11.cpp`, `imgui_impl_dx11.h`
3637
and the headers will also be copied under `dist/include` directory.
3738

@@ -40,10 +41,13 @@ and the headers will also be copied under `dist/include` directory.
4041

4142
If you run into any errors, please make sure you running with the correct environments(i.e `Developer Command Prompt for VS 2017`).
4243

44+
Another note that if you re-running cmake again with different options, make sure you remove `CMakeCache.txt` before you run cmake command again. Because the options would be cached in this file and won't refresh automatically.
4345

4446
## Motivation
4547

46-
I normally use [Conan C++ Package Manager](https://conan.io/) for building my projects and I wanted to have my [own recipe](https://github.com/giladreich/conan-imgui) for packaging ImGui with conan to simplify the usuage of the library.
48+
ImGui library designed to be copied into the project internally, I therefore wanted to externalize it so I can reference to it from multiple projects instead of copying ImGui to each project.
49+
50+
I also use [Conan C++ Package Manager](https://conan.io/) for building my projects and I wanted to have my [own recipe](https://github.com/giladreich/conan-imgui) for packaging ImGui with conan to make it more portable across different projects.
4751

4852
There is already existing project for [conan-imgui](https://github.com/bincrafters/conan-imgui), but unfortunately it only provides the library as is without the option to enable examples.
4953

@@ -54,7 +58,7 @@ I therefore got the motivation to make this CMake module so I can manage my own
5458

5559
* **Gilad Reich** - *Initial work* - [giladreich](https://github.com/giladreich)
5660

57-
See also the list of [contributors](https://github.com/giladreich/QtDirect3D/graphs/contributors) who participated in this project.
61+
See also the list of [contributors](https://github.com/giladreich/ImGui-CMake-Installer/graphs/contributors) who participated in this project.
5862

5963

6064
## License

0 commit comments

Comments
 (0)