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-02-10Rebase on mastertemp-license-header-spdxCampbell Barton
2021-08-04Cleanup: rename restrict to hide/visibility in Object, Collection, MaskLayerBrecht Van Lommel
This makes the internal naming consistent with the public API. And also gives us a visibility_flag rather than restrictflag that can be extended with more flags.
2021-07-20Cleanup: use '#if 0' for disabling multiple linesCampbell Barton
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2021-03-29Fix T76872: Mask created after existing keyframe gets broken handlesSergey Sharybin
The issue was caused by handles not being written to the new mask spline shape: it was always written as (0, 0), which was making the handle calculation go wrong later on. Solved by allocating a temporary array of bezier points and calculating handles for them. While this is an extra array allocation it is only done for a small amount of points and it is not in the critical code path. Having this as an extra array helps to overcome a limitation of the current mask shape API. Additionally, disable the interpolation for the shape change: the spline is brand new, there is nothing to be interpolated there.
2021-01-26Fix T84850: "Lock to Selection" causes unwanted jumpsSergey Sharybin
Adding new tracks, mask points, mask primitives, changing selection was causing an unwanted jumps in the view. This change makes it so those operations are preserving view offset. Differential Revision: https://developer.blender.org/D10146
2020-11-06Cleanup: use ELEM macroCampbell Barton
2020-10-19Spelling: Then Versus ThanHarley Acheson
Corrects incorrect usages of the words 'then' and 'than'. Differential Revision: https://developer.blender.org/D9246 Reviewed by Campbell Barton
2020-09-09Cleanup: reduce variable scopeJacques Lucke
2020-08-28Fix T80064: Adding mask curve points doesn't work around endpointsGermano Cavalcante
2020-08-08Cleanup: use array syntax for sizeof with fixed valuesCampbell Barton
Also order sizeof(..) first to promote other values to size_t.
2020-07-13Clang Tidy: enable readability-non-const-parameter warningJacques Lucke
Clang Tidy reported a couple of false positives. I disabled those `NOLINTNEXTLINE`. Differential Revision: https://developer.blender.org/D8199
2020-07-03Cleanup: Editors, 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/editors` module. No functional changes.
2020-04-03Cleanup: Rename ScrArea variables from sa to areaJulian Eisel
Follow up of b2ee1770d4c3 and 10c2254d412d, part of T74432. Now the area and region naming conventions should be less confusing. Mostly a careful batch rename but had to do few smaller fixes. Also ran clang-format on affected files.
2020-03-27Cleanup: redundant mask includesCampbell Barton
2020-03-25Cleanup: move mask queries into own fileCampbell Barton
Similar functions to lookup nearest mask points were in mask_add.c & mask_edit.c
2020-03-25Cleanup: use 'r_' prefix for output argumentsCampbell Barton
Also pass some args as 'const'.
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-06Cleanup: Rename ARegion variables from ar to regionJulian Eisel
The old convention was easy to confuse with ScrArea. Part of https://developer.blender.org/T74432. This is mostly a batch rename with some manual fixing. Only single word variable names are changed, no prefixed/suffixed names. Brecht van Lommel and Campbell Barton both gave me a green light for this convention change. Also ran clan clang format on affected files.
2019-11-04Nasking: Toggle cyclic on Ctrl-Click on initial vertexSergey Sharybin
This change replaces old behavior when spline was toggled as cyclic on double-click. Doing so was tricky on a tablet and is rather non-intuitive in general. Differential Revision: https://developer.blender.org/D6162
2019-11-04Masking: Cleanup, naming of mask layerSergey Sharybin
2019-09-07Cleanup: use post increment/decrementCampbell Barton
When the result isn't used, prefer post increment/decrement (already used nearly everywhere in Blender).
2019-07-31Refactor access to dependency graphSergey Sharybin
This change ensures that operators which needs access to evaluated data first makes sure there is a dependency graph. Other accesses to the dependency graph made it more explicit about whether they just need a valid dependency graph pointer or whether they expect the graph to be already evaluated. This replaces OPTYPE_USE_EVAL_DATA which is now removed. Some general rules about usage of accessors: - Drawing is expected to happen from a fully evaluated dependency graph. There is now a function to access it, which will in the future control that dependency graph is actually evaluated. This check is not yet done because there are some things to be taken care about first: for example, post-update hooks might leave scene in a state where something is still tagged for update. - All operators which needs to access evaluated state must use CTX_data_ensure_evaluated_depsgraph(). This function replaces OPTYPE_USE_EVAL_DATA. The call is generally to be done in the very beginning of the operator, prior other logic (unless this is some comprehensive operator which might or might not need access to an evaluated state). This call is never to be used from a loop. If some utility function requires evaluated state of dependency graph the graph is to be passed as an explicit argument. This way it is clear that no evaluation happens in a loop or something like this. - All cases which needs to know dependency graph pointer, but which doesn't want to actually evaluate it can use old-style function CTX_data_depsgraph_pointer(), assuming that underlying code will ensure dependency graph is evaluated prior to accessing it. - The new functions are replacing OPTYPE_USE_EVAL_DATA, so now it is explicit and local about where dependency graph is being ensured. This commit also contains some fixes of wrong usage of evaluation functions on original objects. Ideally should be split out, but in reality with all the APIs being renamed is quite tricky. Fixes T67454: Blender crash on rapid undo and select Speculation here is that sometimes undo and selection operators are sometimes handled in the same event loop iteration, which leaves non-evaluated dependency graph. Fixes T67973: Crash on Fix Deforms operator Fixes T67902: Crash when undo a loop cut Reviewers: brecht Reviewed By: brecht Subscribers: lichtwerk Maniphest Tasks: T67454 Differential Revision: https://developer.blender.org/D5343
2019-07-08Cleanup: Spelling in function nameSergey Sharybin
2019-05-23Masks: Properly port to Copy-on-Write conceptSergey Sharybin
Masks were not really covered by Copy-on-Write due to mistake in the dependency graph. After correcting that mistake a lot of tools became broken, so majority of the patch is related on making it so access to evaluated/tessellated masks is done. When accessing evaluated mask state make sure access to an evaluated dependency graph is done. This solves possible access to NULL data on redo. Fixes T64899: Re-doing new point addition causes crash Reviewers: brecht Reviewed By: brecht Maniphest Tasks: T64899 Differential Revision: https://developer.blender.org/D4918
2019-04-22Cleanup: style, use braces for editorsCampbell 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-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-04Outliner: better support for clips/masks ('Blender File' view)Philipp Oeser
- clips/masks were not showing an icon [both dont have a dedicated icon, took the ones used elsewhere] - masks hit an assert in outliner_add_element() - missing outliner update when adding a mask spotted while looking into T59939 Reviewers: mont29, brecht Differential Revision: https://developer.blender.org/D4142
2018-08-143D View boarder/lasso select tool optionsCampbell Barton
Add tool options to control how select operates (add/sub/set/and/xor). Note: edit mode armature select still needs to support all options, this is complicated by how it handles partial end-point selection.
2017-06-08Replace all old DAG calls with direct calls to new DEG and remove ↵Luca Rood
BKE_depsgraph.h This removes BKE_depsgraph.h and depsgraph.c
2017-05-05Masks: Fix broken animation after adding primitivesSergey Sharybin
Was missing mask shape initialization. Not ideal from the CPU ticks point of view, but will work for now.
2016-12-02Fix T50062: Mask - Clicking in ActivePoint Parent makes Blender crash.Bastien Montagne
Mask primitive adding code was not initializing correctly id_type of points' parents.
2016-04-27Mask: always add a new spline when adding a new vertCampbell Barton
Previously, adding a new vertex with Ctrl-LMB would move an existing when there was an active spline but no active point. This function is used as a fallback, extending an existing active point is already handled.
2016-04-27New mask points now compensate parent offsetCampbell Barton
2016-04-27Fix T48282: Newly added mask points don't follow parentCampbell Barton
2016-04-27Cleanup: use const, duplicate headerCampbell Barton
2015-09-04Quiet warningsJulian Eisel
We had too many warnings lately... was awaiting that someone would kill them - didn't happen -> goes to my commit ratio! :P
2015-03-27Use squared dist /w comparisons (mask, edge-slide)Campbell Barton
2014-10-13Code cleanup: Move output arguments to the end of the listSergey Sharybin
2014-10-13Roto: Improve spline sliding vs. curvature detectionSergey Sharybin
If the mouse is closer to the spline than to it's center do a spline curvature correction operator instead.
2014-04-30Code cleanup: remove unused includesCampbell Barton
Opted to keep includes if they are used indirectly (even if removing is possible).
2014-04-03Slide mask spline segment to define it's curvatureSergey Sharybin
This actually implements the idea used in Gimp which is grabbing an arbitrary point on the spline and dragging it, ensuring spline goes over this point. This is really useful way to tweak spline curvature. Currently only affects on a closest handle, meaning no weighting on changes for both handles which are adjacent to the same segment will happen just yet, Another limitation is that currently such a slide is a big jumpy when you start sliding. This is because projection is not used to calculate u value because projection used to fail a lot for me here and didn't find a nice solution for this yet. But this is to be improved for sure!
2014-03-31Code cleanup: use false/true/bool for maskingSergey Sharybin
2014-03-28Implement asymmetric and free handles type for masksSergey Sharybin
Summary: The title actually says it all, it's just possible to have independent free handles for mask splines. Also it's now possible to have aligned handles displayed as independent handles. Required changes in quite a few places, but they're rather straightforward. From user perspective there's one really visible change which is removed Handle Type menu from the panel. With asymmetric handles it's not clear which handle type to display there. So now the only way to change handle type is via V-key menu. Rewrote normal evaluation function to make it deal with new type of handles we support. Now it works in the following way: - Offset the original spline by maximal weight - Calculate vector between corresponding U positions on offset and original spline - Normalize this vector. Seems to be giving more adequate results and doesn't tend to self-intersect as much as old behavior used to, There're still some changes which needed to be done, but which are planned for further patch: - Support colors and handle size via themes. - Make handles color-coded, just the same as done for regular bezier splines in 3D viewport. Additional changes to make roto workflow even better: - Use circles to draw handles - Support AA for handles - Change click-create-drag to change curvature of the spline instead of adjusting point position. Reviewers: campbellbarton CC: sebastian_k, hype, cronk Differential Revision: http://developer.blender.org/D121
2014-02-03Code cleanup: use bools where possibleCampbell Barton
2013-12-20Don't use with_resol suffix for functions which doesn't get resolutionSergey Sharybin
2013-10-29Code cleanup: use bool instead of int in mask moduleSergey Sharybin