Blender

From Gentoo Wiki
Jump to: navigation, search
The information in this article is probably outdated. You can help the Gentoo community by verifying and updating this article.
Resources

Blender is free and open-source 3D computer graphics software, commonly used to create and animate 3D models, or to edit videos.

Installation

USE flags

There are many additional features that can be enabled via USE flags, and some of them are explained a little more in-depth later on in this article.

USE flags for media-gfx/blender 3D Creation/Animation/Publishing System

abi6-compat Build for OpenVDB ABI 6.
abi7-compat Build for OpenVDB ABI 7.
alembic Add support for Alembic through media-gfx/alembic.
bullet Enable Bullet (Physics Engine).
collada Add support for Collada interchange format through media-libs/opencollada.
color-management Enable color management via media-libs/opencolorio.
cuda Build cycles renderer with nVidia CUDA support.
cycles Build cycles renderer (requires media-libs/openimageio and dev-libs/boost).
dds Adds DDS textures support to Blender.
debug Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
doc Build C and Python API documentation directly from the source code.
elbeem Adds surface fluid simulation to Blender using El'Beem library.
ffmpeg Enable ffmpeg/libav-based audio/video codec support
fftw Use FFTW library for computing Fourier transforms
headless Build without graphical support (renderfarm, server mode only).
jack Add support for the JACK Audio Connection Kit
jemalloc Use dev-libs/jemalloc for memory management
jpeg2k Support for JPEG 2000, a wavelet-based image compression format
llvm Enable features depending on llvm.
man Build and install man pages.
ndof Enable NDOF input devices (SpaceNavigator and friends).
nls Add Native Language Support (using gettextGNU locale utilities)
openal Add support for the Open Audio Library
opencl Allow OpenCL Graphics Acceleration. This may require extra graphics card drivers.
openexr Support for the OpenEXR graphics file format
openimageio Enable OpenImageIO Support
openmp Build support for the OpenMP (support parallel computing), requires >=sys-devel/gcc-4.2 built with USE="openmp"
opensubdiv Add rendering support form OpenSubdiv from Dreamworks Animation through media-libs/opensubdiv.
openvdb Add GPU preview rendering. Only works with nVidia cards.
osl Add support for OpenShadingLanguage scripting.
sdl Add support for Simple Direct Layer (media library)
sndfile Add support for libsndfile
standalone Build the standalone version of Cycles.
system-numpy Use the system numpy implementation rather than a local copy.
system-python Use the system python implementation rather than a local copy.
tbb Use threading building blocks library from dev-cpp/tbb.
test Build the provided unit tests.
tiff Add support for the TIFF image format
valgrind Add support for memory debugging using dev-util/valgrind

Emerge

root #emerge --ask media-gfx/blender
Note
To test what unstable packages an unstable version might need, making use of the --autounmask=y --autounmask-write emerge options can be helpful in populating a list for further review.

Additional features

This section lists many of the optional features available in blender and gives a brief overview of their use for beginning users.

Audio device support

Support for Jack, OpenAL, or SDL audio can optionally be enabled through their respective USE flags.

Inside Blender, go to the File->User Preferences->System tab and set the Audio Dev to the desired setting.

CUDA support

Cycles renderer can work on GPUs, for example Nvidia GTX 970 is about twice as fast as an i5 4690k on traditional BMW benchmark.

To enable graphics card rendering with Nvidia graphics cards, install Cuda:

root #emerge --ask --verbose dev-util/nvidia-cuda-toolkit

Inside Blender, go to the File->User Preferences->System tab and set Compute Device to CUDA and select the graphics card in the box below. If the graphics card is not supported these options will not be visible.

Now set the renderer to Cycles Renderer and in the renderer panel under the Render options set the Device to GPU Compute.

The first time a render is created with a new version of blender, the CUDA kernels will need to be compiled. This may take over 15 minutes.

File format support

Support OpenCOLLADA (.dae), jpeg2k, sndfile, and tiff image file formats can optionally be enabled through USE flags.

The collada USE flag adds entries to File->Import/Export for Collada (Default) (.dae) files. The others can be used with background images in the properties panel of the 3D View or as output formats in the render panel.

Blender should work with either ffmpeg or libav libraries, although only ffmpeg is officially recommended by the Blender developers.

Headless (server only)

For render farms it is possible to compile blender with the headless USE flag. This is not recommended for most users.

This feature reduces the Blender file size by around 5 MB, but it will not be possible to run blender normally as the GUI is not available.

In headless mode, Blender can still be used to run python scripts from the commmand line:

user $user $ blender -b -P script.py [-- [--optionsforscript .. ] ]
Note
This functionality is also available with regular versions of Blender, it is not necessary to enable the headless USE flag to run scripts from the command line.

Memory allocator

It is recommended to enable jemalloc to use a more efficient memory allocator. This reduces wasted memory during rendering and allows for larger scenes to be rendered.

Memory profiling

Support for memory profiling can be enabled using the valgrind USE flag. See Debugging for instructions on setting up Valgrind.

OpenColorio

Open Colorio provides additional options under the Color Management section of the Scene panel.

Inside Blender, select the Render View and Look options, and adjust the exposure, gamma, and curves to obtain the desired look.

Opensubdiv

Opensubdiv is a set of libraries that improve subdivision surface modifier evaluation. This can dramatically improve the frame rate of viewing animations in the viewport when using high levels of subdivision.

Not all cards are suitable. The current code checks for geometry shader, GL_ARB_gpu_shader5, glProgramParameteri, glProgramParameteriEXT, and glProgramParameteriARB. These are available as part of OpenGL 3.2, 4.0, and 4.1, or as extensions.

Support is enabled via the opensubdiv USE flag.

Inside Blender, go to the File->User Preferences->System tab and set OpenSubdiv compute to the desired option. It may be possible to choose the CPU, but cards which support GLSL Compute will give better performance. This box will not appear if the card does not meet the requirements.

Finally check the Use Opensubdiv box in the subdivision surface modifier

OpenVDB

OpenVDB provides a data structure for storing and manipulating volumetric information efficiently. It can be compiled into blender using the openvdb USE flag, and openvdb-compression is also recommended as the data can require upwards of 20MB.

In Blender, set the renderer to Cycles Renderer. Go to the physics panel and enable physics for Smoke. In the smoke section select Domain. Save the file to enable editing of the smoke cache. Change File Format to Openvdb and select Blosc compression if desired. Now create and bake the simulation.

See also

External resources