Remove OSL scripts to improve render (#56)
* Remove OSL scripts to improve render * Remove slice viewer * Locator will be added next to selected node * Improve specular in eevee
This commit is contained in:
Binary file not shown.
@@ -419,7 +419,7 @@ node_menu = NodeMenu(
|
|||||||
|
|
||||||
def add():
|
def add():
|
||||||
node_menu.register()
|
node_menu.register()
|
||||||
bpy.types.VIEW3D_HT_header.append(VIEW3D_TOPBAR)
|
# bpy.types.VIEW3D_HT_header.append(VIEW3D_TOPBAR)
|
||||||
bpy.types.TOPBAR_MT_editor_menus.append(TOPBAR)
|
bpy.types.TOPBAR_MT_editor_menus.append(TOPBAR)
|
||||||
bpy.types.NODE_PT_node_tree_properties.prepend(NODE_PROP)
|
bpy.types.NODE_PT_node_tree_properties.prepend(NODE_PROP)
|
||||||
bpy.types.NODE_MT_editor_menus.append(NODE_HEAD)
|
bpy.types.NODE_MT_editor_menus.append(NODE_HEAD)
|
||||||
@@ -427,7 +427,7 @@ def add():
|
|||||||
|
|
||||||
|
|
||||||
def remove():
|
def remove():
|
||||||
bpy.types.VIEW3D_HT_header.remove(VIEW3D_TOPBAR)
|
# bpy.types.VIEW3D_HT_header.remove(VIEW3D_TOPBAR)
|
||||||
bpy.types.TOPBAR_MT_editor_menus.remove(TOPBAR)
|
bpy.types.TOPBAR_MT_editor_menus.remove(TOPBAR)
|
||||||
bpy.types.NODE_PT_node_tree_properties.remove(NODE_PROP)
|
bpy.types.NODE_PT_node_tree_properties.remove(NODE_PROP)
|
||||||
bpy.types.NODE_MT_editor_menus.remove(NODE_HEAD)
|
bpy.types.NODE_MT_editor_menus.remove(NODE_HEAD)
|
||||||
|
|||||||
@@ -510,6 +510,10 @@ class AddLocator(bpy.types.Operator):
|
|||||||
|
|
||||||
modifier = container_obj.modifiers[0]
|
modifier = container_obj.modifiers[0]
|
||||||
node_group = modifier.node_group
|
node_group = modifier.node_group
|
||||||
|
try:
|
||||||
|
selected_node = context.selected_nodes[0]
|
||||||
|
except:
|
||||||
|
selected_node = None
|
||||||
|
|
||||||
parent_node = add_node_to_graph("TransformParent",
|
parent_node = add_node_to_graph("TransformParent",
|
||||||
node_group,
|
node_group,
|
||||||
@@ -518,8 +522,8 @@ class AddLocator(bpy.types.Operator):
|
|||||||
|
|
||||||
parent_node.inputs[1].default_value = locator_obj
|
parent_node.inputs[1].default_value = locator_obj
|
||||||
|
|
||||||
|
if selected_node is None or len(selected_node.outputs) == 0:
|
||||||
output_node = get_output_node(node_group)
|
output_node = get_output_node(node_group)
|
||||||
|
|
||||||
if len(output_node.inputs[0].links) == 0:
|
if len(output_node.inputs[0].links) == 0:
|
||||||
node_group.links.new(parent_node.outputs[0],
|
node_group.links.new(parent_node.outputs[0],
|
||||||
output_node.inputs[0])
|
output_node.inputs[0])
|
||||||
@@ -532,6 +536,23 @@ class AddLocator(bpy.types.Operator):
|
|||||||
output_node.inputs[0])
|
output_node.inputs[0])
|
||||||
move_node_between_nodes(parent_node,
|
move_node_between_nodes(parent_node,
|
||||||
[pre_output_node, output_node])
|
[pre_output_node, output_node])
|
||||||
|
else:
|
||||||
|
try:
|
||||||
|
to_node = selected_node.outputs[0].links[0].to_node
|
||||||
|
except:
|
||||||
|
to_node = None
|
||||||
|
|
||||||
|
if to_node is None:
|
||||||
|
node_group.links.new(selected_node.outputs[0],
|
||||||
|
parent_node.inputs[0])
|
||||||
|
move_node_to_node(parent_node, selected_node, (300, 0))
|
||||||
|
else:
|
||||||
|
node_group.links.new(selected_node.outputs[0],
|
||||||
|
parent_node.inputs[0])
|
||||||
|
node_group.links.new(parent_node.outputs[0],
|
||||||
|
to_node.inputs[0])
|
||||||
|
move_node_between_nodes(parent_node,
|
||||||
|
[selected_node, to_node])
|
||||||
|
|
||||||
return {'FINISHED'}
|
return {'FINISHED'}
|
||||||
|
|
||||||
|
|||||||
@@ -857,7 +857,6 @@ class ImportVolumetricDataDialog(bpy.types.Operator):
|
|||||||
bpy.ops.bioxelnodes.render_setting_preset('EXEC_DEFAULT',
|
bpy.ops.bioxelnodes.render_setting_preset('EXEC_DEFAULT',
|
||||||
preset="balance")
|
preset="balance")
|
||||||
bpy.context.scene.render.engine = 'CYCLES'
|
bpy.context.scene.render.engine = 'CYCLES'
|
||||||
bpy.ops.bioxelnodes.slice_viewer('EXEC_DEFAULT')
|
|
||||||
|
|
||||||
self.report({"INFO"}, "Successfully Imported")
|
self.report({"INFO"}, "Successfully Imported")
|
||||||
return {'FINISHED'}
|
return {'FINISHED'}
|
||||||
|
|||||||
@@ -147,6 +147,7 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
if self.preset == "performance":
|
if self.preset == "performance":
|
||||||
# EEVEE
|
# EEVEE
|
||||||
# bpy.context.scene.eevee.use_taa_reprojection = False
|
# bpy.context.scene.eevee.use_taa_reprojection = False
|
||||||
|
bpy.context.scene.eevee.use_shadow_jitter_viewport = True
|
||||||
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
||||||
bpy.context.scene.eevee.volumetric_shadow_samples = 32
|
bpy.context.scene.eevee.volumetric_shadow_samples = 32
|
||||||
bpy.context.scene.eevee.volumetric_samples = 64
|
bpy.context.scene.eevee.volumetric_samples = 64
|
||||||
@@ -154,7 +155,6 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
bpy.context.scene.eevee.use_volumetric_shadows = True
|
bpy.context.scene.eevee.use_volumetric_shadows = True
|
||||||
|
|
||||||
# Cycles
|
# Cycles
|
||||||
bpy.context.scene.cycles.shading_system = True
|
|
||||||
bpy.context.scene.cycles.volume_bounces = 0
|
bpy.context.scene.cycles.volume_bounces = 0
|
||||||
bpy.context.scene.cycles.transparent_max_bounces = 4
|
bpy.context.scene.cycles.transparent_max_bounces = 4
|
||||||
bpy.context.scene.cycles.volume_preview_step_rate = 4
|
bpy.context.scene.cycles.volume_preview_step_rate = 4
|
||||||
@@ -163,6 +163,7 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
elif self.preset == "balance":
|
elif self.preset == "balance":
|
||||||
# EEVEE
|
# EEVEE
|
||||||
# bpy.context.scene.eevee.use_taa_reprojection = False
|
# bpy.context.scene.eevee.use_taa_reprojection = False
|
||||||
|
bpy.context.scene.eevee.use_shadow_jitter_viewport = True
|
||||||
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
||||||
bpy.context.scene.eevee.volumetric_shadow_samples = 64
|
bpy.context.scene.eevee.volumetric_shadow_samples = 64
|
||||||
bpy.context.scene.eevee.volumetric_samples = 128
|
bpy.context.scene.eevee.volumetric_samples = 128
|
||||||
@@ -170,7 +171,6 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
bpy.context.scene.eevee.use_volumetric_shadows = True
|
bpy.context.scene.eevee.use_volumetric_shadows = True
|
||||||
|
|
||||||
# Cycles
|
# Cycles
|
||||||
bpy.context.scene.cycles.shading_system = True
|
|
||||||
bpy.context.scene.cycles.volume_bounces = 4
|
bpy.context.scene.cycles.volume_bounces = 4
|
||||||
bpy.context.scene.cycles.transparent_max_bounces = 8
|
bpy.context.scene.cycles.transparent_max_bounces = 8
|
||||||
bpy.context.scene.cycles.volume_preview_step_rate = 1
|
bpy.context.scene.cycles.volume_preview_step_rate = 1
|
||||||
@@ -179,6 +179,7 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
elif self.preset == "quality":
|
elif self.preset == "quality":
|
||||||
# EEVEE
|
# EEVEE
|
||||||
# bpy.context.scene.eevee.use_taa_reprojection = False
|
# bpy.context.scene.eevee.use_taa_reprojection = False
|
||||||
|
bpy.context.scene.eevee.use_shadow_jitter_viewport = True
|
||||||
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
bpy.context.scene.eevee.volumetric_tile_size = '2'
|
||||||
bpy.context.scene.eevee.volumetric_shadow_samples = 128
|
bpy.context.scene.eevee.volumetric_shadow_samples = 128
|
||||||
bpy.context.scene.eevee.volumetric_samples = 256
|
bpy.context.scene.eevee.volumetric_samples = 256
|
||||||
@@ -186,7 +187,6 @@ class RenderSettingPreset(bpy.types.Operator):
|
|||||||
bpy.context.scene.eevee.use_volumetric_shadows = True
|
bpy.context.scene.eevee.use_volumetric_shadows = True
|
||||||
|
|
||||||
# Cycles
|
# Cycles
|
||||||
bpy.context.scene.cycles.shading_system = True
|
|
||||||
bpy.context.scene.cycles.volume_bounces = 8
|
bpy.context.scene.cycles.volume_bounces = 8
|
||||||
bpy.context.scene.cycles.transparent_max_bounces = 16
|
bpy.context.scene.cycles.transparent_max_bounces = 16
|
||||||
bpy.context.scene.cycles.volume_preview_step_rate = 0.5
|
bpy.context.scene.cycles.volume_preview_step_rate = 0.5
|
||||||
|
|||||||
Reference in New Issue
Block a user