https://github.com/ABRG-Models/morphologica
C++ header-only graphing and data visualization with Modern OpenGL
https://github.com/ABRG-Models/morphologica
2d 3d cplusplus cplusplus-17 data-visualization graphics graphics-engine graphs matplotlib opengl plotting simulation visualization
Last synced: 10 days ago
JSON representation
C++ header-only graphing and data visualization with Modern OpenGL
- Host: GitHub
- URL: https://github.com/ABRG-Models/morphologica
- Owner: ABRG-Models
- License: apache-2.0
- Created: 2018-06-19T08:32:21.000Z (almost 7 years ago)
- Default Branch: main
- Last Pushed: 2025-04-29T14:51:57.000Z (18 days ago)
- Last Synced: 2025-04-29T15:59:07.700Z (18 days ago)
- Topics: 2d, 3d, cplusplus, cplusplus-17, data-visualization, graphics, graphics-engine, graphs, matplotlib, opengl, plotting, simulation, visualization
- Language: C++
- Homepage: https://abrg-models.github.io/morphologica/
- Size: 77.5 MB
- Stars: 292
- Watchers: 11
- Forks: 35
- Open Issues: 5
-
Metadata Files:
- Readme: README.build.compiler.md
- License: LICENSE.txt
Awesome Lists containing this project
- awesome-scientific-computing - morphologica - Header-only, modern OpenGL code to visualize numerical simulations at runtime. (C++, Apache 2.0, GitHub) (Visualization / Mesh tools)
- trackawesomelist - morphologica (⭐277) - C++ header-only graphing and data visualization with modern OpenGL. \[Apache-2.0] [website](https://abrg-models.github.io/morphologica/) (Recently Updated / [Mar 08, 2025](/content/2025/03/08/README.md))
README
# Minimum compiler versions
morphologica makes extensive use of C++-17 language features, and some
optional use of C++-20 (when building tests/examples, the presence of
C++-20 is tested for in the CMakeLists.txt). For this reason, there
are minimum supported versions of common compilers to be able to
compile *all* the examples. The general rule is that the compiler should
provide full C++-17 support.Note that some of the headers will have more relaxed compiler
requirements. If you are only using a small subset of morphologica
headers in your code, you may get away with a compiler that does not
fulfil the requirements given here.## Tested compiler versions
| OS | Compiler | Version | Result and reason |
| :-------: | :------: | :-----: | ---------------------------------------- |
| Ubuntu 24.04 | g++ | 10.5 | Fail: on constexpr code in morph::Gridct |
| Ubuntu 24.04 | g++ | 11.4 | Pass (make && make test) |
| Ubuntu 24.04 | g++ | 12.3 | Pass (make && make test) |
| Ubuntu 24.04 | g++ | 13.2 | Pass (make && make test) |
| Ubuntu 24.04 | clang++ | 14.0 | Fail: on colourmaps_mono target (`#include ` problem) |
| Ubuntu 24.04 | clang++ | 16.0 | Pass (make && make test) |
| Ubuntu 24.04 | clang++ | 18.1 | Pass (make && make test) |The build also succeeds on various versions of Mac OS with
clang. Entries in the table for clang on Mac are to follow.## Default compilers on different OS platforms
| OS | Default Compiler Family | Version | Support |
| :-------: | :------: | :-----: | :--: |
| Ubuntu 20.04 | gcc | 9 | No |
| Ubuntu 20.10 | gcc | 10 | No |
| Ubuntu 22.04 | gcc | 11 | Yes |
| Ubuntu 22.10 | gcc | 12 | Yes |
| Ubuntu 24.04 | gcc | 13 | Yes |
| Fedora 35 | gcc | 11 | Yes |
| Fedora 36 | gcc | 12 | Yes |
| Fedora 37 | gcc | 12 | Yes |
| Fedora 38 | gcc | 13 | Yes |
| Fedora 39 | gcc | 13 | Yes |
| Fedora 40 | gcc | 14 | Yes* |*Well, probably/hopefully/presumably :)
## Building with clang on Linux
Install clang (which on Ubuntu provides clang++) and a suitable version of libstdc++.
On Ubuntu 24, I used `clang-18` and `libstdc++-14-dev` together.
You then call cmake with
```bash
mkdir build_clang
cd build_clang
CC=clang CXX=clang++ cmake .. # Or maybe CC=clang-18 CXX=clang++-18
make
```
(You probably don't need CC=clang)