Commit Graph

352 Commits

Author SHA1 Message Date
46ef52162e Color: Rename to_srgb/to_linear to include base color space
This helps reduce confusion around sRGB <> Linear conversions by making
both input and output color spaces explicit.
2022-04-13 11:45:52 +02:00
0ea7780e33 move gltf export under scene menu 2022-04-12 19:42:41 +05:30
4ab86c6731 Merge pull request #59980 from reduz/animation-libraries 2022-04-11 14:18:35 +02:00
6f401439f8 Implement Animation Libraries
* Instead of containing single animations, AnimationPlayer now contains libraries.
* Libraries, in turn, contain the animations.

This paves the way for implementing the possibility of importing scenes as animation libraries, finally allowing to import animations separate from the 3D models.

Missing (will be done on separate PRs):

* Make it possible to import scenes (dae/fbx/gltf) as animation libraries.
* Make it possible for AnimationTree to import animation libraries on its own, so it does not rely on AnimationPlayer for everything.
2022-04-11 12:51:54 +02:00
9381acb6a4 Make FileAccess and DirAccess classes reference counted. 2022-04-11 13:28:51 +03:00
d4b54e35f9 Fix path handling in FBX and Blend importers
Fixes #59996.
2022-04-07 23:33:28 +02:00
277825e956 Initialize pointer variables to fix random crash on startup.
`configure_blender_dialog` is lazily created if equal to null,
however nothing really sets it to null.
2022-04-03 23:21:29 +01:00
4263f02f28 Merge pull request #59764 from reduz/blender-import-autodetect 2022-04-01 11:42:05 +02:00
e32215fbad Add Blender install autodetection and configuration.
This PR is a continuation to #54886

* Changed Blender path editor setting from binary to installation.
* Add a class to query whether the format is supported.
* This class allows to create proper editors to configure support.

**NOTE**: This PR only provides autodetection on Linux. Code needs to be added for Windows and MacOS to autodetect the Blender installation.

Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
Co-authored-by: Pedro J. Estébanez <pedrojrulez@gmail.com>
2022-04-01 11:01:12 +02:00
340ad7d748 Merge pull request #59755 from V-Sekai/import-gltf-mat-placeholder 2022-04-01 01:12:16 +02:00
d8b3d14d82 Add support for Blend importing of material placeholders.
Couldn't get the 'NONE' option to work.
2022-03-31 10:11:06 -07:00
b675a6b9de Allow importing punctual lights from Blend. 2022-03-31 09:34:12 -07:00
0a6889d834 Add fbx2gltf support for importing .fbx files
Lets you drag or place .fbx files in the project folder and it will import the files.

An editor setting sets the location of the fbx2gltf binary.

Enables .fbx and .blend by default.

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2022-03-30 15:22:46 +02:00
9484ee7a9e Add support for importing .blend files
Lets you drag or place .blend files in the project folder and it will import the files.

Checks for Blender 3.0's gltf2 `export_keep_originals` option.

Add basepath support to GLTFDocument append_from_file.

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2022-03-29 21:54:41 +02:00
45ec0e31c3 Remove last editor code dependencies in template build
SConstruct change also makes it possible to outright delete the `editor`
folder in a `tools=no` build, which we use in CI to ensure no invalid
cross-dependencies are added.
2022-03-28 21:13:01 +02:00
5fe6984639 Modules: Don't build editor-specific classes in templates
They're moved to an `editor` subfolder so that we can easily handle them
separately.
2022-03-28 16:48:15 +02:00
5e6d4baa48 Add GLTF, DAE and FBX importers enforcement for blend shape mask array 2022-03-24 17:15:23 -04:00
35b964606e glTF export for new TYPE_BLEND_SHAPE tracks 2022-03-03 05:28:00 -08:00
c798f98779 Fix GLTF exporter crash when using GridMap 2022-02-20 21:52:04 +08:00
771170e7b0 Default material is assigned to meshes without material for glTF export 2022-02-16 20:19:19 +05:30
78a767edb3 Merge pull request #35679 from Calinou/doc-add-xml-schema 2022-02-15 13:14:58 +01:00
b68dd2e189 Add an XML schema for documentation
This makes it easier to spot syntax errors when editing the
class reference. The schema is referenced locally so validation
can still work offline.

