Commit graph

2227 commits

Author SHA1 Message Date
Gilles Roudière d8bb53cd21 Implement scenes tiles in TileMaps 2021-05-20 13:12:03 +02:00
Rémi Verschelde 4219a4cb6f
Fix typos with codespell
Using codespell 2.0.0.

Method:
```
$ cat > ../godot-word-whitelist.txt << EOF
ang
curvelinear
dof
doubleclick
fave
findn
GIRD
leapyear
lod
merchantibility
nd
numer
ois
ony
que
seeked
synching
te
uint
unselect
webp
EOF

$ codespell -w -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"
$ git diff // undo unwanted changes
```
2021-05-20 12:38:56 +02:00
Rémi Verschelde b2fb119c53
Merge pull request #36263 from Calinou/increase-default-2d-gravity 2021-05-18 10:54:47 +02:00
Rémi Verschelde 66dac8bda0
Merge pull request #47544 from pycbouh/control-expose-theme-type 2021-05-18 10:52:51 +02:00
Rémi Verschelde 8e8cad5bc9
Merge pull request #48549 from kleonc/bitmap_resize_fix
BitMask::create Don't request more memory than needed when size is a multiply of 8
2021-05-17 17:39:24 +02:00
Rémi Verschelde 6c367f8e0d
Merge pull request #48168 from LightningAA/control-to-ctrl-4.0 2021-05-17 17:38:02 +02:00
Yuri Sizov 9eaa139c1f Add theme_custom_type property to Control and Window 2021-05-17 17:20:42 +03:00
Rémi Verschelde b0a51bf9fe
Merge pull request #48768 from akien-mga/file-access-64-bit-4.0
Make all file access 64-bit (`uint64_t`)
2021-05-17 16:02:12 +02:00
Hugo Locurcio d211c05111
Use a DynamicFont for the default project theme
This makes font oversampling work out of the box, while also increasing
the supported character set's size. The default font is now larger
as well to better fit today's screen resolutions.

The OpenSans SemiBold font was chosen for two reasons:

- Small file size, yet its character set supports Latin-1 and Cyrillic
  text.
- A heavier font weight looks better in most "game" scenarios and is
  more readable against mixed-color backgrounds.

This is considered a breaking change as it changes the default font's
metrics, which will likely affect how Control nodes are laid out in
scenes (unless a custom font is in use).
2021-05-17 15:19:13 +02:00
Pedro J. Estébanez 469fa47e06
Make all file access 64-bit (uint64_t)
This changes the types of a big number of variables.

General rules:
- Using `uint64_t` in general. We also considered `int64_t` but eventually
  settled on keeping it unsigned, which is also closer to what one would expect
  with `size_t`/`off_t`.
- We only keep `int64_t` for `seek_end` (takes a negative offset from the end)
  and for the `Variant` bindings, since `Variant::INT` is `int64_t`. This means
  we only need to guard against passing negative values in `core_bind.cpp`.
- Using `uint32_t` integers for concepts not needing such a huge range, like
  pages, blocks, etc.

In addition:
- Improve usage of integer types in some related places; namely, `DirAccess`,
  core binds.

Note:
- On Windows, `_ftelli64` reports invalid values when using 32-bit MinGW with
  version < 8.0. This was an upstream bug fixed in 8.0. It breaks support for
  big files on 32-bit Windows builds made with that toolchain. We might add a
  workaround.

Fixes #44363.
Fixes godotengine/godot-proposals#400.

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2021-05-17 15:06:19 +02:00
John Wigg c8e402324e
Fix normals of PrismMesh 2021-05-16 23:01:53 +02:00
Rémi Verschelde 99626d5b57
Merge pull request #48478 from brennengreen/normal-mapping-unpacked-fix
Fix refraction offset by manually unpacking normal mappings
2021-05-14 11:33:22 +02:00
kleonc 8963be2ef4 BitMask::create Don't request more memory than needed when size is a multiply of 8 2021-05-08 13:04:41 +02:00
Lightning_A 97fecd1b69 Rename "Control" key to "Ctrl" and add "_pressed" suffix to all InputEventWithModifiers properties/methods 2021-05-07 14:00:50 -06:00
Rémi Verschelde c3f7465b7e
Merge pull request #48535 from groud/tiles_squashed
TileSet and TileMap rework (squashed)
2021-05-07 20:46:06 +02:00
Gilles Roudière a3dda2df85 Rework the TileSet resource and TileMap nodes:
- Move most properties from TileMap to TileSet,
- Make TileSet more flexible, supporting more feature (several
  collision layers, etc...),
- Fusion both the TileMap and TileSet editor,
- Implement TileSetSources, and thus a new way to index tiles in the TileSet,
- Rework the TileSet and TileMap editors completely,
- Implement an editor zoom widget (and use it in several places)
2021-05-07 18:06:17 +02:00
Brennen Green 31f2d946ad Manually unpacked normal mapping to fix issue with refraction being offset rather than distorted. 2021-05-07 08:38:36 -04:00
Rémi Verschelde 8dc12135e4
Merge pull request #48376 from rafallus/fix_surfacetool_crash_master
Check input mesh is valid in SurfaceTool methods (master)
2021-05-07 00:58:20 +02:00
Hugo Locurcio 4a28f7e44f
Increase the default 2D gravity to 980.0
This makes 2D RigidBody physics feel less floaty out of the box.

This closes https://github.com/godotengine/godot-proposals/issues/98.
2021-05-05 22:49:06 -04:00
Hugo Locurcio cf1e30a2ed
Tweak CanvasItem/material sampling property hints for readability
The "Anisotropic" term is abbreviated as spelling it out would cause
the PopupMenu to overflow the editor window when using the default
inspector width.
2021-05-06 03:05:37 +02:00
Rémi Verschelde e144ff0445
Merge pull request #48315 from nekomatata/expose-physics-debug-shape
Expose get_debug_mesh in Shape3D to scripting API
2021-05-05 15:17:36 +02:00
Rémi Verschelde b5e4d63a0b
Merge pull request #48434 from nekomatata/friction-bounce-greater-than-1
Allow values > 1 for friction and bounce in PhysicsMaterial
2021-05-04 12:28:58 +02:00
PouleyKetchoupp 67987be644 Allow values > 1 for friction and bounce in PhysicsMaterial 2021-05-03 17:48:23 -07:00
jfons 6995b0429c Assorted fixes to UV unwrapping and GPU lightmapper
Various fixes to UV2 unwrapping and the GPU lightmapper. Listed here for
context in case of git blame/bisect:

