Age | Commit message (Collapse) | Author |
|
C#: Optimize Variant conversion callbacks
|
|
Update embree to 3.13.5
|
|
|
|
Fix GLAD-related build problems on Linux
|
|
C#: Load assemblies as collectible only in the Godot editor
|
|
These callbacks are used for marshaling by callables and generic Godot
collections.
C# generics don't support specialization the way C++ templates do.
I knew NativeAOT could optimize away many type checks when the types
are known at compile time, but I didn't trust the JIT would do as good
a job, so I initially went with cached function pointers.
Well, it turns out the JIT is also very good at optimizing in this
scenario, so I'm changing the methods to do the conversion directly,
rather than returning a function pointer for the conversion.
The methods were moved to `VariantUtils`, and were renamed from
`GetFromVariantCallback/GetToVariantCallback` to `ConvertTo/CreateFrom`.
The new implementation looks like it goes through many `if` checks
at runtime to find the right branch for the type, but in practice it
works pretty much like template specialization. The JIT only generates
code for the relevant branch. Together with inlining, the result is
very close or the same as doing the conversion manually:
```cs
godot_variant variant;
int foo = variant.Int;
int bar = VariantUtils.ConvertTo<int>(variant);
```
If the type is a generic Godot collection, the conversion still goes
through a function pointer call.
The new code happens to be much shorter as well, with the file going
from 1057 lines to 407.
Side note: `Variant.cs` was mistakenly created in the wrong folder,
so I moved it to the `Core` folder.
|
|
- Use gl.h provided by GLAD in the OpenXR module
- Use non-EXT variants of some OpenGL defines
- Remove libGL-related code paths
|
|
- Add documentation to Projection type
- Reorder Projection members to be consistent with other C# types
|
|
GDScript: Properly respect `int` type hint for `@export_range`
|
|
Fixes #69104.
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
|
|
|
|
Cleanup remaining EditorUndoRedoManager usages
|
|
|
|
C#: Implement BezierDerivative
|
|
Refactor interpolating functions in some classes to use `Math` class
|
|
Cache materials in gltf as the abstract class of Material in GLTFDocument
|
|
Use the abstract material class instead of BaseMaterial3D. This allows inserting ShaderMaterials into gltf. Like in VRM.
|
|
Adds `BezierDerivative` method to Mathf, Vector2 and Vector3 (already exposed in Core).
|
|
|
|
|
|
Partial support for Pico 4
|
|
ImageLoaderSVG: Improve error reporting
|
|
Fix parameters that are considered as constants
|
|
First attempt at fully qualifying the default values of C# properties.
|
|
|
|
|
|
Add unregister for `GLTFDocumentExtension`
|
|
This avoids issues when the default values rely on using
namespaces.
|
|
|
|
Expose string array properties in OpenXR module as PackedStringArray
|
|
Fill random docs
|
|
|
|
This happens too often with normal usage of the API.
The warning can still be useful to find actual bugs where discarding the return
value wasn't intentional, but this should stay enabled manually, at least until
we either improve the API to remove false positives, or improve the warning (e.g.
to only warn about unused return value on const functions).
|
|
fix typo in ZIPReader doc
|
|
Fix using signals in lambda functions
|
|
|
|
adamscott/fix-godot#61386-autoload-scenes-implicit-types
Fix autoload scenes implicit types
|
|
Fetch cached scene if it exists in `GDScriptCache::get_packed_scene()`
|
|
Clarify what happens when return value is discarded in GDScript warning text
|
|
|
|
changed RETURN_VALUE_DISCARDED GDscript warning text to mention how the return value of a function is discarded; update GDScript parser warning test to include new warning text.
|
|
|
|
|
|
|
|
[TextServer] Fix line breaking for the special fonts that substitute a long string (with breaks opportunities in it) with a single glyph.
|
|
Code simplifications found by cppcheck
|
|
Add GLTFDocument documentation.
|
|
They are based on:
- Boolean arithmetic simplifications
- setting variables that are not accessed
- constant variables
|
|
string (with breaks opportunities in it) with a single glyph.
|
|
Co-authored-by: Meow <mosesturner@protonmail.com>
Co-authored-by: Aaron Franke <arnfranke@yahoo.com>
|