Commit Graph

116 Commits

Author SHA1 Message Date
smix8 66a8418a2d Remove unnecessary Clipper lib includes
Removes unnecessary Clipper lib includes.
2023-05-24 23:57:08 +02:00
bruvzg 9163d8c336
Expose TextServer justification flags to Label, Label3D, TextMesh and RTL. Add flags to control last/single line justification. 2023-05-15 19:23:54 +03:00
Rémi Verschelde a90bbc3544
Merge pull request #72225 from MinusKube/shaped_text_invalidated_bug
Mark dirty flags when shaped texts are invalidated
2023-02-13 09:13:27 +01:00
Hugo Locurcio dc06575475
Add a property hint for PrimitiveMesh's `uv2_padding`
Negative values are not valid and will always cause lightmap bleeding
to occur.

This also improves the documentation for the `uv2_padding` property
in the class reference.
2023-02-02 14:55:51 +01:00
MinusKube ba472bd29c Use correct prefix for TextMesh width property 2023-01-28 04:09:10 +01:00
MinusKube d59c221404 Mark dirty flags when shaped texts are invalidated 2023-01-28 03:31:55 +01:00
bruvzg 5361ec9f43
Implement BiDi override mode for GDScript source. 2023-01-18 19:22:20 +02:00
Juan Linietsky 47592927b3 Use BitField<> hint for ArrayFormat
This was missing in the conversion of bitflags to BitField<>.
2023-01-08 18:47:48 +01:00
Rémi Verschelde d95794ec8a
One Copyright Update to rule them all
As many open source projects have started doing it, we're removing the
current year from the copyright notice, so that we don't need to bump
it every year.

It seems like only the first year of publication is technically
relevant for copyright notices, and even that seems to be something
that many companies stopped listing altogether (in a version controlled
codebase, the commits are a much better source of date of publication
than a hardcoded copyright statement).

We also now list Godot Engine contributors first as we're collectively
the current maintainers of the project, and we clarify that the
"exclusive" copyright of the co-founders covers the timespan before
opensourcing (their further contributions are included as part of Godot
Engine contributors).

Also fixed "cf." Frenchism - it's meant as "refer to / see".
2023-01-05 13:25:55 +01:00
Adam Scott ea33001b95 Add safety-checks before some servers `free()` 2022-12-29 16:23:38 -05:00
Hugo Locurcio 6e330e8a75
Add properties to disable top/bottom cap generation in TubeTrailMesh
This can be used to improve generation and rendering performance,
or for certain special effects such as particle trails.
2022-12-19 17:29:32 +01:00
Silc Renew b217c41d36 Refactor interpolating functions in some classes to use Math class 2022-11-24 20:31:43 +09:00
Rémi Verschelde 315c64282b
Fix misc formatting issues
Somehow I missed the failing CI report from trailing whitespace.

Fixed a couple typos found by codespell while at it, and misc
trailing semicolons in one of the files.
2022-11-14 19:00:48 +01:00
Bastiaan Olij 7658dc6e7e Add optional UV2 logic for lightmapping to primitive shapes 2022-11-13 19:28:10 +11:00
Rémi Verschelde 9eb8eb5f7d Merge pull request #67336 from jbcolli2/Normal-of-CylinderMesh
Fix bug in CylinderMesh when computing normals
2022-10-13 15:24:55 +02:00
jbcolli2 491ec622f6 Changed normal of CylinderMesh to account for slanted side. 2022-10-13 08:24:31 -04:00
Haoyu Qiu 344ed9ec6c Remove leading spaces from enumerator name hints
For `PROPERTY_HINT_ENUM` properties, enumerator names can be provided as
a comma separated list. There're a few properties that add leading
spaces to the names (e.g. `First, Second, Third`).

These spaces are included in the Inspector dropdown, which is
unexpected.

It's better to leave the surrounding spaces untouched because it could
be part of the resulting string value (the variable is a string enum).
And most other enum hints don't contain surrounding whitespaces.