* Fix UV2 unwrapping on import, also cleaned up the unwrap cache code.
* Fix saving of RGBA images in EXR format.
* Fixes to the GPU lightmapper:
	- Added padding between atlas elements, avoids bleeding.
	- Remove old SDF generation code.
	- Fix baked attenuation for Omni/Spot lights.
	- Fix baking of material properties onto UV2 (wireframe was
	  wrongly used before).
	- Disable statically baked lights for objects that have a
	  lightmap texture to avoid applying the same light twice.
	- Fix lightmap pairing in RendererSceneCull.
	- Fix UV2 array generated from `RenderingServer::mesh_surface_get_arrays()`.
	- Port autoexposure fix for OIDN from 3.x.
	- Save debug textures as EXR when using floating point format.
2021-05-03 18:10:34 +02:00
rafallus 524d27493b Fix SurfaceTool crash when passing invalid Mesh 2021-05-01 23:02:58 -05:00
Marcel Admiraal fcf8071ec9 Fix documentation following implementation of particle trails 2021-05-01 13:12:31 +01:00
reduz 90056460ad Implement Particle Trails
-Enable the trails and set the length in seconds
-Provide a mesh with a skeleton and a skin
-Or, alternatively use one of the built-in TubeTrailMesh/RibbonTrailMesh
-Works deterministically
-Fixed particle collisions (were broken)
-Not working in 2D yet (that will happen next)
2021-04-30 17:38:02 -03:00
Rafał Mikrut efcb097674 Prevent setting too big or too small Collision Mask and Layer 2021-04-30 17:19:04 +02:00
PouleyKetchoupp 7352a4c0d9 Expose get_debug_mesh in Shape3D to scripting API
Can be useful for custom drawing of physics shapes without having to add
a collision object node to the tree.
2021-04-29 18:18:39 -07:00
Rémi Verschelde 418fe155f9
Merge pull request #48269 from akien-mga/remove-largetexture
Remove obsolete LargeTexture, it's no longer useful since 3.x
2021-04-29 09:45:06 +02:00
Rémi Verschelde 7e0a42a673
Merge pull request #46688 from QbieShay/fix-particle-rotate-y-4
Fixed rotate_y property of particle shaders
2021-04-28 17:09:17 +02:00
Rémi Verschelde 0e93a1df79
Remove obsolete LargeTexture, it's no longer useful since 3.x
It existed in early Godot releases to allow working around hardware limitations
on max texture sizes (e.g. hardware limits of 1024x1024 pixels).

Nowadays the max texture size supported natively by Godot is 16384x16384, and
even low end mobile hardware should support at least 4096x4096.

The LargeTexture implementation is basically just an array with offsets, sizes
and textures and should be easy to replicate with a custom Texture resource if
needed - solving most of its bugs on the way as the implementation removed here
has various unimplemented or incomplete methods.
2021-04-28 15:51:55 +02:00
Rémi Verschelde 305b2a15bf
Merge pull request #48239 from akien-mga/goodbye-copymem
Core: Drop custom `copymem`/`zeromem` defines
2021-04-28 11:04:05 +02:00
Rémi Verschelde 0582cefcbb
Merge pull request #48241 from akien-mga/tabs-panel-style-unused
Tabs: Remove unused 'panel' stylebox from default theme
2021-04-27 19:33:40 +02:00
Rémi Verschelde 95cfce661b
Merge pull request #48050 from JFonS/occlusion_culling 2021-04-27 19:07:12 +02:00
Rémi Verschelde cd8d321961
Tabs: Remove unused 'panel' stylebox from default theme
Cf. https://github.com/godotengine/godot/issues/37875#issuecomment-625297308.
2021-04-27 17:36:53 +02:00
Rémi Verschelde 8247667a3e
Core: Drop custom copymem/zeromem defines
We've been using standard C library functions `memcpy`/`memset` for these since
2016 with 67f65f6639.

There was still the possibility for third-party platform ports to override the
definitions with a custom header, but this doesn't seem useful anymore.
2021-04-27 16:26:27 +02:00
Rémi Verschelde b95a82d46a
Merge pull request #47826 from Chaosus/vs_fix_default_input_overriding
Prevents default values of VSNodeCustom from overriding by a script
2021-04-27 10:42:51 +02:00
Stefan Boronczyk f15cabcfd2 fix triplanar mapping for AO 2021-04-25 03:32:17 +02:00
Rémi Verschelde 759b876b8a
Merge pull request #46593 from pycbouh/theme-editor-better-edit-ui
Refactor Edit Theme menu in Theme Editor
2021-04-23 23:12:25 +02:00
jfons 4d9d99bb82 Implement occlusion culling
Added an occlusion culling system with support for static occluder meshes.
It can be enabled via `Project Settings > Rendering > Occlusion Culling > Use Occlusion Culling`.

Occluders are defined via the new `Occluder3D` resource and instanced using the new
`OccluderInstance3D` node. The occluders can also be automatically baked from a
scene using the built-in editor plugin.
2021-04-23 21:45:23 +02:00
Rémi Verschelde c36807994d
Merge pull request #47345 from nekomatata/heightmap-draw-triangles
Draw triangles for HeightMapShape debug collision
2021-04-20 17:41:11 +02:00
Rémi Verschelde fdf041a466
Merge pull request #47347 from nekomatata/heightmap-support
Heightmap collision shape support in Godot Physics
2021-04-20 17:40:28 +02:00
Rémi Verschelde 29775a1714
doc: Sync classref with current source 2021-04-19 12:26:37 +02:00
Rémi Verschelde 8ba06e3161
Merge pull request #47448 from madmiraal/rename-lineedit-cursor
Rename LineEdit getters and setters to match property names
2021-04-19 10:40:29 +02:00
Rémi Verschelde 6269895ecb
Merge pull request #47980 from reduz/split-particle-shader-entry-points
Split particle shader entry points
2021-04-18 23:39:17 +02:00
Yuri Sizov 2524238bb3 Refactor Edit Theme menu in Theme Editor 2021-04-18 17:55:49 +03:00
Yuri Roubinsky 8ae5c6c6ec Fix sky visual shader mode after last rename 2021-04-17 20:59:48 +03:00
reduz 906882ee66 Split particle shader entry points
* Particle shaders now have start() and process()
* Particle collision happens between them.
* The RESTART property is kept, so porting an old shader is still possible.