Each class XML's schema conformance is also checked on GitHub Actions.
2022-02-15 00:03:31 +01:00
cd1d7294d8 Remove the EditorNode parameter from EditorPlugins create methods
Remove EditorNode usage from the Navigation editor plugin.
2022-02-14 18:21:42 +01:00
05b56f316d Remove most EditorNode constructor parameters and fields 2022-02-14 14:16:24 +01:00
7a7fabe4f6 Merge pull request #57641 from Geometror/compilation-time-improvements-1 2022-02-12 09:46:02 +01:00
b396fd4eef Improve compilation speed (forward declarations/includes cleanup) 2022-02-12 02:46:22 +01:00
92f4c33492 CSG Meshes can be exported as glTF 2022-02-11 22:48:28 +05:30
1bdb82c64e Fix typos with codespell
Using codespell 2.2-dev from current git.

Added `misc/scripts/codespell.sh` to make it easier to run it once in a
while and update the skip and ignore lists.
2022-02-10 12:30:19 +01:00
90162851a7 Core: Move generated VERSION_HASH to a .cpp file
This lets us have its definition in `core/version.h` and avoid
rebuilding a handful of files every time the commit hash changes.
2022-02-09 09:20:17 +01:00
d219547c96 [Net] New replication interface, spawner and synchronizer nodes.
Initial implementation of the MultiplayerReplicationInterface and its
default implementation (SceneReplicationInterface).

New MultiplayerSpawner node helps dealing with instantiation of scenes
on remote peers (e.g. clients).
It supports both custom spawns via a `_spawn_custom` virtual function,
and optional auto-spawn of known scenes via a TypedArray<PackedScenes>
property.

New MultiplayerSynchornizer helps synchronizing states between the local
and remote peers, supports both sync and spawn properties and is
configured via a `SceneReplicationConfig` resource.
It can also sync via path (i.e. without being spawned by a
MultiplayerSpawner if both peers has it in tree, but will not send the
spawn state in that case, only the sync one.
2022-02-04 14:56:30 +01:00
adbe948bda String: Add contains(). 2022-02-04 01:28:02 +05:45
12d0ff1a4d Issue 57130 Fix GLTFDocument.generate_scene if state is null 2022-01-25 00:48:12 +01:00
b468104842 Skip Draco-compressed glTF 3d format files. 2022-01-08 10:14:46 -08:00
9e095bb68b Fix some more wrong node names 2022-01-07 00:27:20 +01:00
3662105f8b Merge pull request #56479 from V-Sekai/import-options 2022-01-05 20:44:42 +01:00
118f6d42ac Merge pull request #56380 from RedMser/export_gltf_normal_crash 2022-01-05 10:46:32 +01:00
c6bd3ca191 Merge pull request #56290 from nikitalita/fix-gltf-mesh-prims 2022-01-05 10:34:08 +01:00
07a39684a0 options dict is now passed to _import_scene. 2022-01-05 01:07:54 -08:00
5ce54ce142 Merge pull request #52541 from V-Sekai/gltf-load-scene-buffer
Add gltf import buffer.
2022-01-04 12:12:09 -08:00
d8923d8c74 Add import glb from buffer
Split functions from gltf document import and export into six functions.

Use base path to allow two code paths based on an empty base path or a full base path.

Add uri decode in _parse_buffers.
2022-01-04 06:06:03 -08:00
fe52458154 Update copyright statements to 2022
Happy new year to the wonderful Godot community!
2022-01-03 21:27:34 +01:00
0e36d5e782 Fix glTF scene export crash on null normal texture
Also removes a redundant get_texture call directly below
the modified code block.

Fixes #56379
2021-12-31 17:45:03 +01:00
f34ea3873e FIX GLTF Document mesh primitive conversions 2021-12-27 17:36:58 -08:00
4070f55ff0 glTF animation parsing: Changed the 'loop' and 'cycle' animation name keywords to be case-insensitive 2021-12-15 01:25:30 +01:00
368c0bc0ac Misc build system fixes 2021-12-10 12:14:27 -06:00
e9808e3d9a Add a double-precision editor build to CI 2021-12-09 09:52:48 -06:00
89ec3d3bc7 Remove or make verbose some debugging prints
The message about SpatialMaterial conversion was turned into a warning,
as it can potentially interfere with porting projects from Godot 3.x
(if there's a bug in the conversion code).
2021-12-05 23:22:23 +01:00
8f433a1f53 Fix crash when exporting meshes to gltf that have no skin. 2021-11-22 22:40:47 -05:00
88c4380737 Modules: Make sure to include modules_enabled.gen.h where needed 2021-11-12 13:42:58 +01:00
06a33e590f Merge pull request #53819 from TokageItLab/re-implement-ping-pong
Reimplement ping-pong animation and reverse playback
2021-11-09 22:11:04 +01:00