This PR removes the spaces and documents this `PROPERTY_HINT_ENUM`
behavior.
2022-10-08 11:33:50 +08:00
bruvzg 0103af1ddd
Fix MSVC warnings, rename shadowed variables, fix uninitialized values, change warnings=all to use /W4. 2022-10-07 11:32:33 +03:00
Micky b6daad8d4b Rename `range_lerp` to `remap` 2022-09-06 07:19:20 +02:00
Hugo Locurcio ae18928748
Rename Curve/Curve2D/Curve3D/Gradient `interpolate()` to `sample()`
"sampling" is a more accurate term than "interpolating" for what's
happening when using that function.
2022-08-30 22:08:38 +02:00
Yuri Sizov 6320a0fc18 Add ThemeDB, expose previously static Theme methods 2022-08-26 19:23:05 +03:00
Rémi Verschelde 354123a207
Merge pull request #64243 from bruvzg/multiline_textmesh 2022-08-26 11:45:25 +02:00
Rémi Verschelde a0113a98e4
Merge pull request #64801 from clayjohn/plane-quad
Remove QuadMesh and add orientation parameter to PlaneMesh
2022-08-25 07:38:30 +02:00
clayjohn 861c5bff0e Remove QuadMesh and add orientation parameter to PlaneMesh 2022-08-24 18:51:18 -07:00
kobewi 1abdffe7a0 Replace Array return types with TypedArray 2 2022-08-23 23:21:32 +02:00
bruvzg 8384815365
Add line breaking support to the TextMesh. 2022-08-10 23:53:48 +03:00
hoontee 21b9b117be Add `TorusMesh` 2022-08-04 13:45:54 -05:00
bruvzg 344ba0ffaf
Refactor Font configuration and import UI, and Font resources. 2022-07-06 14:12:36 +03:00
bruvzg 329923c6ac
Use custom key structs, instead of raw hashes for the Label3D and TextMesh, to avoid potential hash collisions. 2022-07-04 09:47:49 +03:00
tefusion ad7b3549a5 Fix CapsuleMesh loading issue (radius reset) 2022-06-22 17:34:49 +02:00
reduz 141c375581 Clean up Hash Functions
Clean up and do fixes to hash functions and newly introduced murmur3 hashes in #61934
* Clean up usage of murmur3
* Fixed usages of binary murmur3 on floats (this is invalid)
* Changed DJB2 to use xor (which seems to be better)
2022-06-20 12:54:19 +02:00
FireForge 4678736a39 Add suffixes to all nodes and resources 2022-06-11 09:41:05 -05:00
Rémi Verschelde cc21892fa4
Merge pull request #61355 from bruvzg/text_mesh_fix_fill_align
[TextMesh] Fix incorrectly applied FILL alignment.
2022-05-25 01:16:42 +02:00
Hugo Locurcio ce7099a35a
Tweak TextMesh decomposition error message to mention self-intersecting lines 2022-05-24 15:11:39 +02:00
bruvzg 826de9da48
[TextMesh] Fix incorrectly applied FILL alignment. 2022-05-24 11:58:54 +03:00
Rémi Verschelde 56dbfcdcba
Merge pull request #61203 from Calinou/cylindermesh-add-cap-properties
Add properties to disable top/bottom cap generation in CylinderMesh
2022-05-24 08:21:01 +02:00
Rémi Verschelde 9923851370 Fix typos with codespell
Using codespell 2.2-dev from current git.
2022-05-23 21:32:19 +02:00
bruvzg 4e86c13557
[TextMesh] Do not generate meshes for non-visual glyphs. 2022-05-23 20:06:36 +03:00
bruvzg 1f066837e4
[TextMesh] Fix cubic cubic Bezier arc processing. 2022-05-22 18:04:32 +03:00
Hugo Locurcio d23071cae3
Add properties to disable top/bottom cap generation in CylinderMesh 2022-05-21 02:06:53 +02:00
Aaron Franke 5dc3bfb80e
Use suffixes for units in nodes and resources 2022-05-19 14:34:27 -05:00
bruvzg 05963674a7
Implement TextMesh resource.
Apply simulated slant and embolden to the TextServer `gont_get_glyph_contours` results.
2022-05-13 08:20:22 +03:00
Rémi Verschelde f75afaa085
Merge pull request #58777 from Sauermann/fix-capsulemesh-tangent
Reverse tangents of capsule mesh
2022-05-03 08:18:48 +02:00
Pawel Lampe fcd26b8841 Fix navmesh baking
- improved mesh data calculation from standalone static colliders so that no
  VisualServer calls are performed - and thus no VS mutexes need to
  be locked in case of on-thread baking
- improved the same for GridMap's static colliders
2022-04-08 21:01:59 +02:00
reduz 6f51eca1e3 Discern between virtual and abstract class bindings
* Previous "virtual" classes (which can't be instantiated) are not corretly named "abstract".
* Added a new "virtual" category for classes, they can't be instantiated from the editor, but can be inherited from script and extensions.
* Converted a large amount of classes from "abstract" to "virtual" where it makes sense.

Most classes that make sense have been converted. Missing:

* Physics servers
* VideoStream
* Script* classes.

which will go in a separate PR due to the complexity involved.
2022-03-10 12:28:11 +01:00
Markus Sauermann c2e9b0c566 Reverse tangents of capsule mesh 2022-03-05 09:23:59 +01:00
Rémi Verschelde fe52458154
Update copyright statements to 2022
Happy new year to the wonderful Godot community!
2022-01-03 21:27:34 +01:00
Duarte David 7d53755ca7 Fixes the normals of SphereMesh when the radius is different from 1 2021-09-28 00:09:39 +01:00
Brian Semrau 62f8b0eb91 QuadMesh remove format ARRAY_FORMAT_INDEX 2021-09-27 13:10:34 -04:00
Duarte David f4ac08a182 Fixes the normals of SphereMesh when the sphere/hemisphere is oblong 2021-08-22 21:45:39 +01:00