This fixes the problem of particle collisions not functioning on the first particle frame.
2021-04-17 12:22:55 -03:00
Marcel Admiraal 86822b187e Rename LineEdit caret_* properties getters and setters to match property 2021-04-17 12:41:23 +01:00
Rémi Verschelde 8bbdd43b09
Merge pull request #47950 from AndreaCatania/AndreaCatania-patch-4
Lowers the navigation edge margin merge
2021-04-16 10:23:55 +02:00
Andrea Catania fd2e652196
Lowers the navigation edge margin merge
Lowers the edge margin merge to avoid merge undesired edges.
2021-04-16 09:56:39 +02:00
reduz d3b49c416a Refactor GLSL shader compilation
-Used a more consistent set of keywords for the shader
-Remove all harcoded entry points
-Re-wrote the GLSL shader parser, new system is more flexible. Allows any entry point organization.
-Entry point for sky shaders is now sky().
-Entry point for particle shaders is now process().
2021-04-14 11:37:52 -03:00
Yuri Roubinsky 8d3e46098b Prevents default values of VSNodeCustom from overriding by a script 2021-04-12 14:41:08 +03:00
Rémi Verschelde 8b6e3d6375
Merge pull request #46340 from gongpha/various-color-picker
Add Various ColorPicker shapes
2021-04-10 13:29:50 +02:00
Rémi Verschelde cba3b024b5
Merge pull request #43746 from CaptainProton42/master
Vulkan: Implement triplanar mapping in world space
2021-04-08 21:26:08 +02:00
Kongfa Waroros 6294507acb Add Various ColorPicker shapes 2021-04-06 22:48:03 +07:00
Rémi Verschelde d83761ba80
Style: Apply clang-tidy's readability-braces-around-statements 2021-04-05 14:09:59 +02:00
Yuri Roubinsky 44af52d62c Prevents TextureUniform in visual shaders from conversion to constant 2021-04-04 17:32:44 +03:00
Rémi Verschelde cbf5408685
Merge pull request #46273 from Chaosus/vs_comment
Added Comment node to Visual Shaders
2021-04-04 16:04:12 +02:00
Rémi Verschelde 4b6e9f3157
Merge pull request #46991 from madmiraal/rename-invert-reverse
Rename Array.invert() to Array.reverse()
2021-04-01 13:32:22 +02:00
Rémi Verschelde c2b7c69e2b
Merge pull request #42827 from lyuma/rename_bones_blendshapes
Allow renaming bones and blendshapes.
2021-04-01 00:20:07 +02:00
Rémi Verschelde c6ff6707a4
Merge pull request #47457 from bruvzg/rtl_spacing
RichTextLabel: fix font extra spacing and style box size usage.
2021-03-29 17:07:38 +02:00
bruvzg 9f4893c70b
Use extra font spacing in the RichTextLabel line height calculation, and stylebox size in the minimum size calculation. 2021-03-29 17:26:53 +03:00
Rémi Verschelde bc29f4bca1
Merge pull request #47435 from madmiraal/rename-texture-get_data
Rename Texture.get_data() to get_image()
2021-03-29 10:41:22 +02:00
Rémi Verschelde b2eb838781
doc: Sync classref with current source 2021-03-29 09:51:33 +02:00
Marcel Admiraal fd30c36985 Rename Texture.get_data() to get_image() 2021-03-28 13:00:46 +01:00
PouleyKetchoupp c8dd3c7d80 Heightmap collision shape support in Godot Physics 2021-03-25 16:52:41 -07:00
Rémi Verschelde c6b9ceadf2
Merge pull request #47163 from bruvzg/macos_sandbox_file_dialog
FileDialog: add Back/Forward buttons, add message for inaccessible folders.
2021-03-26 00:00:25 +01:00
Morris Tabor 0fc8318f1a Fix ParticlesMaterial spread 2021-03-25 17:33:44 +01:00
Rémi Verschelde 9343a8a970
Merge pull request #47251 from pycbouh/theme-more-useful-methods
Add utility methods to Theme, improve error messages and documentation
2021-03-25 13:09:27 +01:00
PouleyKetchoupp 806a1a6646 Draw triangles for HeightMapShape debug collision
Helps with ambiguous cases where it's not possible to tell which diagonal is used for collision in quads.
2021-03-24 17:58:54 -07:00
Hugo Locurcio b191a7547c
Rename the .shader file extension to .gdshader
This lets third-party software recognize Godot shaders more easily,
without relying on guesswork since the `.shader` extension is generic.
2021-03-24 21:33:44 +01:00
Rémi Verschelde 036a50e8b9
Merge pull request #37755 from KoBeWi/check_down
Add disabled theme icons for CheckBox
2021-03-23 13:06:02 +01:00
bruvzg b202a0dd2a
FileDialog: add Back/Forward buttons, add message for inaccessible folders. 2021-03-23 08:03:41 +02:00
Rémi Verschelde e0f19287f7
Merge pull request #47226 from fabriceci/improve-rayshape-2D
Bring the Raycast2D improvements to Rayshape2D
2021-03-22 23:56:18 +01:00
Juan Linietsky 97a3a66220 Improved 3D Scene Importer
* Added option for importers to show an Advanced settings dialog
* Created advanced settings dialog for Scene Importer
* Cleaned up importers (remove many old/unused options)
* Added the ability to customize every node, material, mesh and animation individually
* Saving to animations and meshes to files is now a manual process, making it more predictable
* Added the ability for materials to be replaced by external files (or to be made external, up to you).
* When doubleclicking an impoted scene in the filesystem dock, it automatically shows the import settings instead of asking to open it.

WARNING: Lightmap UV unwrap is not working, it needs to be re-made.
2021-03-22 12:16:40 -03:00
Yuri Sizov 9df05745ba Add utility methods to Theme, improve error messages and documentation 2021-03-22 14:49:31 +03:00
fabriceci f810ff35fa Bring the Raycast2D improvements to Rayshape2D 2021-03-21 14:52:44 +01:00
Marcel Admiraal 755c70b871 Rename Array.invert() to Array.reverse()
Does the same internally for List and Vector<>, which includes all
PackedArray types.
2021-03-21 10:20:08 +00:00
CaptainProton42 856312ca6d Implement FLAG_UV*_USE_WORLD_TRIPLANAR
Implements triplanar mapping in world space for UV1 and UV2
when the respective flags are enabled.
2021-03-19 20:35:20 +01:00
PouleyKetchoupp 7bbd545432 Disable backface collision with ConcavePolygonShape by default
Helps a lot with soft bodies and generally useful to avoid shapes to go
through the ground in certain cases.

Added an option in ConcavePolygonShape to re-enable backface collision
on specific bodies if needed.
2021-03-18 11:30:22 -07:00
Rémi Verschelde 08ca4184f4
Merge pull request #47024 from groud/navigation
Allow Navigation to be more flexible
2021-03-17 09:18:54 +01:00
Aaron Franke a94cef0ea0
Move SpriteFrames to its own file in the resources folder 2021-03-16 02:00:47 -04:00
Gilles Roudière ac7073f586 Allow Navigation to be more flexible 2021-03-15 15:58:59 +01:00
Anshul7sp1 91181c2086 Fixes small typos and grammar correction 2021-03-12 19:05:16 +05:30
Gilles Roudière a9dc53d152 Remove Navigation2D/3D nodes, and move the navigation map to the world resource 2021-03-10 11:23:06 +01:00
Kongfa Waroros d295d53b4a Add interpolation bar on each channel in ColorPicker 2021-03-09 14:58:19 +07:00
Rémi Verschelde 9a33c1b6a6
Merge pull request #46782 from bruvzg/fix_def_theme_size
Improve bitmap font scaling. Fix default theme font size.
2021-03-08 10:03:12 +01:00
bruvzg 43c7c279d5
Improve bitmap font scaling. Fix default theme font size. 2021-03-08 09:56:40 +02:00
Rémi Verschelde c487f1e854
Merge pull request #46643 from YeldhamDev/hide_all_the_things
Hide more options of disabled properties
2021-03-07 15:12:15 +01:00
QbieShay f1bb54d5e5 fixed particle rotate y flag 2021-03-05 11:37:00 +01:00
Rémi Verschelde 6b2577599f
Merge pull request #46665 from nekomatata/fix-crash-convex-shape-2d
Fix errors and crash with empty ConvexPolygonShape2D
2021-03-04 20:19:16 +01:00
PouleyKetchoupp 6fb6090748 Fix errors and crash with empty ConvexPolygonShape2D 2021-03-04 09:46:32 -07:00
Pedro Rodrigues 46218d8c37 Fix crash trying to destroy an ImageTexture object containing a null texture
The problem happened when `ImageTexture::create_from_image` was called
with an empty image. In this situation an RID was allocated despite the
texture being null. The destructor would then crash trying to acess this
null texture.

