Skip to content

Commit 30a5ac5

Browse files
authored
Merge pull request #67 from bobis33/Doc/all/improve
`Doc/all/improve`
2 parents 1631450 + 72083a1 commit 30a5ac5

11 files changed

Lines changed: 101 additions & 39 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
cmake --build cmake-build-release --config Release
4949
binary: cmake-build-release\bin\cae.exe
5050
build_test: |
51-
cmake -S . -G "Ninja" -B cmake-build-release -DCMAKE_BUILD_TYPE=Release -DBUILD_CAE_TESTS=ON
51+
cmake -S . -G "Ninja" -B cmake-build-release -DCMAKE_BUILD_TYPE=Release -DCAE_BUILD_TESTS=ON
5252
cmake --build cmake-build-release --config Release
5353
binary_test: cmake-build-release\bin\cae-tests.exe
5454
deps: choco install cmake -y

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/modules")
99
set(CMAKE_CXX_STANDARD 23)
1010
set(CMAKE_CXX_STANDARD_REQUIRED ON)
1111
set(CMAKE_CXX_EXTENSIONS OFF)
12+
set(CMAKE_C_STANDARD 23)
13+
set(CMAKE_C_STANDARD_REQUIRED ON)
14+
set(CMAKE_C_EXTENSIONS OFF)
1215
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin")
1316
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/lib")
1417
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/lib")
@@ -76,7 +79,7 @@ target_link_libraries(${PROJECT_NAME} PRIVATE
7679
)
7780

7881
copy_directory_to_target(
79-
cae
82+
${PROJECT_NAME}
8083
"${CMAKE_SOURCE_DIR}/assets"
8184
"assets"
8285
)

README.md

Lines changed: 46 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Rather than focusing only on graphics API abstraction, the objective is to creat
1515
This enables rapid experimentation, platform portability, performance benchmarking, and true freedom in engine architecture research.
1616

