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-03-26Cleanup: spellingCampbell Barton
2021-03-24GPencil: New modules for Import and ExportAntonio Vazquez
This patch adds support to export and import grease pencil in several formats. Inlude: * Export SVG * Export PDF (always from camera view) * Import SVG The import and export only support solid colors and not gradients or textures. Requires libharu and pugixml. For importing SVG, the NanoSVG lib is used, but this does not require installation (just a .h file embedded in the project folder) Example of PDF export: https://youtu.be/BMm0KeMJsI4 Reviewed By: #grease_pencil, HooglyBoogly Maniphest Tasks: T83190, T79875, T83191, T83192 Differential Revision: https://developer.blender.org/D10482
2021-02-20Cleanup: Split grease pencil selection index functionsAntonio Vazquez
This makes the code more readable.
2021-02-19GPencil: Interpolate Tools refactorAntonio Vazquez
Following with the changes included to interpolate strokes of different number of points, a full review has been done in the interpolation tools. * Interpolate now is a tool and not an operator. It was not logic to have this tool as a button. * Interpolate tool parameters have been moved to topbar. * Interpolate popover has been removed from topbar and interpolate `Sequence` operator has been moved to grease pencil menu. * Interpolate Sequence now include a Redo panel. * Interpolate tool now allows to select the strokes by pairs. This allows to interpolate any stroke with any stroke and not as before that it was only possible by drawing order. If no stroke is selected, the interpolation is done as before. * Now is possible interpolate again if a previous keyframe exist. Before, it was impossible to interpolate two times in same frame and this made impossible to do the interpolation by groups of frames. * New automatic option to `Flip strokes` if the stroke and end are not in the right position. Also the flip can be set manually for corner cases. * Cleanup of menus related to interpolate. * Fixed some bugs and removed parameters from scene because now all are tool or operator contained. * Some code cleanup and function renames. This commit also includes the some codebase to future implementation of the concept `Vertex Active` that now does not exist in grease pencil.
2021-02-09GPencil: Fill tool refactor and Multiframe in Draw modeAntonio Vazquez
This commit is a refactor of the fill tool to solve several problems we had since the first version of the tool. Changes: * The filling speed has been improved for each step of the process with the optimization of each algorithm/function. * New `AutoFit` option to fill areas outside of the viewport. When enable, the total size of the frame is calculated to fit the filling area. * New support multiframe filling. Now it is possible to fill multiple similar frames in one go. * New `Stroke Extension` option to create temporary closing strokes. These strokes can be displayed and adjusted dynamically using wheel mouse or PageUp/Down keys. * Parameter `Resolution` now is named `Precision` and has been moved to topbar. * `Resolution` now has decimals and can be lower than 1 to allow quick filling in storyboarding workflows. Maximum value has been set as 5. * Parameter `Simplify` has been moved to Advanced panel. * Improved fill outline detection. In some cases, the outline penetrated the area to be filled with unexpected results. * Fixes some corner case bugs with infinite loops. As a result of this refactor, also these new functionalities has been added. * New support for multiframe in `Draw` mode. Any drawing in active frame is duplicated to all selected frame. * New multiframe display mode. Keyframes before or after of the active frame are displayed using onion colors. This can be disable using Onion overlay options.
2021-02-06Cleanup: malformed web addresses in commentsCampbell Barton
2020-12-15Cleanup: spellingCampbell Barton
2020-12-15Cleanup: reduce indirect DNA header inclusionCampbell Barton
Remove DNA headers, using forward declarations where possible. Also removed duplicate header, header including it's self and unnecessary inclusion of libc system headers from BKE header.
2020-12-12GPencil: Add uniform subdivide BKE to improve interpolationFalk David
This patch introduces a new BKE function that performs a uniform subdivide. The goal of this function is to subdivide the stroke to reach a target number of points while maintaining its shape, color, and weights. This is done by repeatedly subdividing the longest edge in the stroke. Every subdivision adds a new point at the exact middle point of an edge. The function is intended to be used in the interpolation operators to give better results when interpolating between different sized strokes. Reviewed By: antoniov Differential Revision: https://developer.blender.org/D9835
2020-11-18GPencil: Automerge last drawn stroke with previous strokesAntonio Vazquez
This option joins any stroke with an end near the actual stroke. Now it is not limited to the last stroke, any stroke in the same layer for the actual frame can be joined. The join can join two strokes drawing a third stroke. If the end and the start of the result stroke are very small, the stroke is changed to be cyclic automatically. There is a limit distance to join the stroke, if the distance is greater than this value, the strokes are not joined. Actually, a constant, threshold distance is used, but we could expose as a parameter in the UI in the future. The tool can be used with freehand drawing or with primitives. Note: Great part of the patch is just a refactor of the old code to make it accessible and to keep code organized. Reviewed By: mendio Maniphest Tasks: T82377 Differential Revision: https://developer.blender.org/D9440
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-06Cleanup: use ELEM macroCampbell Barton
2020-09-14Fix T79651: Bounding box is wrong after duplicate objectAntonio Vazquez
The bounding box is not updated in the original object when the function is called using evaluated object and keeps wrong while the object is not edited or the file saved. Reviewed By: mont29 Differential Revision: https://developer.blender.org/D8565 Notes: Minor changes done in the patch following review comments.
2020-09-11Cleanup: const cast warning, use string replace functionCampbell Barton
2020-09-10Fix T80191: GPencil - Improve Mesh conversionAntonio Vazquez
There were some problems when converted several objects at the same time, especially with the material conversion. The problems were more visible when bake an animation with several objects at the same time. * Now the layer name include the object name. * Reorganize how the materials are generated including object name. * Fix color not converted to sRGB. * Avoid triangles when generate the stroke. This fix a draw manager issue and also add more geometry to use later. * Code cleanup.
2020-09-09Cleanup: reduce variable scopesJacques Lucke
2020-08-27GPencil: Don't convert color to sRGBAntonio Vazquez
The color is linear, so the conversion is breaking the real color.
2020-08-08Cleanup: use array syntax for sizeof with fixed valuesCampbell Barton
Also order sizeof(..) first to promote other values to size_t.
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-08-02Cleanup: pass const matricesCampbell Barton
Also order return matrices last.
2020-07-24GPencil: Add more randomness to random stroke colorAntonio Vazquez
The old method produce a small range of similar colors.
2020-07-22GPencil: New BKE function for setting random vertex colorAntonio Vazquez
This function is very handy for debug purposes.
2020-07-21Fix T72621: Transform object origin support for grease-pencilSebastian Parborg
Added support for transforming only origins with greasepencil objects. The new functions is based on BKE_gpencil_transform. That is why there is FIXME statements in there. Reviewed By: Campbell, Antonio Differential Revision: http://developer.blender.org/D8303
2020-07-16Cleanup: minor change to grease pencil material accessCampbell Barton
Rename for clarity and avoid passing in the prefix length.
2020-07-15GPencil: Fix unreported error baking mesh animationAntonio Vazquez
When the mesh is linked, the materials can not be available or be the same assigned to mesh. Now, if the mesh is linked, a simple two materials conversion is used. To get the full list of materials, the mesh must not be linked. Also checked some indexes to be sure never get a wrong value and that materials are not created again and again.
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-06Cleanup: spelling, commentsCampbell Barton
2020-07-04Cleanup: Fix small typo errorAntonio Vazquez
2020-07-04GPencil: Cleanup some comments typoAntonio Vazquez
2020-07-03GPencil: Cleanup more comments (cont)Antonio Vazquez
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 commentsAntonio Vazquez
2020-07-02Fix T76886: GPencil - Flickering when use Background or Camera imageAntonio Vazquez
The problem was if some stroke was empty and the changed flag was set to the last stroke wrongly.
2020-06-29Fix T78401: Convert Mesh to Grease Pencil with empty material slot crashesPhilipp Oeser
Also create the 'simple fill' in case there are only empty material slots. Maniphest Tasks: T78401 Differential Revision: https://developer.blender.org/D8151
2020-06-17Cleanup: doxy commentsCampbell Barton
2020-06-17Cleanup: warningCampbell Barton
2020-06-16GPencil: Convert and Bake mesh animation to grease pencil strokesAntonio Vazquez
This patch adds two options: - Convert a mesh to grease pencil strokes. - Bake the mesh animation into grease pencil strokes. Both are related and must be included in the same patch. Related to tasks: T77629 and T77630 Notice: The conversion is done for mesh edges and it's not considering any visibility clipping. All edges are exported, no matters if it's visible or not. Example of Convert a Mesh to Grease Pencil strokes: {F8606028} This conversion was inspired by the technique used by @luamono in this tweet: https://twitter.com/luamono/status/1239983662176841730 Example of Bake Animation (the video is a little outdate, but the basic functionality is the same, only small changes in UI): {F8606032} Reviewed By: mendio, pepeland Maniphest Tasks: T77629, T77630 Differential Revision: https://developer.blender.org/D7983
2020-05-06GPencil: Split Curve geometry functions to new fileAntonio Vazquez
This prepare the code for future curve editors
2020-04-29Fix T76185: GPencil from Curve ignores Cyclic when curve has only 2 pointsAntonio Vazquez
Also changed default thickness to 10 because after draw engine refactor the final line was too thin.
2020-04-03Code Quality: Replace for loops with LISTBASE_FOREACHDalai Felinto
Note this only changes cases where the variable was declared inside the for loop. To handle it outside as well is a different challenge. Differential Revision: https://developer.blender.org/D7320
2020-03-29Cleanup: spelling, commentsCampbell Barton
2020-03-21Cleanup: compiler warningsBrecht Van Lommel
2020-03-19GPencil: Cleanup - Split BKE_gpencil.h geometry functions into ↵Antonio Vazquez
BKE_gpencil_geom.h This split prepare the code for future geometry functions.