Fixes #46274
2021-03-03 23:54:27 +00:00
Michael Alexsander 4be282a269 Hide more options of disabled properties 2021-03-03 20:51:35 -03:00
sps1112 cf6bfea93f Add null check for NavigationMesh.create_from_mesh() 2021-03-03 15:59:30 +05:30
Rémi Verschelde 5895cd4c4f
Merge pull request #36202 from YeldhamDev/sprite_region_hide
Hide extra options from various nodes if they're not enabled
2021-03-02 14:15:25 +01:00
Michael Alexsander 70304f8633 Hide extra options from various nodes if they're not enabled 2021-03-02 09:25:09 -03:00
Rémi Verschelde f49433c91c Fix Animation tracks disabled by default
Was a regression from #45845.
2021-03-02 09:15:01 +01:00
Rémi Verschelde 1eaa89a008
Merge pull request #46539 from Chaosus/vs_fix_return
Removes redundant code from get_input/output_port_type (visual shaders)
2021-03-01 09:44:20 +01:00
Yuri Roubinsky 6f9bdaf656 Fix incorrect switching port type in VisualShaderNodeStep 2021-03-01 08:45:49 +03:00
Yuri Roubinsky 9aca12a1af Removes redundant code from get_input/output/_port_type (visual shaders) 2021-03-01 08:34:39 +03:00
Delf Neumärker 04a4828c5e
Fix crash when loading a scene containing an uncreatable type 2021-02-25 23:58:30 +01:00
PouleyKetchoupp c4b116cff7 Added option in project settings to draw Shape2D outlines
Disabling collision outlines can be useful for performance when the game
is running and many collision shapes are displayed.
2021-02-25 07:52:50 -07:00
Rémi Verschelde f3864ec89f
Merge pull request #46357 from kleonc/mesh_data_tool_crash_fix
MeshDataTool::create_from_surface Fail on invalid index data
2021-02-24 13:23:13 +01:00
Rémi Verschelde a527c6856b
Merge pull request #46045 from bruvzg/text_server_bmp_create
[TextServer] Restores bitmap font dynamic construction functions.
2021-02-24 12:55:36 +01:00
kleonc 8e82cf8174 MeshDataTool::create_from_surface Fail on invalid index data 2021-02-23 21:37:32 +01:00
Yuri Roubinsky fe3051fcce Added Comment node to Visual Shaders 2021-02-21 12:40:17 +03:00
Rémi Verschelde f6efa78173
Merge pull request #38565 from nekomatata/export-default-values
Fixed export var default value in PackedScene when script is not loaded in editor
2021-02-21 08:53:58 +01:00
Hugo Locurcio 23a1f616fd
Draw an outline for 2D debug collision shapes
This makes them easier to distinguish, especially when used
in a TileMap.

The default color's opacity has been slightly decreased to account
for the new outline.
2021-02-20 00:00:03 +01:00
Rémi Verschelde 4c4931eeae
Merge pull request #46196 from nmrkr/visual-shader-invalid-forced-connect
Fix crash when calling connect_nodes_forced with invalid params
2021-02-19 15:49:56 +01:00
Delf Neumärker 4a468171e5 Fix crash when calling connect_nodes_forced with invalid params 2021-02-18 22:57:41 +01:00
Delf Neumärker 735f75a16b Fix handling of negative indices in SurfaceTool 2021-02-18 22:43:39 +01:00
Pedro J. Estébanez 8e128726f0 Modernize atomics
- Based on C++11's `atomic`
- Reworked `SafeRefCount` (based on the rewrite by @hpvb)
- Replaced free atomic functions by the new `SafeNumeric<T>`
- Replaced wrong cases of `volatile bool` by the new `SafeFlag`
- Platform-specific implementations no longer needed

