Renderização por GPU

GPU rendering makes it possible to use your graphics card for rendering, instead of the CPU. This can speed up rendering because modern GPUs are designed to do quite a lot of number crunching. On the other hand, they also have some limitations in rendering complex scenes, due to more limited memory, and issues with interactivity when using the same graphics card for display and rendering.

To enable GPU rendering, go into the Preferences ‣ System ‣ Cycles Render Devices, and select either CUDA, Optix or OpenCL. Next, you must configure each scene to use GPU rendering in Properties ‣ Render ‣ Device.

Supported Hardware

Blender supports two different technologies to render on the GPU depending on the particular GPU manufacture.

Nvidia

CUDA and Optix are supported for GPU rendering with Nvidia graphics cards.

CUDA

CUDA requires graphics cards with compute capability 3.0 and higher. To make sure your GPU is supported, see the list of Nvidia graphics cards with the compute capabilities and supported graphics cards. CUDA GPU rendering is supported on Windows, macOS, and Linux.

Optix

For RTX graphics cards with hardware ray tracing support (e.g. Turing), Optix can be used for better performance. Optix support is still experimental and does not yet support all features, see below for details.

Optix requires Geforce or Quadro RTX graphics card with recent Nvidia drivers, and is supported on Windows and Linux.

AMD

OpenCL is supported for GPU rendering with AMD graphics cards. Blender supports graphics cards with GCN generation 2 and above. To make sure your GPU is supported, see the list of GCN generations with the GCN generation and supported graphics cards.

AMD OpenCL GPU rendering is supported on Windows and Linux, but not on macOS.

Funcionalidades Suportadas e Limitações.

CUDA and OpenCL rendering supports all the same features as CPU rendering, except two:

  • Open Shading Language.

  • Advanced volume light sampling to reduce noise.

Optix support is experimental and does not yet support the following features:

  • Baking

  • Branched Path Tracing

  • Ambient Occlusion and Bevel shader nodes

  • Combined CPU + GPU rendering

  • Using CPU memory for bigger scenes

Perguntas Frequentes

Porquê o Blender não responde durante a renderização?

Enquanto a placa gráfica está renderização, ela não consegue redesenhar a interface do usuário, o que torna o Blender não responsivo. Nós tentamos evitar esse problema devolvendo o controle sobre a GPU assim que possível, mas uma interação suave não pode ser garantida, especialmente em cenas pesadas. Essa é uma limitação de placas gráficas para as quais não há uma solução verdadeira, apesar de que poderemos ser capazes de melhorar isso de alguma forma no futuro.

Se possível, é melhor instalar mais de uma GPU, usando uma para a visualização e outra(s) para renderização.

Por que uma cena que renderiza na CPU não renderiza na GPU?

There maybe be multiple causes, but the most common is that there is not enough memory on your graphics card. Typically while using GPU rendering the GPU can only use the amount of memory that is on the GPU. This is usually much smaller then the amount of system memory that the CPU uses. In the case that the GPU runs out of memory Blender will automatically try to also use system and GPU memory. This has a performance impact but it is still faster than using CPU rendering. This feature does not work on OpenCL rendering.

Múltiplas GPUs podem ser usadas para renderização?

Yes, go to Preferences ‣ System ‣ Compute Device Panel, and configure it as you desire.

Múltiplas GPUs aumentam a memória disponível?

Não, cada GPU só pode acessar sua própria memória.

What renders faster, Nvidia or AMD, CUDA or OpenCL?

Currently Nvidia with CUDA is rendering fastest, but this really depends on the hardware you buy. Currently, CUDA and OpenCL are about the same in the newest mid-range GPUs. However, CUDA is fastest in the respect of high-end GPUs.

Mensagens de erro

In case of problems, be sure to install the official graphics drivers from the Nvidia or AMD website, or through the package manager on Linux.

Versão GPU não suportada! gcc 4.7 e acima não são suportadas!

On Linux, depending on your GCC version you might get this error. There are two possible solutions:

Use an alternate compiler

If you have an older GCC installed that is compatible with the installed CUDA toolkit version, then you can use it instead of the default compiler. This is done by setting the CYCLES_CUDA_EXTRA_CFLAGS environment variable when starting Blender.

Launch Blender from the command line as follows:

CYCLES_CUDA_EXTRA_CFLAGS="-ccbin gcc-x.x" blender

(Substitute the name or path of the compatible GCC compiler).

Remove compatibility checks

If the above is unsuccessful, delete the following line in /usr/local/cuda/include/host_config.h

#error -- unsupported GNU version! gcc 4.7 and up are not supported!

This will allow Cycles to successfully compile the CUDA rendering kernel the first time it attempts to use your GPU for rendering. Once the kernel is built successfully, you can launch Blender as you normally would and the CUDA kernel will still be used for rendering.

Erro CUDA: imagem kernel inválida

If you get this error on Windows 64-bit, be sure to use the 64-bit build of Blender, not the 32-bit version.

Erro CUDA: Compilação do Kernel falhou

This error may happen if you have a new Nvidia graphics card that is not yet supported by the Blender version and CUDA toolkit you have installed. In this case Blender may try to dynamically build a kernel for your graphics card and fail.

Neste caso você pode:

  1. Checar se a última versão do Blender (oficial ou versão experimental) suporta sua placa gráfica.

  2. Se você compilar o Blender você mesmo, tente baixar e instalar uma nova versão de desenvolvedor do kit de ferramentas CUDA.

Normalmente usuários não precisam instalar o kit de ferramentas CUDA já que o Blender vem com os kerneis pré compilados.

Erro CUDA: Sem memória

Isso geralmente significa que não há memória suficiente para armazenar a cena na GPU. Nós atualmente podemos apenas renderizar cenas que cabem na memória da placa gráfica, e ela é geralmente menor que a do CPU. Veja acima para mais detalhes.

Nota

One way to reduce memory usage is by using smaller resolutions for textures. For example, 8k, 4k, 2k, and 1k image textures take up respectively 256MB, 64MB, 16MB and 4MB of memory.

The Nvidia OpenGL driver lost connection with the display driver

If a GPU is used for both display and rendering, Windows has a limit on the time the GPU can do render computations. If you have a particularly heavy scene, Cycles can take up too much GPU time. Reducing Tile Size in the Performance panel may alleviate the issue, but the only real solution is to use separate graphics cards for display and rendering.

Outra solução pode ser aumentar o tempo limite, apesar que isso irá fazer a interface do usuário menos responsiva quando renderizando cenas pesadas.`Aprenda Mais Aqui <https://msdn.microsoft.com/en-us/Library/Windows/Hardware/ff570087%28v=vs.85%29.aspx>`__.

Erro CUDA: Erro desconhecido em cuCtxSynchronize()

Um erro desconhecido pode ter muitas causas, mas uma possibilidade é que o tempo se esgotou. Veja acima respostas para soluções.