1717
![Architecture Diagram](https://raw.githubusercontent.com/bobis33/Cross-API-Engine/main/assets/diagram.png)
18+
1819
## Supported Platforms
1920
| Platform | Compiler | Build system | Status |
2021
|----------|----------------------------------|-----------------|--------|
@@ -26,7 +27,7 @@ This enables rapid experimentation, platform portability, performance benchmarki
2627
| Android | | ||
2728
| Web | | ||
2829

29-
## Build & Run
30+
## Quick Start
3031

3132
### Prerequisites
3233

@@ -35,12 +36,22 @@ Make sure you have the following dependencies installed on your system:
3536
- [CMake ≥ 4.0.0](https://cmake.org/)
3637
- [C++23](https://en.cppreference.com/w/cpp/23)
3738

38-
### UNIX (Linux, MacOS)
39+
### Build (UNIX: Linux, macOS)
3940

4041
```bash
41-
./scripts/unix/build.sh release
42+
cmake -S . -G "Ninja" -B cmake-build-release -DCMAKE_BUILD_TYPE=Release
43+
cmake --build cmake-build-release --config Release
4244
```
4345

46+
### Build (Windows)
47+
48+
```powershell
49+
cmake -S . -G "Visual Studio 18 2026" -A "x64" -B cmake-build-release -DCMAKE_BUILD_TYPE=Release
50+
cmake --build cmake-build-release --config Release
51+
```
52+
53+
### Run
54+
4455
```bash
4556
./cmake-build-release/bin/cae -h
4657
Usage: cae [options]
@@ -51,35 +62,47 @@ Options:
5162
-c, --config <path> Specify JSON configuration file
5263
```
5364

54-
### Windows
65+
## Documentation
5566

56-
```powershell
57-
cmake -S . -G "Visual Studio 18 2026" -A "x64" -B cmake-build-release -DCMAKE_BUILD_TYPE=Release
58-
cmake --build cmake-build-release --config Release
59-
```
67+
- [Online Doxygen documentation](https://bobis33.github.io/Cross-API-Engine/): Full engine architecture, APIs and design rationale.
68+
- [Modules](https://github.com/bobis33/Cross-API-Engine/blob/main/modules/README.md): Overview of available modules and their responsibilities.
69+
- [Plugins](https://github.com/bobis33/Cross-API-Engine/blob/main/plugins/README.md): Plugin system and how to create new runtime modules.
6070

61-
```bash
62-
cmake-build-release\bin\cae.exe -h
63-
Usage: cae.exe [options]
71+
## Development
6472

65-
Options:
66-
-h, --help Show this help message
67-
-v, --version Show version information
68-
-c, --config <path> Specify JSON configuration file
73+
This section targets engine developers and contributors.
74+
75+
### CMake Build options
76+
77+
- `CAE_STRICT_WARNINGS` (default: `OFF`): Enable strict warning level.
78+
- `CAE_ENABLE_SANITIZERS` (default: `OFF`): Enable address and undefined sanitizers.
79+
- `CAE_ENABLE_LTO` (default: `OFF`): Enable LTO on final targets.
80+
- `CAE_BUILD_TESTS` (default: `OFF`): Enable building unit tests.
81+
- `CAE_CLANG_TIDY` (default: `OFF`): Enable clang tidy usage.
82+
- `CAE_CLANG_FORMAT` (default: `OFF`): Enable clang format usage.
83+
- `CAE_BUILD_DOC` (default: `OFF`): Enable building doxygen documentation.
84+
85+
### Testing
86+
87+
Unit tests are based on [Google Test](https://github.com/google/googletest).
88+
89+
Use the `CAE_BUILD_TESTS` option.
90+
91+
```bash
92+
./cmake-build-release/bin/cae-tests
6993
```
7094

71-
## External Libraries
95+
### Build Doxygen documentation
7296

73-
- [Doxygen Awesome CSS](https://github.com/jothepro/doxygen-awesome-css): A custom CSS theme for Doxygen documentation.
74-
- [Google Test](https://github.com/google/googletest): A testing framework for C++.
75-
- [nlohmann-json](https://github.com/nlohmann/json): A JSON library for C++.
97+
documentation is generated using [Doxygen](https://www.doxygen.nl/).
7698

77-
## Documentation
99+
Use the `CAE_BUILD_DOC` option.
78100

79-
- [Modules](https://github.com/bobis33/Cross-API-Engine/blob/main/modules/README.md): Overview of available modules and their functionalities.
80-
- [Plugins](https://github.com/bobis33/Cross-API-Engine/blob/main/plugins/README.md): Information on available plugins and how to create new ones.
101+
## Third-party libraries
81102

82-
Visit the [Doxygen documentation](https://bobis33.github.io/Cross-API-Engine/) for detailed information on architecture, modules, and usage.
103+
- [Doxygen Awesome CSS](https://github.com/jothepro/doxygen-awesome-css): A custom CSS theme for Doxygen documentation.
104+
- [Google Test](https://github.com/google/googletest): A testing framework for C++.
105+
- [nlohmann-json](https://github.com/nlohmann/json): A JSON library for C++.
83106

84107
## Contributing
85108

assets/diagram.png

220 KB
Loading

cmake/modules/ClangFormat.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
option(USE_CLANG_FORMAT "Enable clang-format" OFF)
1+
option(CAE_CLANG_FORMAT "Enable clang-format" OFF)
22

3-
if (NOT USE_CLANG_FORMAT)
3+
if (NOT CAE_CLANG_FORMAT)
44
return()
55
endif()
66

cmake/modules/ClangTidy.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
option(USE_CLANG_TIDY "Enable clang-tidy static analysis" OFF)
1+
option(CAE_CLANG_TIDY "Enable clang-tidy static analysis" OFF)
22

3-
if (NOT USE_CLANG_TIDY)
3+
if (NOT CAE_CLANG_TIDY)
44
return()
55
endif()
66

cmake/modules/MakeDoc.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
option(BUILD_DOC "Build documentation" OFF)
1+
option(CAE_BUILD_DOC "Build documentation" OFF)
22

3-
if (NOT BUILD_DOC)
3+
if (NOT CAE_BUILD_DOC)
44
return()
55
endif()
66

modules/README.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
1-
# Modules
1+
# Modules
2+
3+
| Module Name | Description |
4+
|-------------|-----------------------------------------|
5+
| Engine | Core engine functionalities and systems |
6+
| Interfaces | Abstractions for various subsystems |
7+
| Utils | Utility functions and helpers |

plugins/README.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,31 @@
1-
# Plugins
1+
# Plugins
2+
3+
| Type | Name | Windows | Linux | MacOS | Status |
4+
|-----------------|-----------|---------|-------|-------|--------|
5+
| Audio | ALSA |||||
6+
| Audio | Core |||||
7+
| Audio | OpenAL |||||
8+
| Audio | XAudio2 |||||
9+
| Model | Assimp |||||
10+
| Model | fastgltf |||||
11+
| Network | Asio |||||
12+
| Network | Posix ||| ||
13+
| Network | WinSock |||||
14+
| Physic | | | | ||
15+
| Renderer | DirectX12 |||| 🚧 |
16+
| Renderer | Metal |||||
17+
| Renderer | OpenGL ||| 🚧 | 🚧 |
18+
| Renderer | Vulkan |||| 🚧 |
19+
| Shader IR | SPIR-V |||| 🚧 |
20+
| Shader IR | DXC |||||
21+
| Shader Frontend | GLSL |||| 🚧 |
22+
| Shader Frontend | HLSL | | | ||
23+
| Shader Frontend | MSL | | | ||
24+
| Shader Frontend | WGSL | | | ||
25+
| UI | Imgui |||||
26+
| Window | Cocoa |||||
27+
| Window | GLFW |||||
28+
| Window | Win32 |||||
29+
| Window | X11 |||||
30+
31+
**Legend:** ✅ fully supported, 🚧 work in progress / partial, ❌ not supported

scripts/unix/build.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,19 +60,19 @@ while [[ $# -gt 0 ]]; do
6060
case "$1" in
6161
--tidy)
6262
RUN_TIDY=ON
63-
CMAKE_CMD+=(-DUSE_CLANG_TIDY=ON)
63+
CMAKE_CMD+=(-DCAE_CLANG_TIDY=ON)
6464
;;
6565
--tests)
6666
RUN_TESTS=ON
67-
CMAKE_CMD+=(-DBUILD_CAE_TESTS=ON)
67+
CMAKE_CMD+=(-DCAE_BUILD_TESTS=ON)
6868
;;
6969
--format)
7070
RUN_FORMAT=ON
71-
CMAKE_CMD+=(-DUSE_CLANG_FORMAT=ON)
71+
CMAKE_CMD+=(-DCAE_CLANG_FORMAT=ON)
7272
;;
7373
--doc)
7474
RUN_DOC=ON
75-
CMAKE_CMD+=(-DBUILD_DOC=ON)
75+
CMAKE_CMD+=(-DCAE_BUILD_DOC=ON)
7676
;;
7777
*)
7878
echo "[WARNING] Unknown option: $1"

0 commit comments

Comments
 (0)