Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-09-12Cleanup: replace BLI_snprintf with BLI_path_joinCampbell Barton
Also use a larger buffer to account for the unlikely case of the buffer not being big enough for the appended directories.
2022-05-12UDIM: Add support for packing inside .blend filesJesse Yurkovich
This completes support for tiled texture packing on the Blender / Cycles side of things. Most of these changes fall into one of three categories: - Updating Image handling code to pack/unpack tiled and multi-view images - Updating Cycles to handle tiled textures through BlenderImageLoader - Updating OSL to properly handle textures with multiple slots Differential Revision: https://developer.blender.org/D14395
2022-03-24Cleanup: use "filepath" instead of "filename" for full pathsCampbell Barton
Reserve "filename" when only the name component is used.
2022-03-21Cleanup: add image_format.cc for functions related to ImageFormatDataBrecht Van Lommel
Also fixes missing code to read/write/free/copy color management settings in various places. This can't be set through the UI currently, but still should be handled consistently.
2022-02-11File headers: SPDX License migrationCampbell Barton
Use a shorter/simpler license convention, stops the header taking so much space. Follow the SPDX license specification: https://spdx.org/licenses - C/C++/objc/objc++ - Python - Shell Scripts - CMake, GNUmakefile While most of the source tree has been included - `./extern/` was left out. - `./intern/cycles` & `./intern/atomic` are also excluded because they use different header conventions. doc/license/SPDX-license-identifiers.txt has been added to list SPDX all used identifiers. See P2788 for the script that automated these edits. Reviewed By: brecht, mont29, sergey Ref D14069
2022-01-06Cleanup: spelling in commentsCampbell Barton
2021-12-07Cleanup: move public doc-strings into headers for 'blenkernel'Campbell Barton
- Added space below non doc-string comments to make it clear these aren't comments for the symbols directly below them. - Use doxy sections for some headers. - Minor improvements to doc-strings. Ref T92709
2021-10-11Cleanup: Add const keyword to `BKE_packedfile_id_check`.Jeroen Bakker
2021-10-06Cleanup: rename BKE_font.h -> BKE_vfont.hCampbell Barton
Match API naming prefix (BKE_vfont_*) and DNA_vfont_types.h.
2021-09-13Cleanup: Packedfile don't repeat yourself.Jeroen Bakker
Introduced `BKE_packedfile_unpack` that is called from the specialized implementation for Image, Sound, Font, Volume etc. This is in preparation for T91252.
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2020-11-13Cleanup: use IMB_FTYPE_NONE instead of 0 for imbuf format comparisonCampbell Barton
Image format code checked the file type against an enum except for zero which is used when the format can't be detected. Also add doc-strings to some of the image file type callbacks.
2020-11-13Fix T82349: file extension not added to unpacked imagesRobert Guetzkow
Ensure the appropriate extension is set when unpacking generated images that don't have a filepath set. Ref D9500
2020-09-10Cleanup: extract functions for PackedFile .blend I/OJacques Lucke
2020-08-08Cleanup: remove redundant return parenthesisCampbell Barton
2020-08-07Cleanup: fixed Clang-Tidy `bugprone-suspicious-string-compare` warningsSybren A. Stüvel
No functional changes.
2020-08-07Cleanup: Blenkernel, Clang-Tidy else-after-return fixesSybren A. Stüvel
This addresses warnings from Clang-Tidy's `readability-else-after-return` rule in the `source/blender/blenkernel` module. No functional changes.
2020-06-23Cleanup: rename 'name' to 'filepath' for DNA typesCampbell Barton
Using 'name' for the full path of a file reads badly, especially when id.name is used in related code.
2020-06-23Cleanup: rename Library.filepath to filepath_absCampbell Barton
Make it clear that this is the absolute path, allow the 'name' to be renamed to 'filepath'. Rename is safe since this is only for run-time.
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-18Objects: add Volume object type, and prototypes for Hair and PointCloudBrecht Van Lommel
Only the volume object is exposed in the user interface. It is based on OpenVDB internally. Drawing and rendering code will follow in another commit. https://wiki.blender.org/wiki/Source/Objects/Volume https://wiki.blender.org/wiki/Reference/Release_Notes/2.83/Volumes Hair and PointCloud object types are hidden behind a WITH_NEW_OBJECT_TYPES build option. These are unfinished, and included only to make it easier to cooperate on development in the future and avoid tricky merges. https://wiki.blender.org/wiki/Source/Objects/New_Object_Types Ref T73201, T68981 Differential Revision: https://developer.blender.org/D6945
2019-12-12Add support for tiled images and the UDIM naming schemeLukas Stockner
This patch contains the work that I did during my week at the Code Quest - adding support for tiled images to Blender. With this patch, images now contain a list of tiles. By default, this just contains one tile, but if the source type is set to Tiled, the user can add additional tiles. When acquiring an ImBuf, the tile to be loaded is specified in the ImageUser. Therefore, code that is not yet aware of tiles will just access the default tile as usual. The filenames of the additional tiles are derived from the original filename according to the UDIM naming scheme - the filename contains an index that is calculated as (1001 + 10*<y coordinate of the tile> + <x coordinate of the tile>), where the x coordinate never goes above 9. Internally, the various tiles are stored in a cache just like sequences. When acquired for the first time, the code will try to load the corresponding file from disk. Alternatively, a new operator can be used to initialize the tile similar to the New Image operator. The following features are supported so far: - Automatic detection and loading of all tiles when opening the first tile (1001) - Saving all tiles - Adding and removing tiles - Filling tiles with generated images - Drawing all tiles in the Image Editor - Viewing a tiled grid even if no image is selected - Rendering tiled images in Eevee - Rendering tiled images in Cycles (in SVM mode) - Automatically skipping loading of unused tiles in Cycles - 2D texture painting (also across tiles) - 3D texture painting (also across tiles, only limitation: individual faces can not cross tile borders) - Assigning custom labels to individual tiles (drawn in the Image Editor instead of the ID) - Different resolutions between tiles There still are some missing features that will be added later (see T72390): - Workbench engine support - Packing/Unpacking support - Baking support - Cycles OSL support - many other Blender features that rely on images Thanks to Brecht for the review and to all who tested the intermediate versions! Differential Revision: https://developer.blender.org/D3509
2019-10-02Revert "UI: use correct singular and plural nouns in report messages"Brecht Van Lommel
Convention is to use (s) postfix for cases where there can be one or multiple, so stay consistent with that. This reverts commit 3e8276311ed17d12e8b47b4fe8e2f68c1ce8c603.
2019-10-01UI: use correct singular and plural nouns in report messagesYevgeny Makarov
Differential Revision: https://developer.blender.org/D5729
2019-10-01Fix T70315: Blender exit with code `-6` with message `Attempt to free NULL ↵Bastien Montagne
pointer`. This is not actually fixing the real issue here, PackedFile structs are never supposed to have a NULL pointer - and in that monster .blend file, the pointer is not NULL, but the actual data chunk has been lost somehow, so it gets NULL during read process. Very unlikely we ever know how such corrupted .blend was created though (there's probably a fair chance that this is not even due to a bug in Blender, but rather a glitch in filesystem or something). So for now, ensure at read time that we get a coherent state (i.e. remove any read PackedFile that would have a NULL data field), and add a few asserts in relevant code to check we never get NULL data pointer here.
2019-07-07Cleanup: split enum types, use PF_CMP prefixCampbell Barton
2019-07-07Cleanup: move enum unto BKE_packedFile.hCampbell Barton
Use enum type for functions arguments. Removed -1 check in switch statement, this isn't needed.
2019-07-07Cleanup: use BKE_packedfile prefix for function namesCampbell Barton
Avoid ambiguity with terms check & compare.
2019-05-01ClangFormat: run with ReflowComments on source/Campbell Barton
Prepare for enabling ReflowComments.
2019-04-27Cleanup: comments (long lines) in blenkernelCampbell Barton
2019-04-22Cleanup: style, use braces for blenkernelCampbell Barton
2019-04-17ClangFormat: apply to source, most of internCampbell Barton
Apply clang format as proposed in T53211. For details on usage and instructions for migrating branches without conflicts, see: https://wiki.blender.org/wiki/Tools/ClangFormat
2019-03-08Cleanup: use plural names for Main listsCampbell Barton
Convention was not to but after discussion on 918941483f7e we agree its best to change the convention. Names now mostly follow RNA. Some exceptions: - Use 'nodetrees' instead of 'nodegroups' since the struct is called NodeTree. - Use 'gpencils' instead of 'grease_pencil' since 'gpencil' is a common abbreviation in the C code. Other exceptions: - Leave 'wm' as it's a list of one. - Leave 'ipo' as is for versioning.
2019-02-18doxygen: add newline after \fileCampbell Barton
While \file doesn't need an argument, it can't have another doxy command after it.
2019-02-06Cleanup: remove redundant doxygen \file argumentCampbell Barton
Move \ingroup onto same line to be more compact and make it clear the file is in the group.
2019-02-01Cleanup: remove redundant, invalid info from headersCampbell Barton
BF-admins agree to remove header information that isn't useful, to reduce noise. - BEGIN/END license blocks Developers should add non license comments as separate comment blocks. No need for separator text. - Contributors This is often invalid, outdated or misleading especially when splitting files. It's more useful to git-blame to find out who has developed the code. See P901 for script to perform these edits.
2019-01-26Cleanup: remove redundant BKE/BLI/BIF headersCampbell Barton
2018-11-07Cleanup: Remove 'BKE_library.h' include from 'BKE_main.h'Bastien Montagne
That kind of implicit includes should really only be done when totally, absolutely necessary, and ideally only with rather simple 'second-level' headers. Otherwise not being explicit with includes always end up biting in unexpected ways...
2018-10-18Cleanup: Remove more #if 0 blocksJacques Lucke
Continuation of https://developer.blender.org/D3802 Reviewers: brecht Differential Revision: https://developer.blender.org/D3808
2018-09-24Spelling fixes in comments and descriptions, patch by luzpaz.Brecht Van Lommel
Differential Revision: https://developer.blender.org/D3719
2018-06-17Cleanup: trailing space for blenkernelCampbell Barton
2018-06-11Cleanup: remove moar ugly G.main usages...Bastien Montagne
BKE_image was an ugly nest, could fix all but the ones from compositor, so moved ugly G.main there, at least we know where the Evil is that way ;)
2018-06-05Cleanup: use new accessors to blendfile path (Main.name).Bastien Montagne
2018-05-31Cleanup: nuke G.main out of BKE PackedFile code.Bastien Montagne
2018-03-23Cleanup: stray tabsCampbell Barton
Tabs in middle of code (mostly for no reason / by accident).
2017-11-06Rename ID_IS_LINKED_DATABLOCK to ID_IS_LINKED.Bastien Montagne
This makes code closer to id_override/assent-engine ones, which introduce a new type of linked data, and hence reserve ID_IS_LINKED_DATABLOCK to real linked datablocks.
2017-08-28Make GS macro return proper IDType typeSergey Sharybin
Previously it was returning short, which was really easy to (a) compare against non-ID type value (b) forget to handle some specific value in switch statement. Both issues happened in the nearest past, so it's time to tighten some nuts here. Most of the change related on silencing strict compiler warning now, but there is also one tricky aspect: ID_NLA is not in the IDType enum. So there is still cast to short to handle that switch. If someone has better ideas how to deal with this please go ahead :)
2017-05-20CMake: Use GCC7's -Wimplicit-fallthrough=5Campbell Barton
Use to avoid accidental missing break statements, use ATTR_FALLTHROUGH to suppress.
2016-07-06Replace of (id->lib != NULL) check by meaningful macro.Bastien Montagne
Idea is to replace hard-to-track (id->lib != NULL) 'is linked datablock' check everywhere in Blender by a macro doing the same thing. This will allow to easily spot those checks in future, and more importantly, to easily change it (see work done in asset-engine branch). Note: did not touch to readfile.c, since there most of the time 'id->lib' check actually concerns the pointer, and not a check whether ID is linked or not. Will have a closer look at it later. Reviewers: campbellbarton, brecht, sergey Differential Revision: https://developer.blender.org/D2082
2015-10-26Cleanup: warning & whitespaceCampbell Barton