Skip to main content
  • Home
  • Development
  • Documentation
  • Donate
  • Operational login
  • Browse the archive

swh logo
SoftwareHeritage
Software
Heritage
Archive
Features
  • Search

  • Downloads

  • Save code now

  • Add forge now

  • Help

  • ab20b0c
  • /
  • README.md
Raw File Download
Permalinks

To reference or cite the objects present in the Software Heritage archive, permalinks based on SoftWare Hash IDentifiers (SWHIDs) must be used.
Select below a type of object currently browsed in order to display its associated SWHID and permalink.

  • content
  • directory
content badge Iframe embedding
swh:1:cnt:aea8c2454a74742e1dc2bbe0c16518e2a0fd6d3c
directory badge Iframe embedding
swh:1:dir:ab20b0c61c905c31d522c068fd98219b77284ce9
Citations

This interface enables to generate software citations, provided that the root directory of browsed objects contains a citation.cff or codemeta.json file.
Select below a type of object currently browsed in order to generate citations for them.

  • content
  • directory
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
README.md
# Adaptive Rigidification project code for Siggraph 2022
Matlab code for the adaptive rigidification project. This code base provides an implementation of the adaptive rigidification technique as seen at Siggraph 2022. Matlab is intuitive which makes the project easy to setup and results quickly reproducable. To test the various scenes featured in the paper, simply follow the instructions below then open an example file and click play in the editor. Alternatively the name of the example can be called in the command prompt which will launch the simulation. The scenes feature heterogenous materials, multiple objects, scripted animations, surface mapping and more!

The paper and a few useful videos are available on my website https://www.alexandremercieraubin.com/Work/papers/AdaptiveRigidification/.

## How to use

### Dependencies
required: opengl, visual studio (or any C++ compilers), cmake, matlab, gptoolbox(for 3D)
GPtoolbox might require: 
	embree https://github.com/embree/embree
	libigl https://github.com/libigl/libigl
	boost 1.48 https://www.boost.org/users/history/version_1_48_0.html
	to be detected automatically on windows use the path C:\Program Files\boost\boost_*
Tip: install visual studio before cmake so its compiler is automatically added to cmake

GpToolBox is already included in the repo as a subrepo. Simply call `git submodule update --init --recursive`.
cmake is needed to build gptoolbox's mex. You will need the boost library. 
I recommend not to build gptoolbox with eltopo if you are on windows.

We depend on GPToolbox for contacts(signed distances) as well as loading some mesh files.

Some matlab addons are needed or recommended such as Deep Learning Toolbox, Computer Vision Toolbox, Matlab Compiler, Signal Processing Toolbox, and Image processing Toolbox. Those can be found and downloaded from matlab's add-on menu.

### Installation
#### run the following commands in a command prompt
```
git submodule update --init --recursive ;
#if the recursive update fails then manually go to lib/gptoolbox/mex and build
cd lib/gptoolbox/mex ;
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DWITH_ELTOPO=false ;
cmake --build build --target install --config Release ;
xcopy /F /Y Release ./ ;
```

#### run the following commands in the matlab console
Once the project is set up, add the files to path by calling `addAdaptiveRigidificationToPath();` in the command prompt.
Followed by `mexAdaptiveRigidification();` to build the project's mex code.
```
addAdaptiveRigidificationToPath();
savepath();
mexAdaptiveRigidification();
```
By now you should be all set.

## Running scenes
Try running examples in 2d/examples or 3d/examples.
For instance while being in the root folder, you could open 2d/examples/cantilever_pinned.m and click play or simply call cantilever_pinned in the command prompt.
Why don't you try creating your own scene and play with it?

### FAQ
Please do cite the Adaptive Rigidification of Elastic Solids paper if you are using the ideas or code inspired by this simulator. 
Citations are important for us to obtain funding, and can be used as a proof that our work matters. 
We are also interested to hear from the companies that wish to use this fully or partially.

If you get a signed-distance error when running the 3D code, then you probably did not set up the compiled mex from gptoolbox properly.

Feel free to contact me if you find bugs and to send pull requests with fixes. 
We likewise have a private repository that we maintain with new research. 
Contact us to gain access to the private repository if you wish to collaborate with us on our newest/most exciting stuff.
Please cite us when using this simulator in your own research.

Special thanks to the collaborators Alexander Winter, David IW Levin and Paul Kry who participated in creating this simulator.
This simulator is now used by many students of the McGill physics-based animation lab .
We wish to keep expanding it over time.

Software Heritage — Copyright (C) 2015–2025, The Software Heritage developers. License: GNU AGPLv3+.
The source code of Software Heritage itself is available on our development forge.
The source code files archived by Software Heritage are available under their own copyright and licenses.
Terms of use: Archive access, API— Contact— JavaScript license information— Web API

back to top