Skip to content

Commit

Permalink
init commit
Browse files Browse the repository at this point in the history
  • Loading branch information
YunzhuLi committed Mar 17, 2019
0 parents commit da6d8dc
Show file tree
Hide file tree
Showing 1,435 changed files with 813,265 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
__pycache__
.idea
*.swp
*.swo
25 changes: 25 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
Copyright (c) 2013-2017 NVIDIA Corporation. All rights reserved.

This code contains NVIDIA Confidential Information and is disclosed to you
under a form of NVIDIA software license agreement provided separately to you.

NVIDIA Corporation and its licensors retain all intellectual property and
proprietary rights in and to this software and related documentation and
any modifications thereto. Any use, reproduction, disclosure, or
distribution of this software and related documentation without an express
license agreement from NVIDIA Corporation is strictly prohibited.

ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES
NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,
MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.

Information and code furnished is believed to be accurate and reliable.
However, NVIDIA Corporation assumes no responsibility for the consequences of use of such
information or for any infringement of patents or other rights of third parties that may
result from its use. No license is granted by implication or otherwise under any patent
or patent rights of NVIDIA Corporation. Details are subject to change without notice.
This code supersedes and replaces all information previously supplied.
NVIDIA Corporation products are not authorized for use as critical
components in life support devices or systems without express written approval of
NVIDIA Corporation.
42 changes: 42 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
PyFleX
======


Compile demo
------------

cd demo/compiler/makelinux64/
make


Compile demo using cmake
------------------------

cd examples/
mkdir build; cd build; cmake ..; make -j
./example


Compile demo with cmake & Pybind11
----------------------------------

cd bindings/
mkdir build; cd build; cmake ..; make -j
export PYFLEXROOT=/home/yunzhu/Documents/PyFleX
export PYTHONPATH=${PYFLEXROOT}/bindings/build:$PYTHONPATH
export export LD_LIBRARY_PATH=${PYFLEXROOT}/external/SDL2-2.0.4/lib/x64:$LD_LIBRARY_PATH

python -c "import pyflex; pyflex.main()"

cd ${PYFLEX}/bindings/examples
python test.py


Demo
----


References
----------

Original NVIDIA FleX - 1.2.0 [readme](README_FleX.md)
105 changes: 105 additions & 0 deletions README_FleX.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
NVIDIA Flex - 1.2.0
===================

Flex is a particle-based simulation library designed for real-time applications.
Please see the programmer's manual included in this release package for more information on
the solver API and usage.

Supported Platforms
-------------------

* Windows 32/64 bit (CUDA, DX11, DX12)
* Linux 64 bit (CUDA, tested with Ubuntu 16.04 LTS and Mint 17.2 Rafaela)

Requirements
------------

A D3D11 capable graphics card with the following driver versions:

* NVIDIA GeForce Game Ready Driver 372.90 or above
* AMD Radeon Software Version 16.9.1 or above
* Intel® Graphics Version 15.33.43.4425 or above

To build the demo at least one of the following is required:

* Microsoft Visual Studio 2013
* Microsoft Visual Studio 2015
* g++ 4.6.3 or higher

And either:

* CUDA 9.1.85 toolkit
* DirectX 11/12 SDK

Demo
====

Use the `run_cuda.bat` or `run_d3d.bat` files to launch the demo.

Notes
-----

* Some scenes also have fluid emitters that can be started using 'space'
* For running the Linux binaries you will need to export the path to where the CUDA run time libraries are
For example, you may add to your .bashrc file the following:

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64


Command Line Options
--------------------

The following commands may be passed to the demo application to modify behavior:

-fullscreen=wxh Start fullscreen e.g.: -fullscreen=1280x720
-msaa=0 Disable multisampling (default is on)
-device=n Choose GPU to run on
-d3d12 Enable D3D12 compute
-benchmark Enable bencmark mode, will write a benchmark.txt to the root folder
-vsync=0 Disable vsync

Controls
--------

w,s,a,d - Fly Camera
right mouse - Mouse look
shift + left mouse - Particle select and drag

p - Pause/Unpause
o - Step
h - Hide/Show onscreen help

left/right arrow keys - Move to prev/next scene
up/down arrow keys - Select next scene
enter - Launch selected scene
r - Reset current scene

e - Draw fluid surface
v - Draw points
f - Draw springs
i - Draw diffuse
m - Draw meshes

space - Toggle fluid emitter
y - Toggle wave pool
c - Toggle video capture
u - Toggle fullscreen
j - Wind gust
- - Remove a plane
esc - Quit

Known Issues
============

* Crash with inflatable scenes on Intel HD Graphics 530
* MSAA is broken on D3D12 and currently disabled

Acknowledgements
================

* SDL is licensed under the zlib license
* GLEW is licensed under the Modified BSD license
* Regal is licensed under the BSD license
* stb_truetype by Sean Barrett is public domain
* imgui by Mikko Mononen is licensed under the ZLib license

Loading

0 comments on commit da6d8dc

Please sign in to comment.