This commit adds caching to the lightmap mesh unwraps generated on
import. This speeds up re-imports of meshes that haven't changed and
also makes sure that the unwraps are consistent across imports.
The unwrapping process is not deterministic, so one could end up with
a different mapping every time the scene was imported, breaking any
previously baked lightmaps. The changes in this commit prevent that
from happening.
Note: Only replaced 2 instances to test, Node.get_children and TileMap.get_used_cells
Note: Will do a mass replace on later PRs of whathever I can find, but probably need
a tool to grep through doc.
Warning: Mono will break, needs to be fixed (and so do TypeScript and NativeScript, need to ask respective maintainers)
Also added an easier way to load native GLSL shaders.
Extras:
Had to fix no-cache for subresources in resource loader, it was not properly working, making shaders not properly reload.
Note:
The precommit hooks are broken because they don't seem to support enums from one class being used in another.
Feel free to fix this after merging this PR.
This doesn't make much sense API-wise, but it's important for the documentation
workflow that the Mono and non-Mono builds produce the same output, otherwise
we keep having non-Mono builds removing Mono properties and losing their
descriptions.
This is a terrible hack but it's ad hoc, and should be OK for the time being.
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
Fixes#18809.
The in-editor ortho camera used a far clipping plane of 8192 units, and was
placed 4096 units away from the camera cursor.
This was far enough to cause culling issues from floating point precision loss
on objects smaller than one unit.
This change modifies the near/far clipping planes of the ortho camera to use
those specified in the editor (and currently used by the perspective camera).
The frustum is still centered around the camera cursor location, as it was
before.
(cherry picked from commit 26912c15e6)
- 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
The size settings are more "just works", with default scale and depth scale
values that don't need much tweaking.
Additionally, a "skin" mode was added so skin looks better.
EDIT: Cleaned up SSR filter shader a bit.
The Request Docs button is partly responsible for layout overflow
issues on narrow displays, such as #31133.
It also tended to attract spam and low-effort issues that were
difficult to act upon. A "Send Docs Feedback" menu option has been added
to replace it.
Right now, games only work on devices when exported with FullAOT+Interpreter.
There are some issues left that need to addressed for FullAOT alone. Right now,
it's giving issues with the Godot.NativeCalls static constructor.
Configured for a max line length of 120 characters.
psf/black is very opinionated and purposely doesn't leave much room for
configuration. The output is mostly OK so that should be fine for us,
but some things worth noting:
- Manually wrapped strings will be reflowed, so by using a line length
of 120 for the sake of preserving readability for our long command
calls, it also means that some manually wrapped strings are back on
the same line and should be manually merged again.
- Code generators using string concatenation extensively look awful,
since black puts each operand on a single line. We need to refactor
these generators to use more pythonic string formatting, for which
many options are available (`%`, `format` or f-strings).
- CI checks and a pre-commit hook will be added to ensure that future
buildsystem changes are well-formatted.
- Travis: Change x11 to linuxbsd
- SCons: Change x11 plataform to linuxbsd
- Plugins: Remove ; to avoid fallthrough warning
- DisplayServerX11: Implement set_icon
- DisplayServerX11: Fix X11 bug when a window was erased from windows
map, all the changes from that erased windows are sending to the main
window
- DisplayServerX11: Reorder create_window commands
- DisplayServerX11: Change every Size2 to Size2i and Rect2 to Rect2i
where it belongs
+ More X11 fixes which have been integrated directly back into reduz's
original commits while rebasing the branch.
PR #30877 was bogus as it made a blend shape-specific code block apply
to everything but blend shapes (as it seemed not to work properly *for*
blend shapes).
The proper fix should thus be to simply remove the problematic
block (and thus cleanup unnecessary logic).
Fixes#32712.
Now that the unused DocDump was removed, the `editor/doc` subfolder is
redundant.
Similarly, there's no reason for Collada to have a subfolder for itself
when glTF or OBJ don't.
- Add an help message when no profile is selected.
- This replaces the class/property trees which are now hidden
when no profile is selected.
- Display `(none)` as the current profile when no profile is
currently active.
- Make the newly created/imported profile the current if it's the
first profile to be added to the list.
- Make more strings localizable.
Changes made:
* Added dirty bit for SpatialEditorSelectedItem's last_xform
* SpatialEditorViewport checks that dirt bit too before skipping the selection
- Parse `.po` files from `doc/translations/*.po` like already done
with `editor/translations/*.po`.
- Add logic to register a doc translation mapping in `TranslationServer`
and `EditorSettings`.
- Add `DTR()` to lookup the doc translation mapping (similar to `TTR()`).
Strings are automatically dedented and stripped of whitespace to ensure
that they would match the translation catalog.
- Use `DTR()` to translate relevant strings in `EditorHelp`,
`EditorInspector`, `CreateDialog`, `ConnectionsDialog`.
- Small simplification to `TranslationLoaderPO`, the path argument was
not really meaningful.
Alignment of scene pixels on screen pixel ensure a crisp rendering of small features (such as text). Unfortunately, alignment of top left pixel on screen adds a lot of jittering when zooming at high zoom factor.
This change allow to snap the top left scene pixel on the closest screen pixel (not only the top-left most), and we do so only when the scale factor is an integer.
For us, it practically only changes the fact that `A<A<int>>` is now
used instead of the C++03 compatible `A<A<int> >`.
Note: clang-format 10+ changed the `Standard` arguments to fully
specified `c++11`, `c++14`, etc. versions, but we can't use `c++17`
now if we want to preserve compatibility with clang-format 8 and 9.
`Cpp11` is still supported as deprecated alias for `Latest`.