Difference between revisions of "Blender"

From OpenFOAMWiki
m (Add BVTKNodes example gallery)
(Updates for new Blender 2.80)
 
Line 5: Line 5:
 
= Introduction =
 
= Introduction =
 
</noinclude>
 
</noinclude>
[http://www.blender.org Blender] is the free open source 3D content creation suite, available for all major operating systems under the [http://www.blender.org/education-help/faq/gpl-for-artists/ GNU General Public License]. This page lists links for using Blender with/for {{OpenFOAM}}.
+
[http://www.blender.org Blender] is [https://www.blender.org/about/ the free open source 3D content creation suite], available for all major operating systems under the [https://www.blender.org/about/license/ GNU General Public License]. This page lists links for using Blender with/for {{OpenFOAM}}.
  
 
<noinclude>
 
<noinclude>
Blender is a general purpose 3D content creation suite. Therefore it has several pros and cons, such as:
+
Most of [https://www.blender.org/features/ Blender features] are targeted for 3D artists. For OpenFOAM users, the most interesting Blender features include [https://en.wikipedia.org/wiki/Polygonal_modeling polygon surface mesh modelling], photo-realistic visualization, animation, and Python programming interface (for automation and creating add-ons that extend the software). Pros of Blender include a large on-line community, lot of on-line material, and add-ons. Cons of Blender include a steep learning curve, and fast changing / evolving software (tutorials get outdated quickly). The [https://www.blender.org/download/releases/2-80/ new Blender version 2.80 and later] includes a completely new UI compared to previous version 2.79.
; Pros : Large user base and a lot of documentation, books and add-ons are available. Blender can be a powerful modelling tool when mastered.
+
; Cons : Steep learning curve. If you don't know how to use Blender, it can be cumbersome for even simple tasks such as surface repair or for simply creating a sphere or cube.  
+
  
<br>
+
= Learning Blender =
 +
Links for OpenFOAM users to get familiar with Blender:
 +
* [https://www.blender.org/ Blender.org main page]
 +
* Youtube video series: [https://www.youtube.com/playlist?list=PLa1F2ddGya_-UvuAqHAksYnB0qL9yWDO6 Blender 2.8 fundamentals]
 +
 
 +
= List of links =
 
Wiki pages for using Blender with OpenFOAM:
 
Wiki pages for using Blender with OpenFOAM:
 
* [[Contrib/Unstructured_Grids_Addon_for_Blender | Unstructured Grids Addon for  Blender 2.8]]
 
* [[Contrib/Unstructured_Grids_Addon_for_Blender | Unstructured Grids Addon for  Blender 2.8]]
Line 25: Line 28:
 
* [https://github.com/tkeskita/io_mesh_vtk VTK polydata surface mesh Import-Export Add-on for Blender]
 
* [https://github.com/tkeskita/io_mesh_vtk VTK polydata surface mesh Import-Export Add-on for Blender]
  
<br>
+
= Old information =
 +
 
 
Here is a complete reference list of wiki pages that describe how to use Blender with/for OpenFOAM: {{#categorytree:Blender|mode=pages|hideroot=on}}
 
Here is a complete reference list of wiki pages that describe how to use Blender with/for OpenFOAM: {{#categorytree:Blender|mode=pages|hideroot=on}}
  
= Render OpenFOAM solutions with Blender =
+
== Render OpenFOAM solutions with Blender ==
 
All who are interested for rendering numerical solutions using Blender can start with the following scripts build by T. Holzmann: [http://www.holzmann-cfd.de/index.php/en/openfoam Blender Scripts]
 
All who are interested for rendering numerical solutions using Blender can start with the following scripts build by T. Holzmann: [http://www.holzmann-cfd.de/index.php/en/openfoam Blender Scripts]
 
You will find two python scripts. One is for Paraview (export x3d scenes) that is not complicated. The other one is used by Blender. You have to modify the Blender script in a way that it fit to your simulation and exported x3d scene. Good luck and have fun.
 
You will find two python scripts. One is for Paraview (export x3d scenes) that is not complicated. The other one is used by Blender. You have to modify the Blender script in a way that it fit to your simulation and exported x3d scene. Good luck and have fun.
  
== General proceeding ==
+
=== General proceeding ===
 
* Run your simulation
 
* Run your simulation
 
* Open Paraview and create your scene (save view)
 
* Open Paraview and create your scene (save view)

Latest revision as of 13:30, 27 October 2019



1 Introduction

Blender is the free open source 3D content creation suite, available for all major operating systems under the GNU General Public License. This page lists links for using Blender with/for OpenFOAM.


Most of Blender features are targeted for 3D artists. For OpenFOAM users, the most interesting Blender features include polygon surface mesh modelling, photo-realistic visualization, animation, and Python programming interface (for automation and creating add-ons that extend the software). Pros of Blender include a large on-line community, lot of on-line material, and add-ons. Cons of Blender include a steep learning curve, and fast changing / evolving software (tutorials get outdated quickly). The new Blender version 2.80 and later includes a completely new UI compared to previous version 2.79.

2 Learning Blender

Links for OpenFOAM users to get familiar with Blender:

3 List of links

Wiki pages for using Blender with OpenFOAM:

  • Unstructured Grids Addon for Blender 2.8
  • SnappyHexMesh GUI Addon for Blender 2.8
  • SwiftBlock - An addon for Blender acting as a GUI for creating the dictionary blockMeshDict, that lets the user create the desired hexahedral block structure as a mesh object within Blender 3D.
  • SwiftSnap - Another addon for Blender that acts as a GUI for creating the dictionary snappyHexMeshDict, that lets the user have full control over how and which feature lines are provided to snappyHexMesh. Further, the addon utilises Blender materials to let the user specify patches' names, resolution settings and mesh wall layers.


Blender related links outside wiki which OpenFOAM users may find useful:

4 Old information

Here is a complete reference list of wiki pages that describe how to use Blender with/for OpenFOAM:


4.1 Render OpenFOAM solutions with Blender

All who are interested for rendering numerical solutions using Blender can start with the following scripts build by T. Holzmann: Blender Scripts You will find two python scripts. One is for Paraview (export x3d scenes) that is not complicated. The other one is used by Blender. You have to modify the Blender script in a way that it fit to your simulation and exported x3d scene. Good luck and have fun.

4.1.1 General proceeding

  • Run your simulation
  • Open Paraview and create your scene (save view)
  • Modify the paraview.py python script
  • Run the paraview.py script to export all timesteps (or only one time step) as *.x3d file(s)
  • Modify the blender.py python script that it fit to your simulation
    • Tipp: Start without the loop (500 replaced with 1) and see how the script works
    • Tipp: Uncomment the last lines in the script (remove files and rendering)
    • Take a half day and watch tutorials for Blender (to get a bit more familiar), I recommend Jacob Lewis
  • After the python script works well and like you want, take a rest and render the guys