Commit graph

1073 commits

Author SHA1 Message Date
Rémi Verschelde 710b34b702 Style: Fix missing/invalid copyright headers 2020-05-14 16:54:54 +02:00
Rémi Verschelde a1aaed5a84 Remove redundant void argument lists
Using clang-tidy's `modernize-redundant-void-arg`.
https://clang.llvm.org/extra/clang-tidy/checks/modernize-redundant-void-arg.html
2020-05-14 13:51:45 +02:00
Rémi Verschelde 1f6f364a56 Port member initialization from constructor to declaration (C++11)
Using `clang-tidy`'s `modernize-use-default-member-init` check and
manual review of the changes, and some extra manual changes that
`clang-tidy` failed to do.

Also went manually through all of `core` to find occurrences that
`clang-tidy` couldn't handle, especially all initializations done
in a constructor without using initializer lists.
2020-05-14 10:01:56 +02:00
Rémi Verschelde d3bd219362 doc: Sync classref with current source
Adds API changes from the new GPU lightmapper.
2020-05-12 10:10:50 +02:00
Juan Linietsky 1bea8e1eac New lightmapper
-Added LocalVector (needed it)
-Added stb_rect_pack (It's pretty cool, we could probably use it for other stuff too)
-Fixes and changes all around the place
-Added library for 128 bits fixed point (required for Delaunay3D)
2020-05-10 15:59:09 -03:00
Rémi Verschelde 94721f5ab8 Revert "Renamed plane's d to distance"
This reverts commit ec7b481170.

This was wrong, `d` is not a distance but the `d` constant in the
parametric equation `ax + by + cz = d` describing the plane.
2020-05-10 16:47:11 +02:00
Rémi Verschelde 69de7ce38c Style: clang-format: Disable AllowShortCaseLabelsOnASingleLine
Part of #33027.
2020-05-10 13:13:54 +02:00
Rémi Verschelde e956e80c1f Style: clang-format: Disable AllowShortIfStatementsOnASingleLine
Part of #33027, also discussed in #29848.

Enforcing the use of brackets even on single line statements would be
preferred, but `clang-format` doesn't have this functionality yet.
2020-05-10 13:12:16 +02:00
Marcus Elg ec7b481170 Renamed plane's d to distance 2020-05-10 12:12:51 +02:00
Rémi Verschelde bef52957d0
Merge pull request #38226 from Calinou/increase-camera3d-fov
Increase the default Camera3D field of view to 75
2020-05-07 21:16:21 +02:00
hoontee 330bd686ab
Fix bug with AudioStreamPlayer3D audio position
Applies 0c78a58b64 to `AudioStreamPlayer3D::play`.
2020-05-07 02:23:50 -05:00
Rémi Verschelde 878adb22b7
Merge pull request #37717 from qarmin/world_fix
Change non-existent World to World3D
2020-05-04 16:37:40 +02:00
Bastiaan Olij 45d1f41837 Added missing spring enums for generic_6dof_joint 2020-05-02 21:49:56 +10:00
Rémi Verschelde b77f0e83ca
Merge pull request #38346 from jitspoe/master.fix_uninitialized_particle_param
Fix custom w component being uninitialized on CPU particles.
2020-05-01 14:58:10 +02:00
Hugo Locurcio ccc4f3899c
Increase the default Camera3D field of view to 75
A vertical FOV of 75 degrees is roughly equivalent to a 91 degree
horizontal FOV on a 4:3 display (~107.51 degrees on 16:9),
which is close to the typical default FOV used in PC games.

Note that this doesn't apply to the in-editor camera which keeps its
FOV to 70. This is because it doesn't display in fullscreen;
its viewport only displays in the center of the editor (roughly).
This means the viewport won't cover the viewer's eyes as much. Therefore,
the editor camera FOV should be slightly lower to account for this.

Since this changes the default value, this may break existing projects
slightly.

For the record, this was already done in
https://github.com/godotengine/godot-demo-projects/pull/260
for the official demo projects.
2020-05-01 14:03:27 +02:00
jitspoe 895ed2aed7 Fix custom w component being uninitialized on CPU particles.
(cherry picked from commit 38085f2f6982c491935a434bb45e358dbebe1714)
(cherry picked from commit b9c280b73ff6a13ea490d2da0f2728bcef3038dc)
2020-04-30 01:41:46 -04:00
Rémi Verschelde b46e5c7b94
Merge pull request #38203 from woollysammoth/multiple-ik-bug
Fixes SkeletonIK resetting other IK poses
2020-04-29 17:29:51 +02:00
Aaron Franke 540156b387
[Core] Rename linear_interpolate to lerp 2020-04-29 04:02:49 -04:00
Rémi Verschelde fdf58a5858 Rename InputFilter back to Input
It changed name as part of the DisplayServer and input refactoring
in #37317, with the rationale that input no longer goes through the
main loop, so the previous Input singleton now only does filtering.

But the gains in consistency are quite limited in the renaming, and
it breaks compatibility for all scripts and tutorials that access
the Input singleton via the scripting language. A temporary option
was suggested to keep the scripting singleton named `Input` even if
its type is `InputFilter`, but that adds inconsistency and breaks C#.

Fixes godotengine/godot-proposals#639.
Fixes #37319.
Fixes #37690.
2020-04-28 15:19:49 +02:00
Sam e321d38c0e Resets global pose of IK chain bones being solved, rather than the whole skeleton. Resolves #38026 2020-04-25 10:57:42 -04:00
Rémi Verschelde a800048071
Merge pull request #38109 from nekomatata/mesh-instance-active-material
Fix get_active_material when a material is directly set on the mesh
2020-04-23 12:42:11 +02:00
PouleyKetchoupp 72ee09082c Fix get_active_material when a material is directly set on the mesh
Makes MeshInstance3D::get_active_material consistent with the logic
in the rendering system.

Fixes #38108
2020-04-22 14:35:25 +02:00
Juan Linietsky f8ef38efed Add proper type to most public API uses of Array 2020-04-21 12:16:45 -03:00
Rémi Verschelde 94f0c62789 Fix more GCC -Wmaybe-uninitialized warnings
Fixes #38005.
2020-04-20 22:34:20 +02:00
Rémi Verschelde b7b46093d8 doc: Sync classref with current source
Add missing enum bindings.
2020-04-20 11:48:00 +02:00
qarmin 559bc3ca87 Change non-existent World to World3D 2020-04-18 11:00:51 +02:00
Rémi Verschelde 17304f1aae
Merge pull request #37949 from reduz/implement-global-shader-uniforms
Implement global and per instance shader uniforms.
2020-04-17 18:36:06 +02:00
Rémi Verschelde 077dbdf246
Merge pull request #37964 from AndreaCatania/AndreaCatania-patch-2
Activate Physics Process in SpringArm3D.
2020-04-17 17:38:22 +02:00
Juan Linietsky 0e1c66d9fc Implement global and per instance shader uniforms.
Adds two keywords to shader language for uniforms:
-'global'
-'instance'

This allows them to reference values outside the material.
2020-04-17 12:35:41 -03:00
Andrea Catania 152303bf51
Activate Physics Process in SpringArm3D. 2020-04-17 16:22:24 +02:00
Rémi Verschelde 3c1218a39a
Merge pull request #37914 from clayjohn/VULKAN-decal-fix
Fix texture check in decal setup
2020-04-15 21:26:08 +02:00
clayjohn 61d86190e0 Fix texture check in decal setup 2020-04-15 12:06:02 -07:00
Marcel Admiraal 188bb6f867 Run SpringArm3D's process within physics. 2020-04-15 17:48:46 +01:00
Rémi Verschelde 5b4ea6529a
Merge pull request #37896 from NutmegStudio/decal-enum-constant-fix
Change DecalTexture bind from BIND_CONSTANT to BIND_ENUM_CONSTANT
2020-04-15 12:02:19 +02:00
NutmegStudio fa6d9e0c01 Change DecalTexture bind from BIND_CONSTANT to BIND_ENUM_CONSTANT 2020-04-15 15:00:48 +07:00
NutmegStudio df863cf7ee Fix typo in light3d (Texture -> Texture2D) 2020-04-15 14:09:48 +07:00
Rémi Verschelde 9db525941f
Merge pull request #37887 from reduz/implement-projectors
Add support for projectors in spot and omni lights.
2020-04-14 23:03:32 +02:00
Juan Linietsky 6f293ed795 Add support for projectors in spot and omni lights. 2020-04-14 17:05:45 -03:00
Rémi Verschelde 59a8af2106
Merge pull request #37316 from nekomatata/physical-bone-settings
Add PhysicalBone rotation, damping, axis lock & can sleep
2020-04-14 18:33:43 +02:00
Rémi Verschelde 5e5103f460
Merge pull request #37861 from reduz/implement-decals
Implement decals
2020-04-14 17:13:20 +02:00
Juan Linietsky 5944eb6e7f Implement decals
Also implemented decal atlas, so projectors and other stuff can be added.
Sidenote: Had to make RID hashable, so some unrelated includes changed
in order to include it in hashfuncs.h
2020-04-14 11:13:34 -03:00
PouleyKetchoupp 5c1c03f29a Add PhysicalBone rotation, damping, axis lock & can sleep 2020-04-14 11:55:46 +02:00
MickeMakaron 2edb59ec88 Handle huge offset values in Path2D and Path3D set_offset 2020-04-13 07:42:47 +02:00
Rémi Verschelde 06748a2b5f
Merge pull request #37749 from clayjohn/Vulkan-improved-ss
Add vogel filter and settings to soft shadows
2020-04-13 00:39:37 +02:00
clayjohn 621f6f09a8 Add proper quality settings to soft shadows 2020-04-10 23:09:17 -07:00
Rémi Verschelde c2f0d58c36
Merge pull request #37722 from reduz/implement-softshadows
Support light size and soft shadows
2020-04-10 10:24:57 +02:00
Juan Linietsky 6a730ffeab Support light size and soft shadows 2020-04-09 15:11:15 -03:00
Bastiaan Olij afc8c6391c Renaming all ARVR nodes to XR 2020-04-09 15:33:01 +10:00
Juan Linietsky 4ffc0d6b3f Refactored shadowmapping.
- Made shadow bias size independent, so it will remain when changing light or camera size.
- Implemented normal offset bias, which greatly enhances quality.
- Added transmission to subsurface scattering
- Reimplemented shadow filter modes

Closes #17260
2020-04-08 11:19:43 -03:00
Rémi Verschelde ea7b497065 Replace more occurrences of NULL with nullptr 2020-04-02 14:56:01 +02:00