Skip to content

Commit

Permalink
Improve visuals and settings menus, fix overly strong lights
Browse files Browse the repository at this point in the history
- Fix lights being overly strong due to an excessive range,
  which led to clustering artifacts.
- Make VoxelGI and SDFGI brighter to make the scene more readable.
- Tweak spotlight colors to better match their emitter material.
- Make the core light orange-red to make it look more "unique" in the scene.
- Add window mode, V-Sync and FPS limit options.
- Add resolution scale and scale filter options (bilinear, FSR1, FSR2).
  The default is to use FSR2 at native resolution to provide high-quality
  temporal antialiasing.
- Add volumetric fog (enabled by default), used as a volumetric lighting
  solution.
- Add SSIL option (disabled by default), which helps better ground some
  objects in the scene.
- Refactor settings code to use ConfigFile instead of manual JSON serialization.
- Reorder settings to feature video settings first, then rendering settings.
- Order settings from least expensive to most expensive.
- Add performance color hints for settings
  (green = fast, yellow = average, orange = slow, red = slowest).
- Add volumetric fog and a fake bounce light to the menu.
- Make all setting changes effective in the menu.
- Tweak shadow settings to improve performance and visual consistency.
- Render GI at full-resolution to improve temporal stability when using
  FSR2 or TAA. Using upscaling should be preferred instead,
  since this demo relies on strong GI effects to look good.
- Improve menu theming using the StyleBoxFlat Skew property.
- Use the `canvas_items` stretch mode to match 3.x demo behavior, which
  used the `2d` stretch mode but wasn't ported over by the project converter.
- Only display multiplayer ID in the debug menu if currently online.
- Fix menu not using `experiment.hdr` for reflections as intended.
- Remove unused menu button textures (these were replaced by StyleBoxFlat
  in the 4.0 port).
  • Loading branch information
Calinou committed Nov 30, 2023
1 parent 99f49b5 commit 374bd8d
Show file tree
Hide file tree
Showing 31 changed files with 74,665 additions and 815 deletions.
11 changes: 7 additions & 4 deletions level/debug.gd
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@ extends Label

func _process(_delta):
if Input.is_action_just_pressed("toggle_debug"):
visible = !visible
visible = not visible

text = "FPS: " + str(Engine.get_frames_per_second())
text += "\nVSync: " + ("checked" if ProjectSettings.get_setting("display/window/vsync/vsync_mode") else "unchecked")
text += "\nVSync: " + ("Enabled" if DisplayServer.window_get_vsync_mode() else "Disabled")
text += "\nMemory: " + "%3.2f" % (OS.get_static_memory_usage() / 1048576.0) + " MiB"
text += "\nOnline: " + ("false" if multiplayer.multiplayer_peer is OfflineMultiplayerPeer else "true")
text += "\nMultiplayer ID: " + str(multiplayer.get_unique_id())

var online := not multiplayer.multiplayer_peer is OfflineMultiplayerPeer
text += "\nOnline: " + ("Yes" if online else "No")
if online:
text += "\nMultiplayer ID: " + str(multiplayer.get_unique_id())
17 changes: 8 additions & 9 deletions level/geometry/environment.tres
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,16 @@ reflected_light_source = 1
tonemap_mode = 3
tonemap_exposure = 3.0
tonemap_white = 6.0
ssao_enabled = true
ssao_intensity = 3.0
ssao_light_affect = 0.59
ssao_ao_channel_affect = 1.0
sdfgi_use_occlusion = true
sdfgi_read_sky_light = false
sdfgi_min_cell_size = 0.146484
sdfgi_cascade0_distance = 9.375
sdfgi_max_distance = 150.0
sdfgi_bounce_feedback = 0.33
sdfgi_min_cell_size = 0.4
sdfgi_cascade0_distance = 25.6
sdfgi_max_distance = 409.6
sdfgi_y_scale = 0
sdfgi_energy = 2.2
sdfgi_energy = 8.0
glow_levels/3 = 0.0
glow_levels/4 = 1.0
glow_levels/7 = 1.0
Expand All @@ -30,8 +29,8 @@ glow_hdr_luminance_cap = 3.0
fog_enabled = true
fog_light_color = Color(0.4, 0.25098, 0.101961, 1)
fog_density = 0.002
volumetric_fog_density = 0.02
volumetric_fog_albedo = Color(0.4, 0.25098, 0.101961, 1)
volumetric_fog_emission = Color(0.145098, 0.0901961, 0.0352941, 1)
volumetric_fog_density = 0.0001
volumetric_fog_gi_inject = 0.0
volumetric_fog_temporal_reprojection_enabled = false
adjustment_enabled = true
adjustment_saturation = 1.4
Binary file modified level/geometry/giprobe_data.res
Binary file not shown.
246 changes: 148 additions & 98 deletions level/geometry/scenes/lights.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -4,126 +4,176 @@

[node name="LightsModel" instance=ExtResource("1")]

[node name="Point001_Orientation" parent="Point001" index="0"]
light_color = Color(1, 0.64, 0.09, 1)
light_energy = 1.0
shadow_enabled = true
[node name="Point_001_Orientation" parent="Point_001" index="0"]
light_color = Color(1, 0.282353, 0.12549, 1)
light_energy = 9.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
omni_range = 25.0

