Aaron Franke
f91934872d
Use a const ref for the bone AABB in rendering code
2022-08-18 12:20:11 -05:00
Clay John
982ff7d925
Merge pull request #64416 from aaronfranke/aabb
...
Don't try to merge unused bone AABBs in the rendering server
2022-08-17 23:56:05 -06:00
Aaron Franke
e0d80b37e9
Don't try to merge unused bone AABBs in the rendering server
2022-08-14 23:30:48 -05:00
clayjohn
65e0b266d1
Bind uniform buffer locations for lights even when no lights present to comply with strict webGL drivers
2022-08-12 15:23:01 -06:00
bruvzg
e7464e7a30
Fix macOS and iOS defines in the rendering code.
2022-08-08 17:51:31 +03:00
Rémi Verschelde
8734ef1f7a
Merge pull request #62547 from clayjohn/ref_vec_pbr
2022-08-08 10:18:32 +02:00
Hugo Locurcio
baaa7503c7
Add a shadow opacity property to Light3D
...
This can be used to make shadows translucent for a specific light.
The light distance fade system also uses this to smoothly fade the shadow
when the light fade transition distance is greater than 0.
2022-08-07 11:06:32 +02:00
Rafał Mikrut
49632bf993
Check also GLES3 in CI
2022-08-06 19:12:09 +02:00
Hugo Locurcio
db22b7ded0
Rename shader parameter uniform setter/getter methods for consistency
...
`shader_uniform` is now consistenly used across both per-shader
and per-instance shader uniform methods. This makes methods easier
to find in the class reference when looking for them.
2022-08-04 23:17:06 +02:00
Rémi Verschelde
8a9700c8a7
Force disable S3TC support on Android/iOS since we don't handle it
...
Fixes #63909 for now.
This could be improved in the future if we want to properly support S3TC on mobile.
2022-08-04 18:27:56 +02:00
Patrick Exner
fe5901310e
Add spatial built-ins (camera-pos, object-pos, camera-eye etc.)
2022-08-02 17:30:41 +02:00
Rémi Verschelde
8cce479c01
Merge pull request #51672 from Calinou/shader-add-hint-transparent-texture
...
Add `hint_transparent` to use a transparent black placeholder texture
2022-08-02 07:15:59 +02:00
Hugo Locurcio
813f6a5d57
Add `hint_transparent` to use a transparent black placeholder texture
...
This can be used in shaders to avoid the need to supply a transparent
placeholder texture manually.
2022-08-01 23:38:06 +02:00
clayjohn
4b80cb4aa3
Fix various bugs in GLES3 renderer that stopped it from running on web
2022-08-01 16:45:32 -04:00
Yuri Rubinsky
9ec6de1767
Merge pull request #63766 from Chaosus/fix_shader_instance_uniform
2022-08-01 15:04:54 +03:00
Yuri Rubinsky
81c44718ca
Fix passing values to the instance uniforms in the shader
2022-08-01 13:45:29 +03:00
Rémi Verschelde
d29e95687e
Merge pull request #63761 from BastiaanOlij/gles3_scene_singleton_init
2022-08-01 11:35:19 +02:00
Bastiaan Olij
367507e7da
Initialise singleton in RendererSceneGLES3
2022-08-01 18:42:42 +10:00
Rémi Verschelde
677f565ce8
Merge pull request #63587 from clayjohn/specular-occlusion
...
Treat specular less than 0.02 as occlusion
2022-08-01 07:54:57 +02:00
clayjohn
0c65ed38a6
Treat specular less than 0.02 as occlusion
...
This is a very common hack used in almost all PBR renderers to allow removing specular contribution in dielectric materials
2022-07-31 15:45:21 -07:00
LinuxUserGD
6e6569aa78
fix 'Comparison result is always the same' warnings
2022-07-29 19:45:22 +02:00
Rémi Verschelde
2bf8c4a6d0
Merge pull request #63527 from BastiaanOlij/rework_environment
...
Restructure environment in render implementation
2022-07-29 08:05:40 +02:00
Bastiaan Olij
f579125eeb
Restructure environment in render implementation
2022-07-29 12:24:32 +10:00
Rémi Verschelde
8e0f328a80
Merge pull request #59840 from Calinou/renderingserver-global-uniform-rename
2022-07-28 20:34:17 +02:00
Hugo Locurcio
4b42379c8f
Rename RenderingServer global shader uniform methods to be more explicit
...
The `global_shader_uniform` name is longer, but it makes it much
easier to find the methods when searching in the class reference.
2022-07-28 18:46:59 +02:00
Hugo Locurcio
e24029edc3
Allow changing mipmap LOD bias when FSR 1.0 scaling is not used
...
Mipmap LOD bias can be useful to improve the appearance of distant
textures without increasing anisotropic filtering (or in situations
where anisotropic filtering is not effective).
`fsr_mipmap_bias` was renamed to `texture_mipmap_bias` accordingly.
The property hint now allows for greater precision as well.
2022-07-28 17:51:13 +02:00
Rémi Verschelde
199ea349f5
Merge pull request #57698 from bluenote10/feature/rename_translated_to_translated_local
2022-07-28 10:03:07 +02:00
Rémi Verschelde
d7a1acd229
Merge pull request #62364 from clayjohn/GLES3-sky-optimization
2022-07-27 12:39:58 +02:00
Rémi Verschelde
d5ec1a9650
Merge pull request #63477 from Chaosus/shader_fix_fog
2022-07-27 09:35:30 +02:00
Yuri Rubinsky
bbf76faf86
Fix `FOG` built-in in spatial/fragment shader
2022-07-27 08:31:06 +03:00
Bastiaan Olij
0bd042c601
Change RendererSceneRender::GeometryInstance so more code is shared among renderers
2022-07-27 12:32:07 +10:00
Yuri Rubinsky
886c2d9681
Implement shader uniform groups/subgroups
2022-07-26 11:26:09 +03:00
Rémi Verschelde
90019676b0
Code quality: Fix header guards consistency
...
Adds `header_guards.sh` bash script, used in CI to validate future
changes. Can be run locally to fix invalid header guards.
2022-07-25 11:17:40 +02:00
reduz
455c06ecd4
Implement Vector4, Vector4i, Projection
...
Implement built-in classes Vector4, Vector4i and Projection.
* Two versions of Vector4 (float and integer).
* A Projection class, which is a 4x4 matrix specialized in projection types.
These types have been requested for a long time, but given they were very corner case they were not added before.
Because in Godot 4, reimplementing parts of the rendering engine is now possible, access to these types (heavily used by the rendering code) becomes a necessity.
**Q**: Why Projection and not Matrix4?
**A**: Godot does not use Matrix2, Matrix3, Matrix4x3, etc. naming convention because, within the engine, these types always have a *purpose*. As such, Godot names them: Transform2D, Transform3D or Basis. In this case, this 4x4 matrix is _always_ used as a _Projection_, hence the naming.
2022-07-23 14:00:01 +02:00
Rémi Verschelde
fe929d4787
Merge pull request #62513 from reduz/shader_preprocessor_remake
2022-07-23 00:02:33 +02:00
Rémi Verschelde
4f7bfacfcd
Merge pull request #62478 from BastiaanOlij/split_effects_20220628
2022-07-22 23:44:52 +02:00
reduz
f649678402
Clean up Shader Preprocessor
...
* Moved preprocessor to Shader and ShaderInclude
* Clean up RenderingServer side
* Preprocessor is separate from parser now, but it emits tokens with include location hints.
* Improved ShaderEditor validation code
* Added include file code completion
* Added notification for all files affected by a broken include.
2022-07-22 22:53:03 +02:00
bruvzg
8823eae328
Rename OSX to macOS and iPhoneOS to iOS.
2022-07-21 09:37:52 +03:00
Bastiaan Olij
eefcb5ed67
Move screen space effects into a separate class
2022-07-19 13:27:39 +10:00
David R
c2b0a873c2
added usage_defines for SPECULAR_SHININESS
...
added usage defines for opengl3 renderer
2022-07-18 00:45:42 +02:00
Bastiaan Olij
d139131aab
Adding Variable Rate Shading support to Godot
...
Improve GI renderer and add VRS support
Implement render device has_feature and move subgroup settings to limit_get
2022-07-17 15:42:24 +10:00
Fabian Keller
2bf9e6090c
rename translate(d) to translate(d)_local in Transform 2D/3D
2022-07-16 11:47:54 +02:00
Hugo Locurcio
21ea1c3835
Rename soft shadow quality project settings for easier searching
...
`rendering/quality/shadows` is now `rendering/quality/positional_shadow`
to explicitly denote that the settings only affect positional light shadows,
not directional light shadows.
Shadow atlas settings now contain the word "atlas" for easier searching.
Soft shadow quality settings were renamed to contain the word "filter".
This makes the settings appear when searching for "filter" in the
project settings dialog, like in Godot 3.x.
2022-07-13 19:56:02 +02:00
Yuri Rubinsky
3dc1a1dbfb
Prevent possible crash when mesh is freed
2022-07-06 19:52:54 +03:00
Rémi Verschelde
55fca1cb94
Merge pull request #62344 from BastiaanOlij/extract_dependencies
2022-07-06 13:24:46 +02:00
Hugo Locurcio
c9037a8d2c
Remove unused anisotropy setter/getter methods in VoxelGI
...
These methods weren't exposed to the scripting API.
Anisotropy was used in earlier iterations of VoxelGI, but it was
removed as it was too expensive.
2022-07-06 02:40:49 +02:00
Rémi Verschelde
6bbfd160b0
SCons: Properly track codegen script dependency for generated GLSL headers
2022-07-02 16:01:48 +02:00
clayjohn
93c82ab4b9
Evaluate specular reflections using specular dominant direction instead of assuming mirror reflections
2022-06-29 23:36:18 -07:00
Bastiaan Olij
ecfcfd97fa
Split dependency logic
...
Split FOG
Split visibility notifier
Final cleanup of storage classes
2022-06-28 00:10:29 +10:00
clayjohn
88830509d1
Precompute on the CPU as much as possible for the Cubemap filter shader
2022-06-22 16:46:27 -07:00