2023-08-16 00:20:26 +10:00
|
|
|
# SPDX-FileCopyrightText: 2009-2023 Blender Authors
|
2023-06-15 13:09:04 +10:00
|
|
|
#
|
2022-02-11 09:07:11 +11:00
|
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
2023-06-15 13:09:04 +10:00
|
|
|
|
2019-03-14 15:14:43 +11:00
|
|
|
from bpy.types import Panel
|
2025-09-14 21:37:45 +02:00
|
|
|
from bpy.app.translations import contexts as i18n_contexts
|
2023-12-24 22:17:31 +01:00
|
|
|
from bl_ui.properties_grease_pencil_common import GreasePencilSimplifyPanel
|
2019-06-11 16:08:32 +10:00
|
|
|
from bl_ui.space_view3d import (
|
2018-07-11 11:43:56 +02:00
|
|
|
VIEW3D_PT_shading_lighting,
|
|
|
|
|
VIEW3D_PT_shading_color,
|
|
|
|
|
VIEW3D_PT_shading_options,
|
2025-03-05 11:45:00 +01:00
|
|
|
VIEW3D_PT_shading_cavity,
|
2018-07-11 11:43:56 +02:00
|
|
|
)
|
2023-12-24 22:17:31 +01:00
|
|
|
from bl_ui.utils import PresetPanel
|
2019-09-12 16:12:19 +02:00
|
|
|
|
2009-11-14 13:35:44 +00:00
|
|
|
|
2015-01-29 15:35:06 +11:00
|
|
|
class RenderButtonsPanel:
|
2009-10-31 19:31:45 +00:00
|
|
|
bl_space_type = 'PROPERTIES'
|
|
|
|
|
bl_region_type = 'WINDOW'
|
|
|
|
|
bl_context = "render"
|
|
|
|
|
# COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here
|
|
|
|
|
|
2010-08-09 01:37:09 +00:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
2018-04-17 13:35:05 +02:00
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
2017-10-16 17:15:03 -02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_context(Panel):
|
|
|
|
|
bl_space_type = 'PROPERTIES'
|
|
|
|
|
bl_region_type = 'WINDOW'
|
|
|
|
|
bl_context = "render"
|
|
|
|
|
bl_options = {'HIDE_HEADER'}
|
|
|
|
|
bl_label = ""
|
|
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return context.scene
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
2018-05-31 16:05:38 +02:00
|
|
|
layout.use_property_split = True
|
2018-06-18 12:41:31 +02:00
|
|
|
layout.use_property_decorate = False
|
2017-10-16 17:15:03 -02:00
|
|
|
|
|
|
|
|
scene = context.scene
|
2018-04-17 13:35:05 +02:00
|
|
|
rd = scene.render
|
2017-10-16 17:15:03 -02:00
|
|
|
|
2018-04-17 13:35:05 +02:00
|
|
|
if rd.has_multiple_engines:
|
2018-05-31 16:05:38 +02:00
|
|
|
layout.prop(rd, "engine", text="Render Engine")
|
2012-12-20 07:57:26 +00:00
|
|
|
|
|
|
|
|
|
2018-10-31 13:06:44 +01:00
|
|
|
class RENDER_PT_color_management(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Color Management"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2019-05-19 11:23:43 +02:00
|
|
|
bl_order = 100
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2018-10-31 13:06:44 +01:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
2023-08-09 14:25:15 +02:00
|
|
|
|
2018-10-31 13:06:44 +01:00
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2018-11-02 15:31:17 +01:00
|
|
|
layout.use_property_decorate = False # No animation.
|
2018-10-31 13:06:44 +01:00
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
view = scene.view_settings
|
|
|
|
|
|
|
|
|
|
flow = layout.grid_flow(row_major=True, columns=0, even_columns=False, even_rows=False, align=True)
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(scene.display_settings, "display_device")
|
|
|
|
|
|
|
|
|
|
col.separator()
|
|
|
|
|
|
|
|
|
|
col.prop(view, "view_transform")
|
|
|
|
|
col.prop(view, "look")
|
|
|
|
|
|
2025-08-28 11:03:24 +02:00
|
|
|
if view.is_hdr and not context.window.support_hdr_color:
|
|
|
|
|
row = col.split(factor=0.4)
|
|
|
|
|
row.label()
|
|
|
|
|
row.label(text="HDR display not supported", icon="INFO")
|
2025-08-15 14:26:54 +02:00
|
|
|
|
2018-10-31 13:06:44 +01:00
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(view, "exposure")
|
|
|
|
|
col.prop(view, "gamma")
|
|
|
|
|
|
2025-08-31 02:58:12 +02:00
|
|
|
|
|
|
|
|
class RENDER_PT_color_management_working_space(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Working Space"
|
|
|
|
|
bl_parent_id = "RENDER_PT_color_management"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
|
|
|
|
'BLENDER_EEVEE',
|
|
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
blend_colorspace = context.blend_data.colorspace
|
|
|
|
|
|
|
|
|
|
flow = layout.grid_flow(row_major=True, columns=0, even_columns=False, even_rows=False, align=True)
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
|
|
|
|
|
split = col.split(factor=0.4)
|
|
|
|
|
row = split.row()
|
|
|
|
|
row.label(text="File")
|
|
|
|
|
row.alignment = 'RIGHT'
|
2025-09-14 21:37:45 +02:00
|
|
|
split.operator_menu_enum(
|
|
|
|
|
"wm.set_working_color_space",
|
|
|
|
|
"working_space",
|
|
|
|
|
text=blend_colorspace.working_space,
|
|
|
|
|
text_ctxt=i18n_contexts.default,
|
|
|
|
|
)
|
2018-10-31 13:06:44 +01:00
|
|
|
|
|
|
|
|
col.prop(scene.sequencer_colorspace_settings, "name", text="Sequencer")
|
|
|
|
|
|
|
|
|
|
|
2025-09-26 17:05:18 +02:00
|
|
|
class RENDER_PT_color_management_advanced(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Advanced"
|
|
|
|
|
bl_parent_id = "RENDER_PT_color_management"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
|
|
|
|
'BLENDER_EEVEE',
|
|
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.active = scene.view_settings.support_emulation
|
|
|
|
|
col.prop(scene.display_settings, "emulation")
|
|
|
|
|
|
|
|
|
|
|
2018-10-31 13:06:44 +01:00
|
|
|
class RENDER_PT_color_management_curves(RenderButtonsPanel, Panel):
|
Color management: Support white balance as part of the display transform
This implements a von-Kries-style chromatic adaption using the Bradford matrix.
The adaption is performed in scene linear space in the OCIO GLSL shader, with
the matrix being computed on the host.
The parameters specify the white point of the input, which is to be mapped to
the white point of the scene linear space. The main parameter is temperature,
specified in Kelvin, which defines the blackbody spectrum that is used as the
input white point. Additionally, a tint parameter can be used to shift the
white point away from pure blackbody spectra (e.g. to match a D illuminant).
The defaults are set to match D65 so there is no immediate color shift when
enabling the option. Tint = 10 is needed since the D-series illuminants aren't
perfect blackbody emitters.
As an alternative to manually specifying the values, there's also a color
picker. When a color is selected, temperature and tint are set such that this
color ends up being balanced to white.
This only works if the color is close enough to a blackbody emitter -
specifically, for tint values within +-150. Beyond this, there can be ambiguity
in the representation.
Currently, in this case, the input is just ignored and temperature/tint aren't
changed. Ideally, we'd eventually give UI feedback for this.
Presets are supported, and all the CIE standard illuminants are included.
One part that I'm not quite happy with is that the tint parameter starts to
give weird results at moderate values when the temperature is low.
The reason for this can be seen here:
https://commons.wikimedia.org/wiki/File:Planckian-locus.png
Tint is moving along the isotherm lines (with the plot corresponding to +-150),
but below 4000K some of that range is outside of the gamut. Not much can
be done there, other than possibly clipping those values...
Adding support for this to the compositor should be quite easy and is planned
as a next step.
Pull Request: https://projects.blender.org/blender/blender/pulls/123278
2024-06-27 23:27:58 +02:00
|
|
|
bl_label = "Curves"
|
2018-10-31 13:06:44 +01:00
|
|
|
bl_parent_id = "RENDER_PT_color_management"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2018-10-31 13:06:44 +01:00
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
view = scene.view_settings
|
|
|
|
|
|
|
|
|
|
self.layout.prop(view, "use_curve_mapping", text="")
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
view = scene.view_settings
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = False
|
2018-11-02 15:31:17 +01:00
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
Color management: Support white balance as part of the display transform
This implements a von-Kries-style chromatic adaption using the Bradford matrix.
The adaption is performed in scene linear space in the OCIO GLSL shader, with
the matrix being computed on the host.
The parameters specify the white point of the input, which is to be mapped to
the white point of the scene linear space. The main parameter is temperature,
specified in Kelvin, which defines the blackbody spectrum that is used as the
input white point. Additionally, a tint parameter can be used to shift the
white point away from pure blackbody spectra (e.g. to match a D illuminant).
The defaults are set to match D65 so there is no immediate color shift when
enabling the option. Tint = 10 is needed since the D-series illuminants aren't
perfect blackbody emitters.
As an alternative to manually specifying the values, there's also a color
picker. When a color is selected, temperature and tint are set such that this
color ends up being balanced to white.
This only works if the color is close enough to a blackbody emitter -
specifically, for tint values within +-150. Beyond this, there can be ambiguity
in the representation.
Currently, in this case, the input is just ignored and temperature/tint aren't
changed. Ideally, we'd eventually give UI feedback for this.
Presets are supported, and all the CIE standard illuminants are included.
One part that I'm not quite happy with is that the tint parameter starts to
give weird results at moderate values when the temperature is low.
The reason for this can be seen here:
https://commons.wikimedia.org/wiki/File:Planckian-locus.png
Tint is moving along the isotherm lines (with the plot corresponding to +-150),
but below 4000K some of that range is outside of the gamut. Not much can
be done there, other than possibly clipping those values...
Adding support for this to the compositor should be quite easy and is planned
as a next step.
Pull Request: https://projects.blender.org/blender/blender/pulls/123278
2024-06-27 23:27:58 +02:00
|
|
|
layout.active = view.use_curve_mapping
|
2018-10-31 13:06:44 +01:00
|
|
|
|
2019-03-04 22:06:23 +11:00
|
|
|
layout.template_curve_mapping(view, "curve_mapping", type='COLOR', levels=True)
|
2018-10-31 13:06:44 +01:00
|
|
|
|
|
|
|
|
|
Color management: Support white balance as part of the display transform
This implements a von-Kries-style chromatic adaption using the Bradford matrix.
The adaption is performed in scene linear space in the OCIO GLSL shader, with
the matrix being computed on the host.
The parameters specify the white point of the input, which is to be mapped to
the white point of the scene linear space. The main parameter is temperature,
specified in Kelvin, which defines the blackbody spectrum that is used as the
input white point. Additionally, a tint parameter can be used to shift the
white point away from pure blackbody spectra (e.g. to match a D illuminant).
The defaults are set to match D65 so there is no immediate color shift when
enabling the option. Tint = 10 is needed since the D-series illuminants aren't
perfect blackbody emitters.
As an alternative to manually specifying the values, there's also a color
picker. When a color is selected, temperature and tint are set such that this
color ends up being balanced to white.
This only works if the color is close enough to a blackbody emitter -
specifically, for tint values within +-150. Beyond this, there can be ambiguity
in the representation.
Currently, in this case, the input is just ignored and temperature/tint aren't
changed. Ideally, we'd eventually give UI feedback for this.
Presets are supported, and all the CIE standard illuminants are included.
One part that I'm not quite happy with is that the tint parameter starts to
give weird results at moderate values when the temperature is low.
The reason for this can be seen here:
https://commons.wikimedia.org/wiki/File:Planckian-locus.png
Tint is moving along the isotherm lines (with the plot corresponding to +-150),
but below 4000K some of that range is outside of the gamut. Not much can
be done there, other than possibly clipping those values...
Adding support for this to the compositor should be quite easy and is planned
as a next step.
Pull Request: https://projects.blender.org/blender/blender/pulls/123278
2024-06-27 23:27:58 +02:00
|
|
|
class RENDER_PT_color_management_white_balance_presets(PresetPanel, Panel):
|
|
|
|
|
bl_label = "White Balance Presets"
|
|
|
|
|
preset_subdir = "color_management/white_balance"
|
|
|
|
|
preset_operator = "script.execute_preset"
|
|
|
|
|
preset_add_operator = "render.color_management_white_balance_preset_add"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_color_management_white_balance(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "White Balance"
|
|
|
|
|
bl_parent_id = "RENDER_PT_color_management"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
Color management: Support white balance as part of the display transform
This implements a von-Kries-style chromatic adaption using the Bradford matrix.
The adaption is performed in scene linear space in the OCIO GLSL shader, with
the matrix being computed on the host.
The parameters specify the white point of the input, which is to be mapped to
the white point of the scene linear space. The main parameter is temperature,
specified in Kelvin, which defines the blackbody spectrum that is used as the
input white point. Additionally, a tint parameter can be used to shift the
white point away from pure blackbody spectra (e.g. to match a D illuminant).
The defaults are set to match D65 so there is no immediate color shift when
enabling the option. Tint = 10 is needed since the D-series illuminants aren't
perfect blackbody emitters.
As an alternative to manually specifying the values, there's also a color
picker. When a color is selected, temperature and tint are set such that this
color ends up being balanced to white.
This only works if the color is close enough to a blackbody emitter -
specifically, for tint values within +-150. Beyond this, there can be ambiguity
in the representation.
Currently, in this case, the input is just ignored and temperature/tint aren't
changed. Ideally, we'd eventually give UI feedback for this.
Presets are supported, and all the CIE standard illuminants are included.
One part that I'm not quite happy with is that the tint parameter starts to
give weird results at moderate values when the temperature is low.
The reason for this can be seen here:
https://commons.wikimedia.org/wiki/File:Planckian-locus.png
Tint is moving along the isotherm lines (with the plot corresponding to +-150),
but below 4000K some of that range is outside of the gamut. Not much can
be done there, other than possibly clipping those values...
Adding support for this to the compositor should be quite easy and is planned
as a next step.
Pull Request: https://projects.blender.org/blender/blender/pulls/123278
2024-06-27 23:27:58 +02:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
view = scene.view_settings
|
|
|
|
|
|
|
|
|
|
self.layout.prop(view, "use_white_balance", text="")
|
|
|
|
|
|
|
|
|
|
def draw_header_preset(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
|
|
RENDER_PT_color_management_white_balance_presets.draw_panel_header(layout)
|
|
|
|
|
|
|
|
|
|
eye = layout.operator("ui.eyedropper_color", text="", icon='EYEDROPPER')
|
|
|
|
|
eye.prop_data_path = "scene.view_settings.white_balance_whitepoint"
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
view = scene.view_settings
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
layout.active = view.use_white_balance
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(view, "white_balance_temperature")
|
|
|
|
|
col.prop(view, "white_balance_tint")
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_motion_blur(RenderButtonsPanel, Panel):
|
2022-07-27 17:35:10 +02:00
|
|
|
bl_label = "Motion Blur"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2022-07-27 17:35:10 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
|
scene = context.scene
|
2024-02-08 16:49:18 +01:00
|
|
|
props = scene.render
|
2022-07-27 17:35:10 +02:00
|
|
|
self.layout.prop(props, "use_motion_blur", text="")
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
scene = context.scene
|
2024-02-08 16:49:18 +01:00
|
|
|
props = scene.render
|
|
|
|
|
eevee_props = scene.eevee
|
2022-07-27 17:35:10 +02:00
|
|
|
|
|
|
|
|
layout.active = props.use_motion_blur
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "motion_blur_position", text="Position")
|
|
|
|
|
col.prop(props, "motion_blur_shutter")
|
|
|
|
|
col.separator()
|
2024-02-08 16:49:18 +01:00
|
|
|
col.prop(eevee_props, "motion_blur_depth_scale")
|
|
|
|
|
col.prop(eevee_props, "motion_blur_max")
|
|
|
|
|
col.prop(eevee_props, "motion_blur_steps", text="Steps")
|
2022-07-27 17:35:10 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_motion_blur_curve(RenderButtonsPanel, Panel):
|
2022-07-29 18:01:59 +02:00
|
|
|
bl_label = "Shutter Curve"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_motion_blur"
|
2022-07-29 18:01:59 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2022-07-29 18:01:59 +02:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
layout.active = rd.use_motion_blur
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
|
|
|
|
|
col.template_curve_mapping(rd, "motion_blur_shutter_curve")
|
|
|
|
|
|
|
|
|
|
col = layout.column(align=True)
|
|
|
|
|
row = col.row(align=True)
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='SMOOTHCURVE', text="").shape = 'SMOOTH'
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='SPHERECURVE', text="").shape = 'ROUND'
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='ROOTCURVE', text="").shape = 'ROOT'
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='SHARPCURVE', text="").shape = 'SHARP'
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='LINCURVE', text="").shape = 'LINE'
|
|
|
|
|
row.operator("render.shutter_curve_preset", icon='NOCURVE', text="").shape = 'MAX'
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_depth_of_field(RenderButtonsPanel, Panel):
|
2022-08-04 12:33:43 +02:00
|
|
|
bl_label = "Depth of Field"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2022-08-04 12:33:43 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2022-08-04 12:33:43 +02:00
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "bokeh_max_size")
|
|
|
|
|
col.prop(props, "bokeh_threshold")
|
|
|
|
|
col.prop(props, "bokeh_neighbor_max")
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
col = layout.column(align=False, heading="Jitter Camera")
|
|
|
|
|
row = col.row(align=True)
|
|
|
|
|
sub = row.row(align=True)
|
|
|
|
|
sub.prop(props, "use_bokeh_jittered", text="")
|
|
|
|
|
sub = sub.row(align=True)
|
|
|
|
|
sub.active = props.use_bokeh_jittered
|
|
|
|
|
sub.prop(props, "bokeh_overblur")
|
2022-08-04 12:33:43 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_volumes(RenderButtonsPanel, Panel):
|
2023-10-11 20:27:30 +02:00
|
|
|
bl_label = "Volumes"
|
2023-08-04 16:47:16 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-08-04 16:47:16 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2023-08-04 16:47:16 +02:00
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
|
|
|
|
col = layout.column(align=True)
|
2024-04-19 12:12:28 +02:00
|
|
|
col.prop(props, "volumetric_tile_size", text="Resolution")
|
|
|
|
|
col.prop(props, "volumetric_samples", text="Steps")
|
|
|
|
|
col.prop(props, "volumetric_sample_distribution", text="Distribution")
|
2023-08-04 16:47:16 +02:00
|
|
|
|
|
|
|
|
col = layout.column()
|
2023-10-19 19:22:14 +02:00
|
|
|
col.prop(props, "volumetric_ray_depth", text="Max Depth")
|
2023-08-04 16:47:16 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_volumes_range(RenderButtonsPanel, Panel):
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_label = "Custom Range"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_volumes"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-09-06 14:35:57 +02:00
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
2023-09-06 14:35:57 +02:00
|
|
|
|
2024-04-19 13:51:27 +02:00
|
|
|
def draw_header(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
self.layout.prop(props, "use_volume_custom_range", text="")
|
|
|
|
|
|
2023-09-06 14:35:57 +02:00
|
|
|
def draw(self, context):
|
2024-04-19 13:51:27 +02:00
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2023-09-06 14:35:57 +02:00
|
|
|
layout = self.layout
|
2024-04-19 13:51:27 +02:00
|
|
|
layout.active = props.use_volume_custom_range
|
2023-09-06 14:35:57 +02:00
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2023-09-06 14:35:57 +02:00
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
col = layout.column(align=True)
|
|
|
|
|
col.prop(props, "volumetric_start")
|
|
|
|
|
col.prop(props, "volumetric_end")
|
2023-09-06 14:35:57 +02:00
|
|
|
|
2023-08-04 16:47:16 +02:00
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_raytracing_presets(PresetPanel, Panel):
|
2023-12-24 22:17:31 +01:00
|
|
|
bl_label = "Raytracing Presets"
|
|
|
|
|
preset_subdir = "eevee/raytracing"
|
|
|
|
|
preset_operator = "script.execute_preset"
|
|
|
|
|
preset_add_operator = "render.eevee_raytracing_preset_add"
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_raytracing(RenderButtonsPanel, Panel):
|
2023-08-03 15:32:06 +02:00
|
|
|
bl_label = "Raytracing"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
2023-12-29 08:34:19 +01:00
|
|
|
def draw_header(self, context):
|
|
|
|
|
props = context.scene.eevee
|
|
|
|
|
self.layout.prop(props, "use_raytracing", text="")
|
|
|
|
|
|
2023-12-24 22:17:31 +01:00
|
|
|
def draw_header_preset(self, _context):
|
2025-06-13 12:36:14 +02:00
|
|
|
RENDER_PT_eevee_raytracing_presets.draw_panel_header(self.layout)
|
2023-12-24 22:17:31 +01:00
|
|
|
|
2023-08-03 15:32:06 +02:00
|
|
|
def draw(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
layout.active = props.use_raytracing
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "ray_tracing_method", text="Method")
|
2023-08-03 15:32:06 +02:00
|
|
|
|
2023-12-10 21:38:23 +01:00
|
|
|
options = context.scene.eevee.ray_tracing_options
|
2023-08-03 15:32:06 +02:00
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
col.prop(options, "resolution_scale")
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_screen_trace(RenderButtonsPanel, Panel):
|
2023-08-03 15:32:06 +02:00
|
|
|
bl_label = "Screen Tracing"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_raytracing"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
use_screen_trace = (context.scene.eevee.ray_tracing_method == 'SCREEN')
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES) and use_screen_trace
|
|
|
|
|
|
2023-12-10 21:38:23 +01:00
|
|
|
def draw(self, context):
|
2024-04-19 12:12:28 +02:00
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2023-08-03 15:32:06 +02:00
|
|
|
layout = self.layout
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.active = props.use_raytracing
|
2023-08-03 15:32:06 +02:00
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
2023-12-10 21:38:23 +01:00
|
|
|
props = context.scene.eevee.ray_tracing_options
|
2023-08-03 15:32:06 +02:00
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "screen_trace_quality", text="Precision")
|
|
|
|
|
col.prop(props, "screen_trace_thickness", text="Thickness")
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_gi_approximation(RenderButtonsPanel, Panel):
|
2024-05-26 19:29:15 +02:00
|
|
|
bl_label = "Fast GI Approximation"
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_raytracing"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
2024-08-06 14:28:56 +02:00
|
|
|
def draw_header(self, context):
|
|
|
|
|
self.layout.active = context.scene.eevee.use_raytracing
|
|
|
|
|
props = context.scene.eevee
|
|
|
|
|
self.layout.prop(props, "use_fast_gi", text="")
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
def draw(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
2024-08-06 14:28:56 +02:00
|
|
|
options = scene.eevee.ray_tracing_options
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
2024-08-06 14:28:56 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
col.active = props.use_raytracing and props.use_fast_gi
|
|
|
|
|
col.prop(options, "trace_max_roughness", text="Threshold")
|
|
|
|
|
|
|
|
|
|
is_valid = props.use_raytracing and props.use_fast_gi and props.ray_tracing_options.trace_max_roughness < 1
|
2024-05-27 16:33:49 +02:00
|
|
|
|
2024-08-06 14:28:56 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
col.active = is_valid
|
|
|
|
|
col.prop(props, "fast_gi_method")
|
|
|
|
|
col.prop(props, "fast_gi_resolution", text="Resolution")
|
2024-05-28 16:00:38 +02:00
|
|
|
|
2024-08-06 14:28:56 +02:00
|
|
|
sub = col.column(align=True)
|
|
|
|
|
sub.prop(props, "fast_gi_ray_count", text="Rays")
|
|
|
|
|
sub.prop(props, "fast_gi_step_count", text="Steps")
|
|
|
|
|
sub.prop(props, "fast_gi_quality", text="Precision")
|
|
|
|
|
|
|
|
|
|
sub = col.column(align=True)
|
|
|
|
|
sub.prop(props, "fast_gi_distance")
|
|
|
|
|
sub.prop(props, "fast_gi_thickness_near", text="Thickness Near")
|
|
|
|
|
sub.prop(props, "fast_gi_thickness_far", text="Far")
|
2024-05-26 20:23:42 +02:00
|
|
|
|
2024-08-06 14:28:56 +02:00
|
|
|
col.prop(props, "fast_gi_bias", text="Bias")
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_denoise(RenderButtonsPanel, Panel):
|
2023-08-03 15:32:06 +02:00
|
|
|
bl_label = "Denoising"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_raytracing"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
2023-12-10 21:38:23 +01:00
|
|
|
def draw_header(self, context):
|
2024-04-19 12:12:28 +02:00
|
|
|
self.layout.active = context.scene.eevee.use_raytracing
|
2023-12-10 21:38:23 +01:00
|
|
|
props = context.scene.eevee.ray_tracing_options
|
2023-08-03 15:32:06 +02:00
|
|
|
self.layout.prop(props, "use_denoise", text="")
|
|
|
|
|
|
2023-12-10 21:38:23 +01:00
|
|
|
def draw(self, context):
|
2024-04-19 12:12:28 +02:00
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2023-08-03 15:32:06 +02:00
|
|
|
layout = self.layout
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.active = props.use_raytracing
|
2023-08-03 15:32:06 +02:00
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2023-12-10 21:38:23 +01:00
|
|
|
props = context.scene.eevee.ray_tracing_options
|
2023-08-03 15:32:06 +02:00
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.active = props.use_denoise
|
|
|
|
|
col.prop(props, "denoise_spatial")
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
2023-10-11 20:27:30 +02:00
|
|
|
col.active = props.use_denoise and props.denoise_spatial
|
2023-08-03 15:32:06 +02:00
|
|
|
col.prop(props, "denoise_temporal")
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
2023-10-11 20:27:30 +02:00
|
|
|
col.active = props.use_denoise and props.denoise_spatial and props.denoise_temporal
|
2023-08-03 15:32:06 +02:00
|
|
|
col.prop(props, "denoise_bilateral")
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_clamping(RenderButtonsPanel, Panel):
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_label = "Clamping"
|
2023-10-11 20:27:30 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-10-11 20:27:30 +02:00
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
2024-05-14 16:36:12 +02:00
|
|
|
pass
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_clamping_surface(RenderButtonsPanel, Panel):
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_label = "Surface"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_clamping"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2024-04-19 12:12:28 +02:00
|
|
|
|
2023-10-11 20:27:30 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2023-10-11 20:27:30 +02:00
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2024-04-22 21:19:00 +02:00
|
|
|
col = layout.column(align=True)
|
|
|
|
|
col.prop(props, "clamp_surface_direct", text="Direct Light")
|
|
|
|
|
col.prop(props, "clamp_surface_indirect", text="Indirect Light")
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_clamping_volume(RenderButtonsPanel, Panel):
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_label = "Volume"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_clamping"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
2024-04-22 21:19:00 +02:00
|
|
|
|
|
|
|
|
col = layout.column(align=True)
|
|
|
|
|
col.prop(props, "clamp_volume_direct", text="Direct Light")
|
|
|
|
|
col.prop(props, "clamp_volume_indirect", text="Indirect Light")
|
2023-10-11 20:27:30 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_sampling_shadows(RenderButtonsPanel, Panel):
|
2023-02-08 21:08:54 +01:00
|
|
|
bl_label = "Shadows"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_sampling"
|
2023-02-08 21:08:54 +01:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-02-08 21:08:54 +01:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
2023-02-09 00:48:33 +01:00
|
|
|
def draw_header(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
self.layout.prop(props, "use_shadows", text="")
|
|
|
|
|
|
2023-02-08 21:08:54 +01:00
|
|
|
def draw(self, context):
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
layout = self.layout
|
|
|
|
|
layout.active = props.use_shadows
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
2023-10-11 20:27:30 +02:00
|
|
|
|
|
|
|
|
col = layout.column(heading="Tracing", align=True)
|
|
|
|
|
col.prop(props, "shadow_ray_count", text="Rays")
|
|
|
|
|
col.prop(props, "shadow_step_count", text="Steps")
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
col = layout.column(align=False, heading="Volume Shadows")
|
|
|
|
|
row = col.row(align=True)
|
|
|
|
|
sub = row.row(align=True)
|
|
|
|
|
sub.prop(props, "use_volumetric_shadows", text="")
|
|
|
|
|
sub = sub.row(align=True)
|
|
|
|
|
sub.active = props.use_volumetric_shadows
|
|
|
|
|
sub.prop(props, "volumetric_shadow_samples", text="Steps")
|
2024-03-20 15:55:58 +01:00
|
|
|
|
2024-05-26 18:56:03 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "shadow_resolution_scale", text="Resolution")
|
|
|
|
|
|
2023-02-08 21:08:54 +01:00
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_sampling(RenderButtonsPanel, Panel):
|
2022-06-28 18:33:25 +02:00
|
|
|
bl_label = "Sampling"
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2023-10-11 20:27:30 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_sampling_viewport(RenderButtonsPanel, Panel):
|
2023-10-11 20:27:30 +02:00
|
|
|
bl_label = "Viewport"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_sampling"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-10-11 20:27:30 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2023-10-11 20:27:30 +02:00
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "taa_samples", text="Samples")
|
|
|
|
|
col.prop(props, "use_taa_reprojection", text="Temporal Reprojection")
|
2024-05-18 17:21:47 +02:00
|
|
|
col.prop(props, "use_shadow_jitter_viewport", text="Jittered Shadows")
|
2023-10-11 20:27:30 +02:00
|
|
|
|
2023-10-14 13:49:50 +11:00
|
|
|
# Add SSS sample count here.
|
2023-10-11 20:27:30 +02:00
|
|
|
|
|
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_sampling_render(RenderButtonsPanel, Panel):
|
2023-10-11 20:27:30 +02:00
|
|
|
bl_label = "Render"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_sampling"
|
|
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2023-10-11 20:27:30 +02:00
|
|
|
|
2022-06-28 18:33:25 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2022-06-28 18:33:25 +02:00
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
|
|
|
|
col = layout.column(align=True)
|
2023-10-11 20:27:30 +02:00
|
|
|
col.prop(props, "taa_render_samples", text="Samples")
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2023-10-14 13:49:50 +11:00
|
|
|
# Add SSS sample count here.
|
2022-07-21 16:05:51 +02:00
|
|
|
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_sampling_advanced(RenderButtonsPanel, Panel):
|
2024-04-19 12:12:28 +02:00
|
|
|
bl_label = "Advanced"
|
2025-06-13 12:36:14 +02:00
|
|
|
bl_parent_id = "RENDER_PT_eevee_sampling"
|
2017-10-03 18:30:36 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2017-10-01 02:19:10 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
2018-04-17 13:35:05 +02:00
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
2017-10-01 02:19:10 +02:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
2018-05-30 17:47:48 +02:00
|
|
|
layout.use_property_split = True
|
2024-04-19 12:12:28 +02:00
|
|
|
layout.use_property_decorate = False
|
2018-05-30 17:47:48 +02:00
|
|
|
|
2017-10-01 02:19:10 +02:00
|
|
|
scene = context.scene
|
2018-05-16 19:34:24 +02:00
|
|
|
props = scene.eevee
|
2017-10-01 02:19:10 +02:00
|
|
|
|
|
|
|
|
col = layout.column()
|
2024-04-19 12:12:28 +02:00
|
|
|
col.prop(props, "light_threshold")
|
2018-11-15 18:13:07 +01:00
|
|
|
|
2017-10-01 02:19:10 +02:00
|
|
|
|
2025-06-13 12:36:14 +02:00
|
|
|
class RENDER_PT_eevee_film(RenderButtonsPanel, Panel):
|
2022-06-28 18:33:25 +02:00
|
|
|
bl_label = "Film"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2022-06-28 18:33:25 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
2023-08-03 16:19:08 +02:00
|
|
|
props = scene.eevee
|
2022-06-28 18:33:25 +02:00
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(rd, "filter_size")
|
2022-07-24 15:33:28 +02:00
|
|
|
col.prop(rd, "film_transparent", text="Transparent")
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2023-08-03 16:19:08 +02:00
|
|
|
col = layout.column(align=False, heading="Overscan")
|
|
|
|
|
row = col.row(align=True)
|
|
|
|
|
sub = row.row(align=True)
|
|
|
|
|
sub.prop(props, "use_overscan", text="")
|
|
|
|
|
sub = sub.row(align=True)
|
|
|
|
|
sub.active = props.use_overscan
|
|
|
|
|
sub.prop(props, "overscan_size", text="")
|
|
|
|
|
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2022-04-06 16:19:44 -05:00
|
|
|
def draw_curves_settings(self, context):
|
2022-03-09 17:00:22 +01:00
|
|
|
layout = self.layout
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
layout.prop(rd, "hair_type", text="Shape", expand=True)
|
|
|
|
|
layout.prop(rd, "hair_subdiv")
|
|
|
|
|
|
|
|
|
|
|
2018-07-11 11:43:56 +02:00
|
|
|
class RENDER_PT_eevee_hair(RenderButtonsPanel, Panel):
|
2022-04-06 16:19:44 -05:00
|
|
|
bl_label = "Curves"
|
2018-05-29 11:20:37 +02:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-08-27 09:49:43 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE', 'BLENDER_WORKBENCH'}
|
2018-05-29 11:20:37 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
2022-04-06 16:19:44 -05:00
|
|
|
draw_curves_settings(self, context)
|
2018-05-29 11:20:37 +02:00
|
|
|
|
|
|
|
|
|
2020-02-19 01:44:52 +01:00
|
|
|
class RENDER_PT_eevee_performance(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Performance"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2024-10-30 13:20:01 +11:00
|
|
|
COMPAT_ENGINES = {
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2024-10-30 13:20:01 +11:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2020-02-19 01:44:52 +01:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
2022-03-09 17:00:22 +01:00
|
|
|
layout.use_property_decorate = False # No animation.
|
2020-02-19 01:44:52 +01:00
|
|
|
|
|
|
|
|
layout.prop(rd, "use_high_quality_normals")
|
|
|
|
|
|
|
|
|
|
|
2024-05-14 15:49:20 +02:00
|
|
|
class CompositorPerformanceButtonsPanel:
|
|
|
|
|
bl_label = "Compositor"
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
row = col.row()
|
|
|
|
|
row.prop(rd, "compositor_device", text="Device", expand=True)
|
2025-01-21 23:50:17 +11:00
|
|
|
if rd.compositor_device == 'GPU':
|
2025-01-08 07:41:48 +01:00
|
|
|
col.prop(rd, "compositor_precision", text="Precision")
|
2024-05-14 15:49:20 +02:00
|
|
|
|
|
|
|
|
|
2024-12-28 01:44:49 +01:00
|
|
|
class CompositorDenoisePerformanceButtonsPanel:
|
|
|
|
|
bl_label = "Denoise Nodes"
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
Compositor: Support GPU OIDN denoising
This patch supports GPU OIDN denoising in the compositor. A new
compositor performance option was added to allow choosing between CPU,
GPU, and Auto device selection. Auto will use whatever the compositor is
using for execution.
The code is two folds, first, denoising code was adapted to use buffers
as opposed to passing in pointers to filters directly, this is needed to
support GPU devices. Second, device creation is now a bit more involved,
it tries to choose the device is being used by the compositor for
execution.
Matching GPU devices is done by choosing the OIDN device that matches
the UUID or LUID of the active GPU platform. We need both UUID and LUID
because not all platforms support both. UUID is supported on all
platforms except MacOS Metal, while LUID is only supported on Window and
MacOS metal.
If there is no active GPU device or matching is unsuccessful, we let
OIDN choose the best device, which is typically the fastest.
To support this case, UUID and LUID identifiers were added to the
GPUPlatformGlobal and are initialized by the GPU backend if supported.
OpenGL now requires GL_EXT_memory_object and GL_EXT_memory_object_win32
to support this use case, but it should function without it.
Pull Request: https://projects.blender.org/blender/blender/pulls/136660
2025-04-04 11:17:08 +02:00
|
|
|
row = col.row()
|
|
|
|
|
row.prop(rd, "compositor_denoise_device", text="Denoising Device", expand=True)
|
2024-12-28 01:44:49 +01:00
|
|
|
col.prop(rd, "compositor_denoise_preview_quality", text="Preview Quality")
|
|
|
|
|
col.prop(rd, "compositor_denoise_final_quality", text="Final Quality")
|
|
|
|
|
|
|
|
|
|
|
2024-05-14 15:49:20 +02:00
|
|
|
class RENDER_PT_eevee_performance_compositor(RenderButtonsPanel, CompositorPerformanceButtonsPanel, Panel):
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
bl_parent_id = "RENDER_PT_eevee_performance"
|
2024-10-30 13:20:01 +11:00
|
|
|
COMPAT_ENGINES = {
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2024-10-30 13:20:01 +11:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2024-05-14 15:49:20 +02:00
|
|
|
|
|
|
|
|
|
2024-12-28 01:44:49 +01:00
|
|
|
class RENDER_PT_eevee_performance_compositor_denoise_settings(
|
2025-01-14 12:46:40 +11:00
|
|
|
RenderButtonsPanel, CompositorDenoisePerformanceButtonsPanel, Panel,
|
|
|
|
|
):
|
2024-12-28 01:44:49 +01:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
bl_parent_id = "RENDER_PT_eevee_performance_compositor"
|
|
|
|
|
COMPAT_ENGINES = {
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2024-12-28 01:44:49 +01:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2024-04-19 12:12:28 +02:00
|
|
|
class RENDER_PT_eevee_performance_memory(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Memory"
|
|
|
|
|
bl_parent_id = "RENDER_PT_eevee_performance"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2024-04-19 12:12:28 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.eevee
|
|
|
|
|
|
|
|
|
|
layout.prop(props, "shadow_pool_size", text="Shadow Pool")
|
|
|
|
|
layout.prop(props, "gi_irradiance_pool_size", text="Light Probes Volume Pool")
|
|
|
|
|
|
|
|
|
|
|
2024-03-13 12:00:24 +01:00
|
|
|
class RENDER_PT_eevee_performance_viewport(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Viewport"
|
|
|
|
|
bl_parent_id = "RENDER_PT_eevee_performance"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2025-06-13 12:36:14 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_EEVEE'}
|
2024-03-13 12:00:24 +01:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
rd = scene.render
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(rd, "preview_pixel_size", text="Pixel Size")
|
|
|
|
|
|
|
|
|
|
|
2025-04-03 16:52:05 +02:00
|
|
|
# TODO(falk): To rename for 5.0
|
2020-05-12 17:47:48 +02:00
|
|
|
class RENDER_PT_gpencil(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Grease Pencil"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2020-06-04 14:44:00 +02:00
|
|
|
bl_order = 10
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2020-05-12 17:47:48 +02:00
|
|
|
|
2025-04-03 16:52:05 +02:00
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_grease_pencil_viewport(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Viewport"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
bl_parent_id = "RENDER_PT_gpencil"
|
|
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2025-04-03 16:52:05 +02:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.grease_pencil_settings
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "antialias_threshold", text="SMAA Threshold")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_grease_pencil_render(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Render"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
bl_parent_id = "RENDER_PT_gpencil"
|
|
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2025-04-03 16:52:05 +02:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
|
|
|
|
|
2020-05-12 17:47:48 +02:00
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.grease_pencil_settings
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
2025-04-03 16:52:05 +02:00
|
|
|
col.prop(props, "antialias_threshold_render", text="SMAA Threshold")
|
|
|
|
|
col.prop(props, "aa_samples", text="SSAA Samples")
|
2020-05-12 17:47:48 +02:00
|
|
|
|
2025-06-09 15:44:53 +02:00
|
|
|
col = layout.column()
|
|
|
|
|
col.active = scene.render.use_motion_blur
|
|
|
|
|
col.prop(props, "motion_blur_steps")
|
|
|
|
|
|
2020-05-12 17:47:48 +02:00
|
|
|
|
2019-05-02 15:18:53 +02:00
|
|
|
class RENDER_PT_opengl_sampling(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Sampling"
|
2023-09-04 17:42:04 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_WORKBENCH'}
|
2019-05-02 15:18:53 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
scene = context.scene
|
|
|
|
|
props = scene.display
|
|
|
|
|
|
|
|
|
|
col = layout.column()
|
|
|
|
|
col.prop(props, "render_aa", text="Render")
|
2020-03-09 19:52:42 +01:00
|
|
|
col.prop(props, "viewport_aa", text="Viewport")
|
2019-05-02 15:18:53 +02:00
|
|
|
|
|
|
|
|
|
2018-07-11 11:43:56 +02:00
|
|
|
class RENDER_PT_opengl_film(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Film"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2023-09-04 17:42:04 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_WORKBENCH'}
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
layout.use_property_decorate = False # No animation.
|
|
|
|
|
|
|
|
|
|
rd = context.scene.render
|
2019-05-16 17:03:16 +02:00
|
|
|
layout.prop(rd, "film_transparent", text="Transparent")
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_opengl_lighting(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Lighting"
|
2023-09-04 17:42:04 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_WORKBENCH'}
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
VIEW3D_PT_shading_lighting.draw(self, context)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_opengl_color(RenderButtonsPanel, Panel):
|
2025-05-14 16:24:51 +02:00
|
|
|
bl_label = "Object Color"
|
2023-09-04 17:42:04 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_WORKBENCH'}
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
2018-08-19 20:25:36 +02:00
|
|
|
VIEW3D_PT_shading_color._draw_color_type(self, context)
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_opengl_options(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Options"
|
2023-09-04 17:42:04 +02:00
|
|
|
COMPAT_ENGINES = {'BLENDER_WORKBENCH'}
|
2018-07-11 11:43:56 +02:00
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES)
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
VIEW3D_PT_shading_options.draw(self, context)
|
|
|
|
|
|
2025-03-05 11:45:00 +01:00
|
|
|
# Cavity properties.
|
|
|
|
|
VIEW3D_PT_shading_cavity.draw_header(self, context)
|
|
|
|
|
VIEW3D_PT_shading_cavity.draw(self, context)
|
|
|
|
|
|
2018-07-11 11:43:56 +02:00
|
|
|
|
2018-11-03 05:12:45 +01:00
|
|
|
class RENDER_PT_simplify(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Simplify"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2018-11-03 05:12:45 +01:00
|
|
|
|
|
|
|
|
def draw_header(self, context):
|
|
|
|
|
rd = context.scene.render
|
|
|
|
|
self.layout.prop(rd, "use_simplify", text="")
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RENDER_PT_simplify_viewport(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Viewport"
|
|
|
|
|
bl_parent_id = "RENDER_PT_simplify"
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2018-11-03 05:12:45 +01:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
|
|
rd = context.scene.render
|
|
|
|
|
|
|
|
|
|
layout.active = rd.use_simplify
|
|
|
|
|
|
|
|
|
|
flow = layout.grid_flow(row_major=True, columns=0, even_columns=False, even_rows=False, align=True)
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "simplify_subdivision", text="Max Subdivision")
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "simplify_child_particles", text="Max Child Particles")
|
|
|
|
|
|
2020-10-01 17:58:43 +02:00
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "simplify_volumes", text="Volume Resolution")
|
|
|
|
|
|
2023-12-16 00:18:41 +01:00
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "use_simplify_normals", text="Normals")
|
|
|
|
|
|
2018-11-03 05:12:45 +01:00
|
|
|
|
|
|
|
|
class RENDER_PT_simplify_render(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Render"
|
|
|
|
|
bl_parent_id = "RENDER_PT_simplify"
|
2023-01-24 17:58:58 +01:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-29 14:32:54 +10:00
|
|
|
'BLENDER_WORKBENCH',
|
|
|
|
|
}
|
2018-11-03 05:12:45 +01:00
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
|
|
rd = context.scene.render
|
|
|
|
|
|
|
|
|
|
layout.active = rd.use_simplify
|
|
|
|
|
|
|
|
|
|
flow = layout.grid_flow(row_major=True, columns=0, even_columns=False, even_rows=False, align=True)
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "simplify_subdivision_render", text="Max Subdivision")
|
|
|
|
|
|
|
|
|
|
col = flow.column()
|
|
|
|
|
col.prop(rd, "simplify_child_particles_render", text="Max Child Particles")
|
|
|
|
|
|
|
|
|
|
|
2019-09-12 16:12:19 +02:00
|
|
|
class RENDER_PT_simplify_greasepencil(RenderButtonsPanel, Panel, GreasePencilSimplifyPanel):
|
2018-11-03 05:12:45 +01:00
|
|
|
bl_label = "Grease Pencil"
|
|
|
|
|
bl_parent_id = "RENDER_PT_simplify"
|
2022-07-26 13:23:45 +10:00
|
|
|
COMPAT_ENGINES = {
|
|
|
|
|
'BLENDER_RENDER',
|
2025-06-13 12:36:14 +02:00
|
|
|
'BLENDER_EEVEE',
|
2023-09-04 17:42:04 +02:00
|
|
|
'BLENDER_WORKBENCH',
|
2022-07-26 13:23:45 +10:00
|
|
|
}
|
2018-11-03 05:12:45 +01:00
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
|
|
|
|
|
|
2023-08-04 15:06:12 +02:00
|
|
|
class RENDER_PT_hydra_debug(RenderButtonsPanel, Panel):
|
|
|
|
|
bl_label = "Hydra Debug"
|
|
|
|
|
bl_options = {'DEFAULT_CLOSED'}
|
|
|
|
|
bl_order = 200
|
|
|
|
|
COMPAT_ENGINES = {'HYDRA_STORM'}
|
|
|
|
|
|
|
|
|
|
@classmethod
|
|
|
|
|
def poll(cls, context):
|
|
|
|
|
prefs = context.preferences
|
|
|
|
|
return (context.engine in cls.COMPAT_ENGINES) and prefs.view.show_developer_ui
|
|
|
|
|
|
|
|
|
|
def draw(self, context):
|
|
|
|
|
layout = self.layout
|
|
|
|
|
layout.use_property_split = True
|
|
|
|
|
|
|
|
|
|
hydra = context.scene.hydra
|
|
|
|
|
layout.prop(hydra, "export_method")
|
|
|
|
|
|
|
|
|
|
|
2017-03-18 20:03:24 +11:00
|
|
|
classes = (
|
2017-10-16 17:15:03 -02:00
|
|
|
RENDER_PT_context,
|
2025-06-13 12:36:14 +02:00
|
|
|
RENDER_PT_eevee_sampling,
|
|
|
|
|
RENDER_PT_eevee_sampling_viewport,
|
|
|
|
|
RENDER_PT_eevee_sampling_render,
|
|
|
|
|
RENDER_PT_eevee_sampling_shadows,
|
|
|
|
|
RENDER_PT_eevee_sampling_advanced,
|
|
|
|
|
RENDER_PT_eevee_clamping,
|
|
|
|
|
RENDER_PT_eevee_clamping_surface,
|
|
|
|
|
RENDER_PT_eevee_clamping_volume,
|
|
|
|
|
RENDER_PT_eevee_raytracing_presets,
|
|
|
|
|
RENDER_PT_eevee_raytracing,
|
|
|
|
|
RENDER_PT_eevee_screen_trace,
|
|
|
|
|
RENDER_PT_eevee_denoise,
|
|
|
|
|
RENDER_PT_eevee_gi_approximation,
|
|
|
|
|
RENDER_PT_eevee_volumes,
|
|
|
|
|
RENDER_PT_eevee_volumes_range,
|
2018-11-02 02:21:35 +01:00
|
|
|
RENDER_PT_eevee_hair,
|
2024-05-26 19:33:31 +02:00
|
|
|
RENDER_PT_simplify,
|
|
|
|
|
RENDER_PT_simplify_viewport,
|
|
|
|
|
RENDER_PT_simplify_render,
|
|
|
|
|
RENDER_PT_simplify_greasepencil,
|
2025-06-13 12:36:14 +02:00
|
|
|
RENDER_PT_eevee_depth_of_field,
|
|
|
|
|
RENDER_PT_eevee_motion_blur,
|
|
|
|
|
RENDER_PT_eevee_motion_blur_curve,
|
|
|
|
|
RENDER_PT_eevee_film,
|
2024-04-19 12:12:28 +02:00
|
|
|
RENDER_PT_eevee_performance,
|
|
|
|
|
RENDER_PT_eevee_performance_memory,
|
|
|
|
|
RENDER_PT_eevee_performance_viewport,
|
2024-05-14 15:49:20 +02:00
|
|
|
RENDER_PT_eevee_performance_compositor,
|
2024-12-28 01:44:49 +01:00
|
|
|
RENDER_PT_eevee_performance_compositor_denoise_settings,
|
2022-06-28 18:33:25 +02:00
|
|
|
|
2022-07-29 18:01:59 +02:00
|
|
|
|
2020-05-12 17:47:48 +02:00
|
|
|
RENDER_PT_gpencil,
|
2025-04-03 16:52:05 +02:00
|
|
|
RENDER_PT_grease_pencil_viewport,
|
|
|
|
|
RENDER_PT_grease_pencil_render,
|
2019-05-02 15:18:53 +02:00
|
|
|
RENDER_PT_opengl_sampling,
|
2018-07-11 11:43:56 +02:00
|
|
|
RENDER_PT_opengl_lighting,
|
|
|
|
|
RENDER_PT_opengl_color,
|
|
|
|
|
RENDER_PT_opengl_options,
|
2018-11-02 02:21:35 +01:00
|
|
|
RENDER_PT_opengl_film,
|
2023-08-04 15:06:12 +02:00
|
|
|
RENDER_PT_hydra_debug,
|
2018-11-02 02:21:35 +01:00
|
|
|
RENDER_PT_color_management,
|
|
|
|
|
RENDER_PT_color_management_curves,
|
Color management: Support white balance as part of the display transform
This implements a von-Kries-style chromatic adaption using the Bradford matrix.
The adaption is performed in scene linear space in the OCIO GLSL shader, with
the matrix being computed on the host.
The parameters specify the white point of the input, which is to be mapped to
the white point of the scene linear space. The main parameter is temperature,
specified in Kelvin, which defines the blackbody spectrum that is used as the
input white point. Additionally, a tint parameter can be used to shift the
white point away from pure blackbody spectra (e.g. to match a D illuminant).
The defaults are set to match D65 so there is no immediate color shift when
enabling the option. Tint = 10 is needed since the D-series illuminants aren't
perfect blackbody emitters.
As an alternative to manually specifying the values, there's also a color
picker. When a color is selected, temperature and tint are set such that this
color ends up being balanced to white.
This only works if the color is close enough to a blackbody emitter -
specifically, for tint values within +-150. Beyond this, there can be ambiguity
in the representation.
Currently, in this case, the input is just ignored and temperature/tint aren't
changed. Ideally, we'd eventually give UI feedback for this.
Presets are supported, and all the CIE standard illuminants are included.
One part that I'm not quite happy with is that the tint parameter starts to
give weird results at moderate values when the temperature is low.
The reason for this can be seen here:
https://commons.wikimedia.org/wiki/File:Planckian-locus.png
Tint is moving along the isotherm lines (with the plot corresponding to +-150),
but below 4000K some of that range is outside of the gamut. Not much can
be done there, other than possibly clipping those values...
Adding support for this to the compositor should be quite easy and is planned
as a next step.
Pull Request: https://projects.blender.org/blender/blender/pulls/123278
2024-06-27 23:27:58 +02:00
|
|
|
RENDER_PT_color_management_white_balance_presets,
|
|
|
|
|
RENDER_PT_color_management_white_balance,
|
2025-09-26 17:05:18 +02:00
|
|
|
RENDER_PT_color_management_working_space,
|
|
|
|
|
RENDER_PT_color_management_advanced,
|
2017-03-18 20:03:24 +11:00
|
|
|
)
|
|
|
|
|
|
2011-04-04 10:13:04 +00:00
|
|
|
if __name__ == "__main__": # only for live edit.
|
2017-03-18 20:03:24 +11:00
|
|
|
from bpy.utils import register_class
|
|
|
|
|
for cls in classes:
|
|
|
|
|
register_class(cls)
|