[node name="Spot010_Orientation" parent="Spot010" index="0"]
light_energy = 3.0
[node name="Spot_010_Orientation" parent="Spot_010" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 27.0
spot_angle = 28.8
spot_angle_attenuation = 1.0

[node name="Spot009_Orientation" parent="Spot009" index="0"]
light_energy = 3.0
spot_range = 22.0
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot008_Orientation" parent="Spot008" index="0"]
light_energy = 3.0
spot_range = 22.0
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot007_Orientation" parent="Spot007" index="0"]
light_energy = 2.0
spot_range = 10.0
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot006_Orientation" parent="Spot006" index="0"]
light_energy = 2.0
spot_range = 10.0
spot_angle = 45.0

[node name="Spot005_Orientation" parent="Spot005" index="0"]
light_color = Color(0.82, 0.89, 0.89, 1)
light_energy = 3.26
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_009_Orientation" parent="Spot_009" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 10.0
spot_angle = 45.0

[node name="Spot004_Orientation" parent="Spot004" index="0"]
light_energy = 2.0
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_008_Orientation" parent="Spot_008" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 10.0
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot003_Orientation" parent="Spot003" index="0"]
light_energy = 2.0
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_007_Orientation" parent="Spot_007" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 10.0
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot002_Orientation" parent="Spot002" index="0"]
light_energy = 2.0
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_006_Orientation" parent="Spot_006" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 12.1
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot001_Orientation" parent="Spot001" index="0"]
light_energy = 2.0
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_005_Orientation" parent="Spot_005" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 8.8
spot_angle = 28.8

[node name="Spot000_Orientation" parent="Spot000" index="0"]
light_energy = 2.26
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_004_Orientation" parent="Spot_004" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 26.3
spot_angle = 45.0
spot_angle_attenuation = 1.0

[node name="Spot013_Orientation" parent="Spot013" index="0"]
transform = Transform3D(1, 1.55903e-09, 6.81474e-17, 0, -4.37114e-08, 1, 1.55903e-09, -1, -4.37114e-08, -3.05176e-05, -2.994, 0)
light_energy = 2.26
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_003_Orientation" parent="Spot_003" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_002_Orientation" parent="Spot_002" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_001_Orientation" parent="Spot_001" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_000_Orientation" parent="Spot_000" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
shadow_bias = 0.01
spot_range = 5.0
spot_angle = 30.8
spot_angle_attenuation = 1.0

[node name="Spot012_Orientation" parent="Spot012" index="0"]
transform = Transform3D(1, 1.55903e-09, 6.81474e-17, 0, -4.37114e-08, 1, 1.55903e-09, -1, -4.37114e-08, 0, -3.04347, -3.8147e-06)
light_energy = 2.98
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_013_Orientation" parent="Spot_013" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
shadow_bias = 0.01
spot_range = 5.0
spot_angle = 26.8
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Spot_012_Orientation" parent="Spot_012" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 12.0
light_volumetric_fog_energy = 10000.0
light_bake_mode = 1
shadow_enabled = true
spot_range = 25.0
spot_angle_attenuation = 2.0

[node name="Point010_Orientation" parent="Point010" index="0"]
light_color = Color(0.0666667, 0.239216, 0.235294, 1)
[node name="Point_010_Orientation" parent="Point_010" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
shadow_enabled = true
omni_range = 15.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
omni_range = 25.0

[node name="Point008_Orientation" parent="Point008" index="0"]
[node name="Point_008_Orientation" parent="Point_008" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
shadow_enabled = true
omni_range = 15.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
omni_range = 25.0

[node name="Point006_Orientation" parent="Point006" index="0"]
[node name="Point_006_Orientation" parent="Point_006" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
omni_range = 15.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
omni_range = 25.0

[node name="Point004_Orientation" parent="Point004" index="0"]
[node name="Point_004_Orientation" parent="Point_004" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
shadow_enabled = true
omni_range = 15.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
omni_range = 25.0

[node name="Point002_Orientation" parent="Point002" index="0"]
[node name="Point_002_Orientation" parent="Point_002" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
shadow_enabled = true
omni_range = 15.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
omni_range = 25.0

[node name="Point_Orientation" parent="Point" index="0"]
light_color = Color(1, 1, 1, 1)
light_energy = 1.0
light_volumetric_fog_energy = 10000.0
light_specular = 0.0
light_bake_mode = 1
shadow_enabled = true
omni_range = 15.0
omni_range = 25.0
omni_attenuation = 2.0
Binary file modified level/level.exr
Binary file not shown.
9 changes: 4 additions & 5 deletions level/level.exr.import
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,19 @@
importer="2d_array_texture"
type="CompressedTexture2DArray"
uid="uid://bwrkkvnq7ekgo"
path.bptc="res://.godot/imported/level.exr-f8692a9e8b90a50a8e781c95ee874290.bptc.ctexarray"
path="res://.godot/imported/level.exr-f8692a9e8b90a50a8e781c95ee874290.ctexarray"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
"vram_texture": false
}

[deps]

source_file="res://level/level.exr"
dest_files=["res://.godot/imported/level.exr-f8692a9e8b90a50a8e781c95ee874290.bptc.ctexarray"]
dest_files=["res://.godot/imported/level.exr-f8692a9e8b90a50a8e781c95ee874290.ctexarray"]

[params]

compress/mode=2
compress/mode=0
compress/high_quality=true
compress/lossy_quality=0.7
compress/hdr_compression=1
Expand Down
Loading

0 comments on commit 374bd8d

Please sign in to comment.