$0+

Gaussian Cube Blender Importer

0 ratings
I want this!

Gaussian Cube Blender Importer

$0+
0 ratings

Addon to import Gaussian Cube File, For Blender 3.0-3.5+ (written in Blender 3.5).

Written by René Meng for a 3 month internship about scientific visualisation with Matthieu Salanne at the Institute of Computing and Data Sciences(ISCD) at Sorbonne University.

(If OpenVDB is active this addon export VDB file to ./*_vdb_cache directory)

Some examples of Imported files:

To use Older versions of Blender you may need to disable OpenVDB as pyopenvdb if it isn't already.

If you run out of memory, OpenVDB volume may not display volume as desired. (i run on this issue with 4GB of ram)

Watch the French Tutorial: https://youtu.be/imFo62jpXp0

Main functionality:

- Use the Built in pyopenvdb, numpy, os, shutil

- ChatGPT wrote custom library to replace matplotlib.color for a color gradient, and ckdtree for nearest neighbour bonding.

- Fully support Molecular Dynamics: 1 file per frame as vertex position (only if OpenVDB active) see example for graphene: https://youtu.be/7KqpsXqUz4U

Installation

- 1 Download the code, then extract it.

- 2 Open Blender Edit>Preferences>Addon>install from file

- 3 Find the IO_Gaussian_CUBE.py addon and open it

- 4 Check the addon to activate


How to Use it ?

File>import>Gaussian_Cube

It opens the File Browser

Functionalities:

  • Create Bonding a custom kdtree: 0 is disabled points will be imported | 4 is four bonds with neighbours | 1,2,3 may not work as expected, keep trying, Number of bonding uses a custom tree to generate in average 4 bond per atom with the nearest neighbour.
  • A slider set The Green&crop throtle: If set to 0, There is no Green, full volume is displayed | If set to 0.1, Default Green and crop | If set to 1, You should see an empty object because you croped all the density

  • Import with color in all 3 of blender Render Engine(EEVEE, WorkBench(solid mode), Cycle), faster if ColorValue disabled.
  • Support Importing Gaussian Cube file with Geometry nodes (No support for Molecular Dynamics or EEVEE, Only Monochrome color is supported for Workbench,)
  • Uses OPENVDB, the read volume is exported to a cache file named vdbcache, and then imported back into Blender. Its in ./_vdb_cache directory where you can find all the VDB File and open it in other softwares.

You may need to delete cache Regularly by simply deleting the VDB_Cache directory, they contains the VDB File.

To import Molecular Dynamics, just select more file by pressing Ctrl or Shift and clicking. Or press A if you want all files to be selected.

Just press Spacebar or play to start playing MD:

Other things you can do with Blender and OpenVDB

  • You can mannualy change the density
  • You can make cut Slices
  • You can add a mesh and choose a Volume To Mesh Modifier to draw isosurface
  • You can make Mesh Bonds using Skin modifier (then you can press Ctrl+A to apply the modifier)
  • You can add balls to atoms

A big thanks to Matthieu Salanne and the rich community of the ISCD for the support.


This software is licensed as GNU General Public License (GPL) Licence publique générale GNU, v3.0 - Projet GNU - Free Software Foundation


Check the Github page for more information.

https://github.com/ero646545/IO_Gaussian_Cube_file_blender/tree/main

$
I want this!
Copy product URL