Co-authored-by: Hein-Pieter van Braam-Stewart <hp@tmm.cx>
2021-02-18 17:12:46 +01:00
andybarcia f455f873c7 Fixes crash when calling VisualShader::set_mode 2021-02-16 14:57:40 +01:00
Rémi Verschelde 2a03886cbf
Merge pull request #46082 from YeldhamDev/styleboxline_margin_fix
Fix StyleBoxLine's incorrect style margin values
2021-02-16 14:00:45 +01:00
Michael Alexsander ddf05a7c3c Fix StyleBoxLine's incorrect style margin values 2021-02-16 01:36:51 -03:00
Rémi Verschelde f14008b600
Merge pull request #46069 from bruvzg/fix_font_crash_empty_data
Fix font `draw_*string` crash with empty data.
2021-02-15 22:19:53 +01:00
bruvzg a354125d7d
Fix TextLine/TextParagraph crash when add_string / set_dropcap is called null font reference. 2021-02-15 22:57:42 +02:00
bruvzg 0fcbc1c6e3
Fix font draw_*string crash with empty data. 2021-02-15 22:41:16 +02:00
Rémi Verschelde 9d511ff924
Merge pull request #45704 from EricEzaM/PR/popup-menu-beautification
Improved PopupMenu visuals. Removed x-y margin, made it 'padding' instead
2021-02-15 13:38:47 +01:00
bruvzg bee718f1af
[Text Server] Restores bitmap font dynamic construction functions. 2021-02-15 10:46:49 +02:00
bruvzg f4d095cdd3
[TextServer] Restore character and space extra spacing support. 2021-02-15 10:46:23 +02:00
Eric M 26c29cc0d7 Improved PopupMenu visuals. Removed x-y margin, made it 'padding' instead. 2021-02-15 15:45:25 +10:00
kleonc 7d451c0040 VisualShader::_input_type_changed Fix index out of bounds crash. 2021-02-14 15:26:33 +01:00
bruvzg d78336c65e
[CTL] Add missing font outline drawing routines and theme constants. 2021-02-14 14:11:44 +02:00
bruvzg be14f065d1
Fix uninitialized BaseMaterial3D::features variable. 2021-02-14 01:12:30 +02:00
reduz 28537d8c84 Fix LineEdit minimum width
-Changed theme setting name to make more sense of what it does
-Reduced amount of minimum characters, so minimum size is smaller.
2021-02-12 17:04:38 +01:00
reduz f8d03b98e7 Improve resource load cache
-Added a new method in Resource: reset_state , used for reloading the same resource from disk
-Added a new cache mode "replace" in ResourceLoader, which reuses existing loaded sub-resources but resets their data from disk (or replaces them if they chaged type)
-Because the correct sub-resource paths are always loaded now, this fixes bugs with subresource folding or subresource ordering when saving.
2021-02-11 15:44:28 -03:00
reduz 1aa2823fa3 Removed _change_notify
-For inspector refresh, the inspector now detects if a property change by polling a few times per second and then does update the control if so. This process is very cheap.
-For property list refresh, a new signal (property_list_changed) was added to Object. _change_notify() is replaced by notify_property_list_changed()
-Changed all objects using the old method to the signal, or just deleted the calls to _change_notify(<property>) since they are unnecesary now.
2021-02-10 19:31:24 -03:00
Rémi Verschelde e8f73124a7
Merge pull request #45845 from qarmin/cppcheck_scene_2
Initialize class variables with default values in scene/ [2/2]
2021-02-10 20:06:12 +01:00
reduz 8b19ffd810 Make Servers truly Thread Safe
-Rendering server now uses a split RID allocate/initialize internally, this allows generating RIDs immediately but initialization to happen later on the proper thread (as rendering APIs generally requiere to call on the right thread).
-RenderingServerWrapMT is no more, multithreading is done in RenderingServerDefault.
-Some functions like texture or mesh creation, when renderer supports it, can register and return immediately (so no waiting for server API to flush, and saving staging and command buffer memory).
-3D physics server changed to be made multithread friendly.
-Added PhysicsServer3DWrapMT to use 3D physics server from multiple threads.
-Disablet Bullet (too much effort to make multithread friendly, this needs to be fixed eventually).
2021-02-10 13:21:46 -03:00
Rafał Mikrut 7961a1dea3 Initialize class variables with default values in scene/ [2/2] 2021-02-09 18:24:36 +01:00
reduz 3e2281a347 Improve SDFGI indirect light feedback loop
-Use occlusion for feedback, further reduces light leaking.
-More control on feedback, now its a slider.
2021-02-07 21:30:12 -03:00
reduz 8faf23b52b Simplify Volumetric Fog
-Always use temporal reproject, it just loos way better than any other filter.
-By always using termporal reproject, the shadowmap reduction can be done away with, massively improving performance.
-Disadvantage of temporal reproject is update latency so..
-Made sure a gaussian filter runs in XY after fog, this allows to keep stability and lower latency.
2021-02-06 15:08:21 -03:00
reduz 7997544af5 Added temporal reprojection to Volumetric Fog
-It's an option, just enable it
-Just works, don't have to do anything else.
2021-02-05 10:52:54 -03:00
Rémi Verschelde 2ba66c1457
Merge pull request #45672 from reduz/barrier-optimization
Rewrote how barriers work for faster rendering
2021-02-04 17:19:35 +01:00
Rémi Verschelde 69152af45d doc: Don't bind argument names with p_ prefix
This prefix is used in the C++ codebase, not in the scripting API.
2021-02-04 14:45:06 +01:00
George Marques 3f4d60616e
Make SyntaxHighligher::_clear_highlighting_cache virtual
Since it's meant to be used as a virtual method.
2021-02-04 09:54:09 -03:00
reduz f20999f6fe Rewrote how barriers work for faster rendering
-Added more finegrained control in RenderingDevice API
-Optimized barriers (use less ones for thee same)
-General optimizations
-Shadows render all together unbarriered
-GI can render together with shadows.
-SDFGI can render together with depth-preoass.
-General fixes
-Added GPU detection
2021-02-04 09:42:28 -03:00
George Marques bcf1617755
Removed duplicated binding of two methods
They are bound as both regular and virtual methods which makes ClassDB
report the methods twice when querying the API. The non-virtual binding
is removed since both methods only seem to be used as virtual.
2021-02-04 09:30:41 -03:00
Rémi Verschelde 7185a7c3c2
Merge pull request #45496 from Chaosus/fix_particles
Fix particles not properly updated by their lifetime
2021-02-03 15:50:52 +01:00
clayjohn 814b41fef1 Add check for sun in PhysicalSky 2021-02-02 23:06:42 -08:00
Rémi Verschelde b24c24f64b
Merge pull request #45594 from JFonS/improve_3d_grid
3D editor grid improvements
2021-02-01 23:18:24 +01:00
jfons 73e62dffb9 3D editor grid improvements
This commit adds a view-dependant fade to the 3D viewport grid. It fades out
at steep view angles to hide the solid regions that appear far from the camera.
I also included a fade to hide the grid borders.

I added some improvements to the dynamic grid when the camera is in orthogonal mode.
It properly handles zoom now, and the grid center is now set to the intersection point
between the grid plane and the camera forward ray, keeping the grid
always visible.
2021-02-01 22:19:54 +01:00
Rémi Verschelde d2e1216504
Merge pull request #37547 from aaronfranke/tau
Use Math_TAU and deg2rad/etc in more places and optimize code
2021-02-01 20:55:25 +01:00
Rémi Verschelde d811f86102
Merge pull request #45281 from Chaosus/vs_unify
Unified several visual shader nodes
2021-02-01 08:56:03 +01:00
Rémi Verschelde fb01d057af
doc: Sync classref with current source 2021-01-28 11:26:37 +01:00
Yuri Roubinsky aefce8000d Fix particles not properly modified by their lifetime 2021-01-27 16:28:15 +03:00
Yuri Roubinsky 64971bcc8a Added missed Button font_hover_pressed_color style 2021-01-27 10:44:53 +03:00
Yuri Roubinsky 6d82898470 Reveals Button "icon_color" style properties to the user 2021-01-26 22:05:59 +03:00
Rémi Verschelde 6cba658934
Merge pull request #44194 from madmiraal/fix-font_selected_color
Change themes font_color_selected to font_selected_color
2021-01-26 00:03:40 +01:00
Rémi Verschelde d7aea6ff6c
Merge pull request #45447 from pycbouh/graphedit-minimap-active-invisible
Fix minimap capturing events and improve its theme and editor settings
2021-01-25 20:32:46 +01:00
Yuri Sizov 9d9d0f0bc9 Fix minimap capturing events and improve its theme
Add an editor setting for minimap opacity in visual editors
2021-01-25 21:49:07 +03:00
reduz 51d8e32c93 Implement shadow meshes
-When importing, a vertex-only version of the mesh is created.
-This version is used when rendering shadows, and improves performance by reducing bandwidth
-It's automatic, but can optionally be used by users, in case they want to make special versions of geometry for shadow casting.
2021-01-25 15:03:15 -03:00
Marcel Admiraal 8eb39f4e8b Change themes *_color_* to *_*_color
Changed:
font_color_accel -> font_accelerator_color
font_color_bg -> font_unselected_color
font_color_disabled -> font_disabled_color
font_color_fg -> font_selected_color
font_color_hover -> font_hover_color
font_color_hover_pressed -> font_hover_pressed_color
font_color_pressed -> font_pressed_color
font_color_readonly -> font_readonly_color
font_color_selected -> font_selected_color
font_color_shadow -> font_shadow_color
font_color_uneditable -> font_uneditable_color
icon_color_disabled -> icon_disabled_color
icon_color_hover -> icon_hover_color
icon_color_hover_pressed -> icon_hover_pressed_color
icon_color_normal -> icon_normal_color
icon_color_pressed -> icon_pressed_color

