blenderproc.python.modules.renderer.RendererInterface module

class blenderproc.python.modules.renderer.RendererInterface.RendererInterface(config)[source]

Bases: blenderproc.python.modules.main.Module.Module

Configuration:

Parameter Description Type
output_file_prefix The file prefix that should be used when writing the rendering to file. String
output_key The key which should be used for storing the rendering in a merged file. which should be used for storing the rendering in a merged file. String
samples Number of samples to render for each pixel. Higher numbers take longer but remove noise in dark areas. Default: 256, (not true for all Renderes). int
use_adaptive_sampling Combined with the maximum sample amount, it is also possible to set the amount of noise left per pixel. This means pixel is sampled until the noise level is smaller than specified or the maximum amount of samples were reached. Do not use this with Non-RGB-Renders! Only used if specified” in config. Default: 0.0 float
simplify_subdivision_render Global maximum subdivision level during rendering. Speeds up rendering. Default: 3 int
denoiser The denoiser to use. Set to “Blender”, if the Blender’s built-in denoiser should be used or set to “Intel”, if you want to use the Intel Open Image Denoiser, performs much better. Default: “Intel” Available: [“Intel”, “Blender”]. string
max_bounces Total maximum number of bounces. Default: 3 int
diffuse_bounces Maximum number of diffuse reflection bounces, bounded by total maximum. Default: 3 int
glossy_bounces Maximum number of glossy reflection bounces, bounded by total maximum. Be careful the default is set to zero to improve rendering time, but it removes all indirect glossy rays from the rendering process. Default: 0 int
ao_bounces_render Approximate indirect light with background tinted ambient occlusion at the specified bounce. Default: 3 int
transmission_bounces Maximum number of transmission bounces, bounded by total maximum. Be careful the default is set to zero to improve rendering time, but it removes all indirect transmission rays from the rendering process. Default: 0 int
transparency_bounces Maximum number of transparency bounces, bounded by total maximum. A higher value helps if a lot of transparency objects are stacked after each other. Default: 8 int
volume_bounces Maximum number of volumetric scattering events. Default: 0 int
render_distance If true, the distance is also rendered to file. Default: False. bool
distance_output_file_prefix The file prefix that should be used when writing distance to file. Default: “distance_” string
distance_output_key The key which should be used for storing the distance in a merged file. Default: “distance”. string
distance_range Total distance in which the distance is measured. Default: 10000.0 float
render_depth If true, the z-buffer is also rendered to file. Default: False. bool
depth_output_file_prefix The file prefix that should be used when writing depth to file. Default: “depth_” string
depth_output_key The key which should be used for storing the depth in a merged file. Default: “depth”. string
use_alpha If true, the alpha channel stored in .png textures is used. Default: False bool
stereo If true, renders a pair of stereoscopic images for each camera position. Default: False bool
cpu_threads Set number of cpu cores used for rendering (1 thread is always used for coordination if more than one cpu thread means GPU-only rendering). When 0 is set, the number of threads will be set automatically. Default: 0 int
render_normals If true, the normals are also rendered. Default: False bool
normals_output_file_prefix The file prefix that should be used when writing normals. Default: “normals_” string
normals_output_key The key which is used for storing the normal in a merged file. Default: “normal” string
render_diffuse_color If true, the diffuse color image are also rendered. Default: False bool
_configure_renderer(max_amount_of_samples=1024, use_denoiser=False, default_denoiser='Intel')[source]

Sets many different render parameters which can be adjusted via the config.

Parameters:
  • max_amount_of_samples (int) – Default maximum number of samples to render for each pixel
  • use_denoiser (bool) – If true, a denoiser is used, only use this on color information
  • default_denoiser (str) – Either “Intel” or “Blender”, “Intel” performs much better in most cases
_render(default_prefix, default_key, output_key_parameter_name='output_key', output_file_prefix_parameter_name='output_file_prefix', enable_transparency=False, file_format='PNG')[source]

Renders each registered keypoint.

Parameters:default_prefix (str) – The default prefix of the output files.