summaryrefslogtreecommitdiff
path: root/modules/dds
AgeCommit message (Collapse)Author
2021-06-19Rename `instance()`->`instantiate()` when it's a verbLightning_A
2021-06-11Core: Move DirAccess and FileAccess to `core/io`Rémi Verschelde
File handling APIs are typically considered part of I/O, and we did have most `FileAccess` implementations in `core/io` already.
2021-02-11Improve resource load cachereduz
-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-08Initialize class/struct variables with default values in modules/Rafał Mikrut
2021-01-01Update copyright statements to 2021Rémi Verschelde
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 🎆
2020-11-16Remove empty lines around braces with the formatting scriptAaron Franke
2020-06-15DDS: Fix loading files without DDSD_CAPS or DDSD_PIXELFORMATRémi Verschelde
MSDN says: > When you write .dds files, you should set the DDSD_CAPS and > DDSD_PIXELFORMAT flags, and for mipmapped textures you should also > set the DDSD_MIPMAPCOUNT flag. However, when you read a .dds file, > you should not rely on the DDSD_CAPS, DDSD_PIXELFORMAT, and > DDSD_MIPMAPCOUNT flags being set because some writers of such a file > might not set these flags. https://docs.microsoft.com/en-us/windows/win32/direct3ddds/dds-header ¯\_(ツ)_/¯ Fixes #39516.
2020-05-14Style: Enforce braces around if blocks and loopsRémi Verschelde
Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html
2020-05-14Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocksRémi Verschelde
Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
2020-04-20Exposed RenderingDevice to script APIJuan Linietsky
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.
2020-04-02Replace NULL with nullptrlupoDharkael
2020-03-30SCons: Format buildsystem files with psf/blackRémi Verschelde
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.
2020-03-23Adding missing include guards to header files identified by LGTM.Rajat Goswami
This addresses the issue godotengine/godot#37143
2020-02-28Removed interactive loader, added proper thread loading.Juan Linietsky
2020-02-18PoolVector is gone, replaced by VectorJuan Linietsky
Typed `PoolTypeArray` types are now renamed `PackedTypeArray` and are sugar for `Vector<Type>`.
2020-02-11Texture refactorJuan Linietsky
-Texture renamed to Texture2D -TextureLayered as base now inherits 2Darray, cubemap and cubemap array -Removed all references to flags in textures (they will go in the shader) -Texture3D gone for now (will come back later done properly) -Create base rasterizer for RenderDevice, RasterizerRD
2020-01-01Update copyright statements to 2020Rémi Verschelde
Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
2019-09-25Added some obvious errors explanationsqarmin
2019-08-12Replace 'ERR_EXPLAIN' with 'ERR_FAIL_*_MSG' in rest of 'modules/'Robin Hübner
2019-07-06Added release function to PoolVector::Access.Ibrahn Sahir
For clarity, assign-to-release idiom for PoolVector::Read/Write replaced with a function call. Existing uses replaced (or removed if already handled by scope)
2019-07-02Fix few GCC9 warnings:Martin Liska
thirdparty/assimp/include/assimp/material.inl: In member function 'aiReturn aiMaterial::Get(const char*, unsigned int, unsigned int, aiColor3D&) const': thirdparty/assimp/include/assimp/material.inl:176:33: error: implicitly-declared 'aiColor3D& aiColor3D::operator=(const aiColor3D&)' is deprecated [-Werror=deprecated-copy] 176 | pOut = aiColor3D(c.r,c.g,c.b); modules/dds/texture_loader_dds.cpp:167:50: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 167 | if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("DXT1")) { | ^ [ 28%] modules/dds/texture_loader_dds.cpp:170:57: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 170 | } else if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("DXT3")) { | ^ modules/dds/texture_loader_dds.cpp:174:57: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 174 | } else if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("DXT5")) { | ^ modules/dds/texture_loader_dds.cpp:177:57: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 177 | } else if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("ATI1")) { | ^ modules/dds/texture_loader_dds.cpp:180:57: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 180 | } else if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("ATI2")) { | ^ modules/dds/texture_loader_dds.cpp:183:57: error: comparison of integer expressions of different signedness: 'uint32_t' {aka 'unsigned int'} and 'int' [-Werror=sign-compare] 183 | } else if (format_flags & DDPF_FOURCC && format_fourcc == PF_FOURCC("A2XY")) { | ^ thirdparty/assimp/include/assimp/material.inl: In member function 'aiReturn aiMaterial::Get(const char*, unsigned int, unsigned int, aiColor3D&) const': thirdparty/assimp/include/assimp/material.inl:176:33: error: implicitly-declared 'aiColor3D& aiColor3D::operator=(const aiColor3D&)' is deprecated [-Werror=deprecated-copy] 176 | pOut = aiColor3D(c.r,c.g,c.b);
2019-06-18Unexpose subclasses of ResourceFormatLoader and -SaverRémi Verschelde
ResourceFormatLoader and ResourceFormatSaver are meant to be overridden to add support for different formats in ResourceLoader and ResourceSaver. Those should be exposed as they can be overridden in plugins. On the other hand, all predefined subclasses of those two base classes are only meant to register support for new file and resource types, but should not and cannot be used directly from script, so they should not be exposed. Also unexposed ResourceImporterOGGVorbis (and thus its base class ResourceImporter) which are editor-only.
2019-05-07Fixes to the DDS loaderDaniel Rakos
* Added missing format info entries for ATI1 and ATI2 formats * Added missing A2XY format
2019-04-09Style: Apply new changes from clang-format 8.0Rémi Verschelde
It seems to stay compatible with formatting done by clang-format 6.0 and 7.0, so contributors can keep using those versions for now (they will not undo those changes).
2019-02-20Add -Wshadow=local to warnings and fix reported issues.marxin
Fixes #25316.
2019-01-01Update copyright statements to 2019Rémi Verschelde
Happy new year to the wonderful Godot community!
2018-12-15Added basic support for custom resource savers and loadersMarc Gilleron
2018-10-03Fixed DDS loader according to issue #22530qonnop
width and height attributes have to be switched according to the official DDS header docs: https://docs.microsoft.com/en-us/windows/desktop/direct3ddds/dds-header
2018-09-12Make core/ includes absolute, remove subfolders from include pathRémi Verschelde
This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
2018-08-24Make some debug prints verbose-only, remove othersRémi Verschelde
2018-05-30SCons: Pass env to modules can_build methodRémi Verschelde
This allows to disable modules based on the environment, in particular `env[tools]` which tells us if we are building the editor or not.
2018-01-05Add missing copyright headers and fix formattingRémi Verschelde
Using `misc/scripts/fix_headers.py` on all Godot files. Some missing header guards were added, and the header inclusion order was fixed in the Bullet module.
2018-01-01Update copyright statements to 2018Rémi Verschelde
Happy new year to the wonderful Godot community!
2017-11-15doc: Make all module docs self-containedRémi Verschelde
2017-09-20Rename pos to position in user facing methods and variablesletheed
Rename user facing methods and variables as well as the corresponding C++ methods according to the folloming changes: * pos -> position * rot -> rotation * loc -> location C++ variables are left as is.
2017-08-27Use HTTPS URL for Godot's website in the headersRémi Verschelde
2017-05-31rewritten PBR implementation to make it friendlier with BlenderJuan Linietsky
2017-05-26-Added EXR supprot for HDR (no BC6 compression yet though)Juan Linietsky
-Improvements to texture importer -Proper detection of S3TC compression modes, and added all modes to Image -Fixes to non-power of 2 compressed textures, which should all be supported by GLES3
2017-05-17Removal of Image from Variant, converted to a Resource.Juan Linietsky
2017-04-23Fix property warnings and hide some debug printsRémi Verschelde
"ALL IS GOOD" was a lie. In particular, removes verbose "path not recognized" false positive. The actual logic is to (somewhat naively) check all ResourceFormatLoaders and to pick the first good match, so no need to warn about the formats that do not match the type hint.
2017-04-08Add "Godot Engine contributors" copyright lineRémi Verschelde
2017-03-24Fix typos in source code using codespellRémi Verschelde
From https://github.com/lucasdemarchi/codespell
2017-03-05A Whole New World (clang-format edition)Rémi Verschelde
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
2017-02-21Fix some compilation warnings.Shlomi Fish
Redone the commit based on the input in https://github.com/godotengine/godot/pull/7851 . Not all warnings were fixed but it's a start.
2017-01-14Style: Fix whole-line commented codeRémi Verschelde
They do not play well with clang-format which aligns the `//` part with the rest of the code block, thus producing badly indented commented code.
2017-01-14rename String.extension() -> String.get_extension() / String.basename() -> ↵Juan Linietsky
String.get_basename()
2017-01-07Memory pool vectors (DVector) have been enormously simplified in code, and ↵Juan Linietsky
renamed to PoolVector
2017-01-02ObjectTypeDB was renamed to ClassDB. Types are meant to be more generic to ↵Juan Linietsky
Variant. All usages of "type" to refer to classes were renamed to "class" ClassDB has been exposed to GDScript. OBJ_TYPE() macro is now GDCLASS()
2017-01-02Merge remote-tracking branch 'origin/gles3' into gles3-on-masterRémi Verschelde
Various merge conflicts have been fixed manually and some mistakes might have been made - time will tell :)
2017-01-01Welcome in 2017, dear changelog reader!Rémi Verschelde
That year should bring the long-awaited OpenGL ES 3.0 compatible renderer with state-of-the-art rendering techniques tuned to work as low as middle end handheld devices - without compromising with the possibilities given for higher end desktop games of course. Great times ahead for the Godot community and the gamers that will play our games!