Also includes:
font_outline_modulate -> font_outline_color
tab_fg -> tab_selected
tab_bg -> tab_unselected
2021-01-24 06:28:49 +00:00
Rémi Verschelde d39f6386ce
Merge pull request #45314 from RandomShaper/modernize_rwlock
Modernize RWLock
2021-01-22 14:51:05 +01:00
Rémi Verschelde 76c6007aa6
Cleanup: Remove executable bit from files which don't need it
Drop unused xpmfix.sh script.
2021-01-19 23:36:42 +01:00
Pedro J. Estébanez 8ed259b792 Modernize RWLock
- Based on C++14's `shared_time_mutex`
- No more need to allocate-deallocate or check for null
- No pointer anymore, just a member variable
- Platform-specific implementations no longer needed
- Simpler for `NO_THREADS`
2021-01-19 11:53:10 +01:00
Yuri Roubinsky 4618e09f3b
Added SDF nodes to visual shader 2021-01-18 15:04:54 +01:00
Yuri Roubinsky de5a8128d7 Unified several visual shader nodes 2021-01-18 13:32:12 +03:00
Hugo Locurcio 1f9cac1717
Fix typo in theming methods ("botton" -> "bottom") 2021-01-18 04:19:07 +01:00
Yuri Roubinsky 4a85f4cafe Fix replaced visual shader nodes updating 2021-01-15 21:10:32 +03:00
Rémi Verschelde c7fb7674c8
Merge pull request #44805 from Chaosus/vs_convert
Add convert options between constants and uniforms in visual shaders
2021-01-15 16:58:26 +01:00
Yuri Roubinsky ef941a6500 Renamed emit_particle to emit_subparticle shader function 2021-01-12 09:41:08 +03:00
K. S. Ernest (iFire) Lee 59b61a1f64 Scale error in mesh optimizer so it uses absolute scale.
Switch to simplify sloppy for another try.

Update to meshoptimizer e3f53f66e7a35b9b8764bee478589d79e34fa698.
2021-01-11 06:07:54 -08:00
Aaron Franke 1d5042c9e2
Use Math_TAU and deg2rad/rad2deg in more places and optimize code 2021-01-09 03:47:14 -05:00
reduz cdb216f4e4 Added ability to visualize native shaders 2021-01-06 09:40:09 -03:00
Rémi Verschelde b5334d14f7
Update copyright statements to 2021
Happy new year to the wonderful Godot community!

2020 has been a tough year for most of us personally, but a good year for
Godot development nonetheless with a huge amount of work done towards Godot
4.0 and great improvements backported to the long-lived 3.2 branch.

