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
2021-10-06Cleanup: rename BKE_font.h -> BKE_vfont.hCampbell Barton
Match API naming prefix (BKE_vfont_*) and DNA_vfont_types.h.
2021-10-06Cleanup: move BLI_vfontdata.h to BKE_vfontdata.hCampbell Barton
This didn't belong on blenlib since it uses DNA data types and included a bad-level call to BKE_curve.h. It also meant linking in blenlib would depend on the freetype library, noticeable for thumbnail extraction (see D6408).
2021-09-29Fix T91756: String to Curve node produces NaN when size is zeroJacques Lucke
2021-09-24Geometry Nodes: String to Curves NodeErik Abrahamsson
This commit adds a node that generates a text paragraph as curve instances. The inputs on the node control the overall shape of the paragraph, and other nodes can be used to move the individual instances afterwards. To output more than one line, the "Special Characters" node can be used. The node outputs instances instead of real geometry so that it doesn't have to duplicate work for every character afterwards. This is much more efficient, because all of the curve evaluation and nodes like fill curve don't have to repeat the same calculation for every instance of the same character. In the future, the instances component will support attributes, and the node can output attribute fields like "Word Index" and "Line Index". Differential Revision: https://developer.blender.org/D11522
2021-09-22Initial implementation of local ID re-use when appending.Bastien Montagne
This commit adds to ID struct a new optional 'weak reference' to a linked ID (in the form of a blend file library path and full ID name). This can then be used on next append to try to find a matching local ID instead of re-making the linked data local again. Ref. T90545 NOTE: ID re-use will be disabled for regular append for the time being (3.0 release), and only used for assets. Therefore, this commit should not change anything user-wise. Differential Revision: https://developer.blender.org/D12545
2021-09-15Cleanup: replace defines with functionsCampbell Barton
2021-09-15Cleanup: correct tracker ID in commentCampbell Barton
2021-09-15Fix T89241: Scale to fit overflows into a second lineCampbell Barton
2021-08-19Cleanup: Blendwrite: Move code deciding if an ID should be written out of ID ↵Bastien Montagne
callbacks. This was not really useful, and added estra useless steps in case and ID should not actually be written. Further more, it prevented clearing the usercount on write, which can be cause a false positive 'chanhged' detection in undo/redo case.
2021-08-17Docs: improve word wrap commentCampbell Barton
2021-08-12Fix T89241: 3D Text "Scale to Fit" wraps onto the second lineCampbell Barton
Disable wrapping when "scale to fit" is used, assert the error is small so an invalid scale-to-fit value wont go by unnoticed.
2021-08-04Fix T90417: font loading creates duplicate ID namesCampbell Barton
Also repair any errors in existing files. Error from e0dd3fe5872ba37ff188e292b80b46fcf8df413c.
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2021-06-30Cleanup: use const for datatoc declarationsCampbell Barton
2021-06-26Cleanup: full sentences in comments, improve comment formattingCampbell Barton
2021-06-24Cleanup: comment blocks, trailing space in commentsCampbell Barton
2021-04-08Fix T81707: Spline IK Joints "Floating" above curveSebastian Parborg
The issue was that where_on_path uses a resampled curve to get the data from the curve. This leads to disconnects between the curve the user sees and the evaluated location data. To fix this we simply use the actual curve data the user can see. The older code needed a cleanup either way as there were hacks in other parts of the code trying to work around some brokenness. This is now fixed and we no longer need to clamp the evaluation range to 0-1 or make helper functions to make it do what we actually want. Reviewed By: Campbell, Sybren Differential Revision: http://developer.blender.org/D10898
2021-04-01Curve: Remove 'CU_2D' flag used for nurbsGermano Cavalcante
This fixes T86440 As the CU_2D flag is set for nurbs, a Curve can have 2D nurbs mixed with 3D. But the UI does not allow this mixing. It updates all nurbs to 2D or 3D when set. So remove this specific flag for nurbs. This may break old files, since 2D curves with mixed 3D are now set as 3D. Differential Revision: https://developer.blender.org/D10738
2021-02-25Refactor: IDTypeInfo: Add `owner_get` to get owner of embedded IDs.Bastien Montagne
This concerns currently only collections (`master_collection` of scenes) and root node trees. It removes the matching type-specific helpers (`BKE_collection_master_scene_search` and `BKE_node_tree_find_owner_ID`). No functional change expected here. NOTE: Current implementation of `owner_get` is far from optimal, we could probably do it better, see {T69169}. NOTE: While it could also have it, shapekeys IDTypeInfo was left out of this change for now. Mainly because it sould not be used currently, and we ultimately want to demote shape keys from ID status anyway.
2021-01-22LibOverride: Add an 'post apply' callback to IDTypeInfo.Bastien Montagne
Currently this is needed to properly tag PointCache's for info update (fixes an issue reported in T82503). Suspect we may need this in more cases in the future though, RNA assign/update processes are not always 100% enough to deal with complicated corner cases.
2020-12-14LibOverride: Do not store some heavy data from override IDs.Bastien Montagne
This commit removes geometry from meshes and shapekeys, and embedded files, from liboverride IDs. This data is never overrideable, there is no reason to store extra useless copies of it in production files. See T78944. Note that we may add more data to be skipped on write for liboverrides in the future, but this commit should address all the most important cases already. Reviewed By: brecht Differential Revision: https://developer.blender.org/D9810
2020-11-06Cleanup: use ELEM macroCampbell Barton
2020-11-03Add a callback to `IDTypeInfo` to allow preservation of some data accross ↵Bastien Montagne
memfile undos This is essentially adding that new callback, and using it only for already existing Scene's 3DCursor. Note that the place where this is called has been moved again, after all have been lib-linked, such that those callbacks may also work on ID pointers. Maniphest Tasks: T71759 Differential Revision: https://developer.blender.org/D9237
2020-10-07IDTypeInfo: add flag to indicate that ID has no animation dataJacques Lucke
This is part of T75724. Reviewers: mont29 Differential Revision: https://developer.blender.org/D9134
2020-09-21Fix T66614: Text objects: Truncate overflow for non-top aligned textDalai Felinto
2020-09-10Refactor: move VFont .blend I/O to IDTypeInfo callbacksJacques Lucke
2020-09-09Cleanup: reduce variable scopesJacques Lucke
2020-09-03Fix 3D text cursor alignment without any textCampbell Barton
Part of fix for T80340.
2020-09-03Fix mistake in recent font cleanupCampbell Barton
7ff7a9c8fdc0 missed incrementing the pointer used for initializing.
2020-09-03Fix T80340: Crash with an empty text with Text on CurveCampbell Barton
Avoid divide by zero, based on D8780 by @lichtwerk.
2020-09-03Cleanup: remove redundant Y bounds calculation for text on pathCampbell Barton
Also correct some comments.
2020-08-28IDTypeInfo: add .blend file io callbacksJacques Lucke
This is part of T76372. It adds the `blend_write`, `blend_read_data`, `blend_read_lib` and `blend_read_expand` which correspond to the various steps when reading and writing .blend files. Having these callbacks allows us to decentralize the blenloader code a lot more. This has the affect that code related to any specific ID type is less scattered. Reviewers: mont29 Differential Revision: https://developer.blender.org/D8670
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-07-23Cleanup: rename Curve.len_wchar to len_char32Campbell Barton
The name was misleading as the length is for char32_t, not wchar_t.
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-09Fix mistake in recent fix for text editor overflowCampbell Barton
2020-06-09Docs: comment text scale behaviorCampbell Barton
Avoid misunderstanding that caused T77609.
2020-06-09Fix T77609: Scale to Fit Text Box fails when text is too narrowDalai Felinto
Caused by error in fix for T75965 (83d9ba341e5a).
2020-05-21Refactor: Move NOP idtypes foreach_id to new IDTypeInfo structure.Bastien Montagne
2020-04-23Fix T75965: Scale to Fit Text Box fails with a single wordCampbell Barton
2020-04-03Cleanup: split `BKE_anim.h` and `anim.c` into smaller piecesSybren A. Stüvel
The files are now split up into the following sections: - `BKE_anim_path.h` and `anim_path.c` for path/curve functions. - `BKE_anim_visualization.h` and `anim_visualizationanim_path.c` for animation visualization (mostly motion paths). - `BKE_duplilist.h` for DupliList function declarations. These were already implemented in `object_dupli.c`, so they were rather out of place being declared in `BKE_anim.h` in the first place. No functional changes.
2020-04-03Cleanup: Font, added initialisation for two variablesSybren A. Stüvel
My compiler (GCC 7.5.0) was warning about these variables potentially not being initialised. Since the function is highly complex, instead of analysing it I just trust my compiler and added initial values. This should be no functional change.
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-06Cleanup: VFont: Move to IDTypeInfo and remove unused BKE APIDalai Felinto
This was particularly strange because we had a _free_data() function. But still the one I replaced was of course the _free() one. And we should rename the _free_data_ function later to avoid confusions.
2020-03-04Refactor ID make local to use a single flag parameter.Bastien Montagne
Instead of using anonymous booleans flags, also allows to keep the same behavior in all cases, without needing special handling from calling code for our beloved oddballs object proxies...
2020-03-04Cleanup: ID make local: remove `id_in_bmain` argument.Bastien Montagne
This info is now stored in ID tags themselves, so no need to pass an extra anonymous boolean parameter around, yay!
2020-03-04Cleanup: Rename 'make local' functions to new scheme.Bastien Montagne
Also removed some only used locally from the header, `BKE_lib_id.h` is already way too big, no need to overload it with unused things.
2020-02-10Cleanup/refactor: Rename `BKE_library` files to `BKE_lib`.Bastien Montagne
Note that `BKE_library.h`/`library.c` were renamed to `BKE_lib_id.h`/`lib_id.c` to avoid having a too generic name here. Part of T72604.
2019-11-24Cleanup: doxygen commentsCampbell Barton
Also correct some outdated symbol references, add missing 'name' commands.
2019-11-22Fix T71273: Bad encoding of utf-8 for Text objectsmano-wii
`BLI_strncpy_wchar_from_utf8` internally assumes `wchar_t` is 32 bits which is not the case on windows. The solution is to replace `wchar_t` with `char32_t`. Thanks to @robbott for compatibility on macOS. Differential Revision: https://developer.blender.org/D6198