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-06Cleanup: spelling in comments, formatting, move comments into headersCampbell Barton
2022-08-12Cleanup: replace magic number with flagCampbell Barton
2022-07-20Cleanup: remove unused get_cage_mesh parameterJacques Lucke
All callers passed `false` for this parameter, making it more confusing than useful. If this functionality is needed again in the future, a separate function should be added. Differential Revision: https://developer.blender.org/D15401
2022-06-29LineArt: Shadow and related functionalities.Yiming Wu
This patch includes the full shadow functionality for LineArt: - Light contour and cast shadow lines. - Lit/shaded region selection. - Enclosed light/shadow shape calculation. - Silhouette/anti-silhouette selection. - Intersection priority based on shadow edge identifier. Reviewed By: Sebastian Parborg (zeddb) Differential Revision: https://developer.blender.org/D15109
2022-06-17Cleanup: spelling in commentsCampbell Barton
2022-06-15GPencil: Fix crash when using time offset modifierFalk David
This fixes a mistake in 60bf561d379a, which did not account for offset frames by the time offset modifier.
2022-06-15Fix T98853: Blender crashes when moving grease pencil object has any ↵filedescriptor
invisible layers Whats happening is that the modifier keeps adding new frames to the evaluated object resulting in an exponential increase. This is because when preparing the data for the modifiers we only copy visible strokes to the eval object. But the modifiers do not consider visibility and will generate the mirrored strokes even for layers that are hidden. Because those layers have not been copied (only their structure) we run into this issue. The solution is always copy the active frame of all layers (even if the layer is hidden).
2022-03-31Cleanup: spelling, trailing space for comment-blocksCampbell Barton
2022-03-09Fix T96233: Crash with gpencil data with vertex groupsFalk David
Blender crashes when a multi-user grease pencil object has vertex groups and is modified by modifiers, layer transform or parenting. The fix makes sure that we copy the vertex group names list. Reviewed By: antoniov Maniphest Tasks: T96233 Differential Revision: https://developer.blender.org/D14275
2022-03-09Cleanup: use ELEM macroCampbell Barton
2022-03-07Cleanup: quiet warningsCampbell Barton
2022-03-07Improve multi-user gpencil data performance with modifiersYann Lanthony
When a grease pencil data-block has multiple users and is subject to modifiers, layer transforms or parenting, performance (especially playback) is greatly affected. This was caused by the grease pencil eval process which does per instance full-copies of the original datablock in case those kinds of transformations need to be applied. This commit changes the behavior of the eval process to do shallow copies (layers with empty frames) of the datablock instead and duplicates only the visible strokes. When we need to have a unique eval data per instance, only copy the strokes of visible frames to this copy. Performance: On a test file with 1350 frames 33k strokes and 480k points in a single grease pencil object that was instanced 13 times: - master: 2.8 - 3.3 fps - patch: 42 - 52 fps Co-authored by: @filedescriptor This patch was contributed by The SPA Studios. Reviewed By: #grease_pencil, pepeland Differential Revision: https://developer.blender.org/D14238
2022-03-03Fix T96145: GPencil eval data not updated correctlyFalk David
When removing a modifier, changing the layer transform or updating the parent of a grease pencil object that has a multi-user datablock and animation data, the eval data is not updated properly (after a frame change). This can also cause memory leaks. The fix makes sure that we free and reset any runtime copy (`ob->runtime.gpd_eval`) in `BKE_gpencil_prepare_eval_data`. Note: As far as we can tell, `ob->runtime.gpd_orig` is unused and could be removed. The assignment in `BKE_gpencil_prepare_eval_data` seemed to be unnecessary. Co-authored-by: @yann-lty Reviewed By: antoniov Maniphest Tasks: T96145 Differential Revision: https://developer.blender.org/D14236
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: move public doc-strings into headersCampbell Barton
Some recent changes re-introduced public-style doc-strings in the source file.
2021-12-14Cleanup: resolve parameter mis-matches in doc-stringsCampbell Barton
Renamed or removed parameters which no longer exist.
2021-12-13GPencil: New Shrinkwrap modifierAntonio Vazquez
his new modifier is equals to the existing mesh modifier but adapted to grease pencil. The underlying functions used to calculate the shrink are the same used in meshes. {F11794101} Reviewed By: pepeland, HooglyBoogly Differential Revision: https://developer.blender.org/D13192
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-09-24Cleanup: spelling in commentsCampbell Barton
2021-09-23Cleanup: spelling in commentsCampbell Barton
2021-09-16GPencil: Fix dash modifier reading error.YimingWu
The reference for parent modifier in segment data is not assigned. Now fixed.
2021-09-15GPencil: Dot dash modifier.YimingWu
Create dot-dash effect for grease pencil strokes. User can manually edit the length, gap and styles for each segment of dashed lines. The values in each segment can all be key-framed to make animations. Reviewed By: Hans Goudey (HooglyBoogly), Antonio Vazquez (antoniov) Differential Revision: http://developer.blender.org/D11876
2021-08-31Fix T91060: GPencil Time Offset Modifier breaks evaluation timePhilipp Oeser
Caused by {rBf3bf87e5887c}. When using a GPencil Time Offset Modifier, the bGPDlayer>actframe can be NULL. This can be determined though, but above optimization commit skipped getting the active frame in this case entirely (with the intention to only get it if framenumbers did not match). Now also call BKE_gpencil_layer_frame_get() if actframe is NULL in order to fetch a valid one if present. Maniphest Tasks: T91060 Differential Revision: https://developer.blender.org/D12355
2021-08-26Cleanup: Use `ID_IS_LINKED` instead of direct `id.lib` pointer check.Bastien Montagne
2021-07-16Cleanup: remove redundant parenthesesCampbell Barton
2021-07-14Fix T89849: Time offset not working with Bake Object transform to Grease pencilAntonio Vazquez
The bake animation was not using the remap of time done by grease pencil time modifier.
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-18Cleanup: clang-tidyCampbell Barton
2021-06-16LineArt: Cached calculation for modifiers in the same stack.YimingWu
This allows line art to run only once for each modifier stacks, with an option to toggle a specific line art modifier should use cache or re-do their own calculations. Reviewed By: Sebastian Parborg (zeddb), Hans Goudey (HooglyBoogly) Differential Revision: https://developer.blender.org/D11291
2021-05-02GPencil: Fix unreported problem when save file in Curve Edit modeAntonio Vazquez
This is related to T87905
2021-05-01Fix T87905: GPencil modifiers not applied if saved with multiframeAntonio Vazquez
When saving a file in Edit mode with Multiframe enabled, the render did not include the modifiers. Now the multiframe is not enabled if it's doing a render.
2021-04-09Cleanup: use our own code style for doxy-gen comment blocksCampbell Barton
2021-02-18GPencil: Small frame evaluation speed up improvementAntonio Vazquez
Avoid look for frame if the actual frame is already available.
2021-01-16GPencil: Add new parameteres to transform layersAntonio Vazquez
When using grease pencil for drawing Storyboards, it's very common to require a transform of the layers. This transform can be done using the offset modifier, but in some cases, the scene requires a lot of modifiers and makes the file hard to work. This new feature adds a transforms Location, Rotation and Scale at Layer level, and allows to transform the layer without using a modifier, keeping the scene more clean. {F9480695} This feature was suggested by @pepeland after receiving feedback from several artists. Also, done some code cleanup and rename some functions to get a better naming. Maniphest Tasks: T83660 Differential Revision: https://developer.blender.org/D9761
2020-12-15Cleanup: doxy comments (use colon after parameter name)Campbell Barton
Also remove colon after `\note`.
2020-12-08LibOverride: Refactor collection items 'local' helper functions.Bastien Montagne
It's easier to read and less 'weird' to check that an item is non-local in a liboverride data-block, than the other way around. Thanks to @sybren for noticing it.
2020-12-07LibOverride: Abstract a bit handling of local items of RNA collections.Bastien Montagne
RNA collections that support insertion of new items in liboverride data-block need a special way to distiguish between locale and orig-from-linked items (since some operations are allowed on the forer, but no the latter). In future we want a proper solution to abstract that at the `BKE_lib_override` level, but for now we need to add some code for each case. Note that this commit also fixes a few potential issues with GPencil modifiers, and constraints, regarding their handling of local overrides.
2020-11-13GPencil: Merge GSoC curve edit modeFalk David
Differential Revision: https://developer.blender.org/D8660 This patch is the result of the GSoC 2020 "Editing Grease Pencil Strokes Using Curves" project. It adds a submode to greasepencil edit mode that allows for the transformation of greasepencil strokes using bezier curves. More information about the project can be found here: https://wiki.blender.org/wiki/User:Filedescriptor/GSoC_2020.
2020-11-06Refactor: move gpencil modifier .blend I/O to blenkernelJacques Lucke
Ref T76372.
2020-10-30Cleanup: Use an enum to set instanced panel expansionHans Goudey
This commit uses an enum to access expansion for specific panels for each modifier, constraint, etc. Even though these values are quite simple, this can help make the code more explicit when the ui_expand_flag is accessed directly. Also update comments about this bitfield to make them consistent.
2020-10-28Outliner: Properties editor sync on selectionNathan Craddock
When outliner datablocks are selected, switch to the corresponding tab for that datablock in properties editors. Only properties editors that share an edge with the outliner will change tabs. Additionally, when modifiers, constraints, and shader effects are selected from the outliner, the panel will be expanded in all properties editors. Part of T77408 Manifest Task: https://developer.blender.org/T63991 Differential Revision: https://developer.blender.org/D8638
2020-10-07Refactor `BKE_id_copy_ex` to return the new ID pointer.Bastien Montagne
Note that possibility to pass the new ID pointer as parameter was kept, as this is needed for some rather specific cases (like in depsgraph/COW, when copying into already allocated memory). Part of T71219.
2020-10-01remove foreachObjectLink callbackJacques Lucke
This removes `foreachObjectLink` from `ModifierTypeInfo`, `GpencilModifierTypeInfo` and `ShaderFxTypeInfo`. There is no need to have both, `foreachObjectLink` and `foreachIDLink`. There is not code that actually depends on `foreachObjectLink`. Reviewers: brecht Differential Revision: https://developer.blender.org/D9078
2020-09-03Fix T63125: Gpencil: bones cannot be selected in weightpaint modePhilipp Oeser
Some underlying functionality was not ready for greasepencil: - BKE_modifiers_get_virtual_modifierlist (now introduce dedicated BKE_gpencil_modifiers_get_virtual_modifierlist) - BKE_modifiers_is_deformed_by_armature - checks in drawing code - checks in (pose) selection code A couple of changes to make this work: - `eGpencilModifierType_Armature` has to be respected (not only `eModifierType_Armature`) - `OB_MODE_WEIGHT_GPENCIL` has to be respected (not only `OB_MODE_WEIGHT_PAINT`) -- (now use new `OB_MODE_ALL_WEIGHT_PAINT`) - `gpencil_weightmode_toggle_exec` now shares functionality from `wpaint_mode_toggle_exec` -- moved to new `ED_object_posemode_set_for_weight_paint` This patch will also set the context member "weight_paint_object" for greasepencil (otherwise some appropriate pose operators wont work when in weightpaint mode) Reviewed By: campbellbarton Maniphest Tasks: T63125 Differential Revision: https://developer.blender.org/D8483
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-06Cleanup: spelling, commentsCampbell Barton
2020-07-03GPencil: Cleanup more comments (cont)Antonio Vazquez
2020-07-03GPencil: Cleanup move functions to geom from modifierAntonio Vazquez
2020-07-03GPencil: Cleanup Doxygen comments (cont)Antonio Vazquez
2020-06-28GPencil: Cleanup - replace loop with LISTBASE_FOREACHAntonio Vazquez