We've had close to 400 contributors to engine code this year, authoring near
7,000 commit! (And that's only for the `master` branch and for the engine code,
there's a lot more when counting docs, demos and other first-party repos.)

Here's to a great year 2021 for all Godot users 🎆
2021-01-01 20:19:21 +01:00
Yuri Roubinsky c98c6eadbe Add convert options between constants and uniforms in visual shaders 2020-12-30 13:07:08 +03:00
Rémi Verschelde 848f5ba05c
Merge pull request #44762 from KoBeWi/offset_is_now_point_not_offset_point
Rename offset to point in remove_point()
2020-12-29 13:37:49 +01:00
Rémi Verschelde 2086acfacc
Merge pull request #44614 from madmiraal/rename-normalmap-normal_map
Consistently use normal_map
2020-12-29 10:39:56 +01:00
Rémi Verschelde 09212fba1e
Fix missed renamings from empty() to is_empty()
Those were missed in #44401 or added by later PRs.
2020-12-29 09:55:07 +01:00
Rémi Verschelde 652bdd573e
Merge pull request #43691 from bruvzg/ctl_dropcap
[Complex Text Layouts] Add drop-cap support to RTL.
2020-12-29 09:14:46 +01:00
Marcel Admiraal b4a190e0bc Consistently use normal_map 2020-12-29 08:04:19 +00:00
kobewi 4f72a07eaa Rename offset to point in remove_point() 2020-12-28 17:57:55 +01:00
Rémi Verschelde 4ca98c7a35
Merge pull request #44183 from madmiraal/box_shape-size
Use a size Vector for adjusting the size of Rectangles and Boxes
2020-12-28 16:06:50 +01:00
Rémi Verschelde 058f3fe069
Merge pull request #44149 from madmiraal/rename-tangent-orthogonal
Rename Vector2.tangent() to Vector2.orthogonal()
2020-12-28 16:00:12 +01:00
Marcel Admiraal b628912af0 Rename Rect2 and Rect2i grow_margin() to grow_side() 2020-12-28 12:47:33 +00:00
Marcel Admiraal 5b937d493f Rename empty() to is_empty() 2020-12-28 10:39:56 +00:00
Marcel Admiraal 4b8b803931 Rename Control margin to offset 2020-12-23 06:25:56 +00:00
clayjohn 44f8922305 Port ASSAO to Godot to replace SAO 2020-12-21 23:08:59 -08:00
Pedro J. Estébanez b7367ac426 Add animation reset track feature
As a bonus, to have consistency between use Beziers and create insert tracks, use Beziers also gets a default via editor settings that is used when the confirmation dialog is disabled, instead of just falling back to creating non-Bezier tracks.
2020-12-20 12:45:08 +01:00
Marcel Admiraal 2df9a8ccad Rename Rect2 and Rect2i clip() to intersection() 2020-12-19 12:59:08 +00:00
reduz d2302f53d6 Implement automatic LOD (Level of Detail)
-Happens on import by default for all models
-Just works (tm)
-Biasing can be later adjusted per node or per viewport (as well as globally)
-Disabled AABB.get_support test because its broken
2020-12-18 15:48:03 +01:00
Rémi Verschelde 771b99b7f4
Merge pull request #44495 from godotengine/font-typo-44494
Font: Fix typo in DynamicFontData compat code
2020-12-18 14:08:15 +01:00
Rémi Verschelde a5c47dab5b
Font: Fix typo in DynamicFontData compat code
Fixes #44494.
2020-12-18 12:59:52 +01:00
Rémi Verschelde c7b53c03ae
SCons: Add explicit dependencies on thirdparty code in cloned env
Since we clone the environments to build thirdparty code, we don't get an
explicit dependency on the build objects produced by that environment.

So when we update thirdparty code, Godot code using it is not necessarily
rebuilt (I think it is for changed headers, but not for changed .c/.cpp files),
which can lead to an invalid compilation output (linking old Godot .o files
with a newer, potentially ABI breaking version of thirdparty code).

This was only seen as really problematic with bullet updates (leading to
crashes when rebuilding Godot after a bullet update without cleaning .o files),
but it's safer to fix it everywhere, even if it's a LOT of hacky boilerplate.
2020-12-18 10:29:34 +01:00
Rémi Verschelde c83d1b2526
Merge pull request #43416 from pycbouh/graph-minimap
Add a minimap to the GraphEdit
2020-12-17 17:34:36 +01:00
Yuri Sizov 8d608cdc40 Remove unused argument in Theme method and expose missing methods 2020-12-17 15:51:08 +03:00
reduz bf77016c8a Reimplement skeletons and blend shapes
Uses compute shaders, which only once, on demand, and all in parallel.
2020-12-16 14:32:04 -03:00
Marcel Admiraal f5a3cbda19 Rename Animation::track_remove_key_at_position to track_remove_key_at_time 2020-12-14 18:00:11 +00:00
reduz 77a045e902 Rework Mesh handling on scene importing.
-Reworked how meshes are treated by importer by using EditorSceneImporterMesh and EditorSceneImporterMeshNode. Instead of Mesh and MeshInstance, this allows more efficient processing of meshes before they are actually registered in the RenderingServer.
-Integrated MeshOptimizer
-Reworked internals of SurfaceTool to use arrays, making it more performant and easy to run optimizatons on.
2020-12-13 21:29:51 -03:00
bruvzg 62927383ed
[Complex Text Layouts] Add drop-caps support to TextParagraph and RTL. 2020-12-13 22:20:02 +02:00
bruvzg c1d261fdb0
[Complex Text Layouts] Add variable fonts support. 2020-12-13 18:43:39 +02:00
bruvzg 6b6f101983
[Complex Text Layouts] Refactor RichTextLabel. 2020-12-11 09:48:49 +02:00
Rémi Verschelde 67259d07db
Merge pull request #44070 from YeldhamDev/popupmenu_separator_font_color
Add "font_color_separator" theme property to 'PopupMenu'
2020-12-10 11:13:07 +01:00
Rémi Verschelde 114f97ff11
Merge pull request #44128 from KoBeWi/🧹
Cleanup unused engine code
2020-12-09 13:01:50 +01:00
Tomasz Chabora 2c048ea164 Cleanup unused engine code 2020-12-09 12:12:36 +01:00
Rémi Verschelde 92c001ef09
Merge pull request #43931 from bruvzg/ctl_comp_font
[Complex Text Layouts] Add compatibility for legacy Font resources.
2020-12-09 11:28:11 +01:00
Rémi Verschelde 0c5d3b838c
Merge pull request #44199 from bruvzg/pvs_fixes_1
PVS-Studio static analyzer fixes
2020-12-09 10:23:21 +01:00
bruvzg 644f739660
Static analyzer fixes:
Removes unused code in OS.
Fixes return types.
Fixes few typos.
2020-12-09 10:17:53 +02:00
Hugo Locurcio 88f70b0c05
Increase dithering in the PhysicalSkyMaterial shader to combat banding
Banding should now be much less visible when using the default
PhysicalSkyMaterial settings.
2020-12-09 01:40:58 +01:00
Marcel Admiraal 43c9106806 Use box size instead of extents for Shape dimensions 2020-12-08 11:58:21 +00:00
Marcel Admiraal d5d99aaed6 Use rectangle size instead of extents for Shape dimensions 2020-12-08 11:57:46 +00:00
bruvzg a458e90179
[Complex Text Layouts] Adds missing Font::SPACING_* to the Label, LineEdit, TextEdit, TextLine and TextParagraph.
Fixes oversized editor control height (default editor spacing is negative) and control size changing when text is set.
2020-12-06 20:30:59 +02:00
Marcel Admiraal a24c38d1a8 Rename Vector2.tangent() to Vector2.orthogonal() 2020-12-06 18:16:06 +00:00
Hugo Locurcio 44d0c74768
Tweak BaseMaterial3D heightmap property hints
- Allow finer adjustments of the heightmap scale.
- Allow increasing the heightmap level detail (at the cost of performance).
2020-12-05 21:43:32 +01:00
Rémi Verschelde c574b4d086
Merge pull request #44091 from madmiraal/rename-cubemesh-boxmesh
Rename CubeMesh to BoxMesh
2020-12-05 16:48:15 +01:00
Marcel Admiraal df6b061dbb Rename CubeMesh BoxMesh 2020-12-05 11:48:26 +00:00
Aaron Franke 40b81339d0
Rebind Mesh/ArrayMesh enums 2020-12-04 19:34:50 -05:00
Aaron Franke 47f8ac7864
Rename Particles/ParticlesMaterial "Flags" enum to "ParticleFlags"
"Flags" was a bit too ambiguous, and in 3D it hid GeometryInstance.Flags
2020-12-04 19:34:29 -05:00
Rémi Verschelde 1a001ad964
doc: Sync classref with current source
And fixups:
- Add missing bindings in RenderingServer
- Remove duplicate ArrayMesh enum bindings (they're in Mesh already)
- Remove redundant _unhandled_key_input binding in Control (it's in Node
  already)
2020-12-04 22:28:08 +01:00
Michael Alexsander 383e8919e0 Add "font_color_separator" theme property to 'PopupMenu' 2020-12-03 11:36:03 -03:00
bruvzg 3c3590522f
[Complex Text Layouts] Add compatibility for legacy Font resources. 2020-12-03 10:34:03 +02:00
reduz 70f5972905 Refactored Mesh internals and formats.
-Changed how mesh data is organized, hoping to make it more efficient on Vulkan and GLES.
-Removed compression, it now always uses the most efficient format.
-Added support for custom arrays (up to 8 custom formats)
-Added support for 8 weights in skeleton data.
-Added a simple optional versioning system for imported assets, to reimport if binary is newer
-Fixes #43979 (I needed to test)

WARNING:

-NOT backwards compatible with previous 4.x-devel, will most likely never be, but it will force reimport scenes due to version change.
-NOT backwards compatible with 3.x scenes, this will be eventually re-added.
-Skeletons not working any longer, will fix in next PR.
2020-12-02 13:07:59 -03:00
Yuri Roubinsky dd32d7b7ee Fixed some errors when changing port name in visual shader expressions 2020-12-02 13:27:37 +03:00
Yuri Roubinsky b74f1abd25 Fix few bugs in visual shader expressions
Fixed few bugs in visual shader expressions
2020-12-01 16:55:52 +03:00
Yuri Sizov 999ce610a2 Add a minimap to the GraphEdit 2020-11-30 16:48:52 +03:00
Yuri Roubinsky 82d64ebd19 Fixed several visual shader inputs
Fixed several inputs in visual shaders
2020-11-29 16:10:05 +03:00
Rémi Verschelde ef2d1f6d19
Merge pull request #42761 from fire/color-grading-3d
Environment brightness, contrast, saturation restore with 3d LUT.
2020-11-28 23:07:52 +01:00
Yuri Roubinsky 07e752585c Fixed invalid visual shader outputs (TRANSMISSION, ALPHA_SCISSOR) 2020-11-28 20:42:59 +03:00
clayjohn 076908bed9 Environment brightness, contrast, saturation restore with color correction.
Allow gradients and 2d images.

Use shader versions for LUT in tonemap

Co-authored-by: alex-poe <3957610+CptPotato@users.noreply.github.com>
Co-authored-by: QbieShay <cislaghi.ilaria@gmail.com>
Co-authored-by: Clay John <claynjohn@gmail.com>
2020-11-28 07:37:49 -08:00
Rémi Verschelde a6751e6c58
Merge pull request #41100 from bruvzg/ctl_text_server_interface
[Complex Text Layouts] Implement TextServer interface.
2020-11-28 09:03:15 +01:00
Rémi Verschelde 43f60c94e8
Merge pull request #39056 from rileylyman/tscn_newlines
Skip extra newline in .tscn when renaming dependency
2020-11-27 15:35:15 +01:00
bruvzg 99666de00f
[Complex Text Layouts] Refactor Font class, default themes and controls to use Text Server interface.
Implement interface mirroring.
Add TextLine and TextParagraph classes.
Handle UTF-16 input on macOS and Windows.
2020-11-26 14:25:48 +02:00
Yuri Roubinsky 3e1e01b7ab Added extra warning to VisualShaderNodeTexture + fix warning appearing 2020-11-26 14:53:47 +03:00
Andrii Doroshenko (Xrayez) 0ee88d6705 Describe ImageTexture, Image creation and usage 2020-11-17 16:00:41 +02:00
Rémi Verschelde 99d0df2e33
Merge pull request #38812 from aaronfranke/brace-no-empty-line
Remove all empty lines from the start of blocks defined with braces
2020-11-17 08:59:50 +01:00
Rémi Verschelde 9de18cc946
Merge pull request #43547 from TokageItLab/lowering-s3d-and-camera-min-unit
Lowering the Minimum Unit at Shape3D and Cameras
2020-11-17 07:55:44 +01:00
Aaron Franke 02161aad5a
Remove empty lines around braces with the formatting script 2020-11-16 23:38:11 -05:00
Tokage 4a2aaabf9f Lowering the Minimum Unit at Shape3D and Cameras 2020-11-17 13:17:37 +09:00
Rémi Verschelde d105c718fd
Merge pull request #43316 from YeldhamDev/rate_scale_wav_fix
Fix WAV resources ignoring the AudioServer's 'global_rate_scale' value
2020-11-16 15:52:48 +01:00
Rémi Verschelde fc70f986b9
Merge pull request #42008 from Calinou/theme-rename-node-type
Rename the `type` parameter to `node_type` in Theme and Control
2020-11-16 13:20:24 +01:00
Nick Swoboda bf8f763524 Improve error messages related to failing to open files 2020-11-12 17:30:56 -08:00
Rémi Verschelde 9d2e8f2f27
Variant: Rename Type::_RID to Type::RID
The underscore prefix was used to avoid the conflict between the `RID` class
name and the matching enum value in `Variant::Type`.

This can be fixed differently by prefixing uses of the `RID` class in `Variant`
with the scope resolution operator, as done already for `AABB`.
2020-11-09 16:29:04 +01:00
reduz 127458ed17 Reorganized core/ directory, it was too fatty already
-Removed FuncRef, since Callable makes it obsolete
-Removed int_types.h as its obsolete in c++11+
-Changed color names code
2020-11-07 20:17:12 -03:00
bruvzg 061f65e410
Fix uninitialised variables in the BaseMaterial3D. 2020-11-06 10:17:11 +02:00
Michael Alexsander 04ebe4e7a4 Fix WAV resources ignoring the AudioServer's 'global_rate_scale' value 2020-11-04 17:03:54 -03:00
Marios Staikopoulos e5d7c7d5fc Alpha Hash and Alpha2Coverage Implementation 2020-11-02 20:11:20 -08:00
Juan Linietsky a65481dd35
Update scene/resources/dynamic_font.cpp
Co-authored-by: Hugo Locurcio <hugo.locurcio@hugo.pro>
2020-10-28 22:09:37 -03:00
reduz 8ab9b39707 Implement CanvasGroup and CanvasItem clipping
-Allows merging several 2D objects into a single draw operation
-Use current node to clip children nodes
-Further fixes to Vulkan barriers
-Changed font texture generation to white, fixes dark eges when blurred
-Other small misc fixes to backbuffer code.
2020-10-28 18:53:32 -03:00
Hugo Locurcio c3b246e6af
Rename the type parameter to node_type in Theme and Control
This makes it clearer that it expects a node type as a string
(such as "Label") instead of a type like "TYPE_ARRAY".
This is backwards-compatible since only the name of the parameter
is changed, not its order.
2020-10-27 14:58:52 +01:00
Luke Costello 65eb02b236 Visual Shader Parenthesis fix
missing parenthesis were added to prevent conditional statement from interacting with operations
2020-10-27 03:20:29 -04:00
Rémi Verschelde 8ee44cc60c
Merge pull request #43075 from Xrayez/color-ramp-to-gradient
Fixup `ColorRamp` to `Gradient` renames
2020-10-26 08:44:27 +01:00
Andrii Doroshenko (Xrayez) 8ce2f401dd Fixup ColorRamp to Gradient renames 2020-10-25 18:32:44 +02:00
reduz 84d734da0e Refactored 2D shader and lighting system
-Removed normal/specular properties from nodes
-Create CanvasTexture, which can contain normal/specular channels
-Refactored, optimized and simplified 2D shaders
-Use atlas for light textures.
-Use a shadow atlas for shadow textures.
-Use both items aboves to make light rendering stateless (faster).
-Reorganized uniform sets for more efficiency.
2020-10-24 15:57:25 -03:00
Rémi Verschelde 6b20859984
Merge pull request #42558 from Chaosus/vs_curve
Added visual shader node to easy gather data from a CurveTexture
2020-10-19 14:58:45 +02:00
Juan Linietsky 53d5a252bb
Revert "Replace SAO implementation with MSSAO" 2020-10-18 19:27:51 -03:00