samarium

2-D physics simulation and rendering engine written in modern C++.

MIT License

Stars
8
Committers
1

Samarium

Samarium is a 2d physics simulation library written in modern C++20.

Contents

Examples

Quickstart

git clone --depth 1 https://github.com/jjbel/samarium.git
python samarium/bootstrap.py

Prerequistes

Dependency URL Documentation
python https://www.python.org/downloads/
git https://git-scm.com/downloads/ https://git-scm.com/docs/

A compiler supporting C++20 is required, namely GCC-11, Clang-13, or Visual C++ 2019.

Running boostrap.py will install CMake and Conan, or you can do it yourself first.

Installation

To install the library locally:

conan download samarium/1.1.0@

or for the latest version

git clone --depth 1 https://github.com/jjbel/samarium.git
conan create ./samarium/ -b missing

Example

For a fully-featured and self-contained example, run:

git clone --depth 1 https://github.com/jjbel/samarium_example.git .
cmake --preset default
cmake --build --preset default

Tools

For the optimal developing experience, use VSCode using the following extensions and tools

  1. C++ Extension Pack
  2. Clang Format
  3. CMake Format and the corresponding extension
  4. SonarLint
  5. C++ Advanced Lint

Documentation

Documentation is located at Github Pages

License

Samarium is distributed under the MIT License.

Libraries Used

Many thanks to the following wonderful libraries:

  1. fmtlib
  2. range-v3
  3. BS::thread_pool
  4. PCG RNG
  5. tl::function_ref and tl::expected
  6. znone/call_thunk
  7. itlib-static-vector