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-07-02GPencil: New modifier to generate weights dynamicallyAntonio Vazquez
his new modifier allows to generate weights base on: * Angle of the stroke relative to object or world orientation. For example, if the value is 90, the maximum weights will be for vertical lines and minimum for horizontal lines. * Distance to Target object. The distance calculated is normalized to get valid weights between 0 and 1.0. The weights are created in an existing vertex group and the data can be replaced or mixed with the existing value to combine different weight effects. The minimum parameter, allows to define the minimum weight generated. This is useful to avoid very low weights. The generated weights can be used in any modifier. For example, the angle weight value can be used to mimic FreeStyle Caligraphy modifier using the weight with the thickness modifier. Also some modifier has been changed to inlude a new option to use the weights as factor of the effect. As result of this change, the fading option has been removed from Thickness and Opacity modifiers because this can be done using the new modifier, it's not logic to repeat the same. Reviewed By: mendio, filedescriptor Differential Revision: https://developer.blender.org/D11604
2021-06-04GPencil: Cleanup unneeded variable assignAntonio Vazquez
The variable is assigned below again and the initial value is not used.
2021-04-28Cleanup: Add float formatAntonio Vazquez
2021-04-28GPencil: Fading based on distance to reference object in Opacity and ↵YimingWu
Thickness modifiers This patch allows you to dynamically control stroke's opacity and thickness using an object for distance reference in the modifier. Fading range is adjustable, and it is compatible with current curve/vertex group selection. Reviewed By: #grease_pencil, antoniov, mendio Maniphest Tasks: T82177, T80194 Differential Revision: https://developer.blender.org/D9091
2021-03-21Cleanup: redundant headers in 'source/blender/gpencil_modifiers'Campbell Barton
2020-10-15Cleanup: Use DNA defaults for grease pencil modifiersHans Goudey
This will make "Reset to Default Value" work properly for grease pencil modifiers. See T80164 for more information.
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 T80289: GPencil Opacity modifier not workingAntonio Vazquez
This error was introduced in the refactor of the modifier panels.
2020-09-02UI: Use instanced panel custom data instead of list indexHans Goudey
For modifier shortcuts we added a "custom_data" field to panels. This commit uses the same system for accessing the list data that corresponds to each panel. This way the context is only used once and the modifier for each panel can be accessed more easily later. This ends up being mostly a cleanup commit with a few small changes in interface_panel.c. The large changes in the UI functions are due to the fact that the panel custom data is now passed around as a single pointer instead of being created again for every panel. The list_index variable in Panel.runtime is removed as it's now unnecessary. Differential Revision: https://developer.blender.org/D8559
2020-08-01Cleanup: use term init instead of initialize/initialiseCampbell Barton
The abbreviation 'init' is brief, unambiguous and already used in thousands of places, also initialize is often accidentally written with British spelling.
2020-06-19UI: Grease Pencil Modifier Drag and Drop, Layout ChangesHans Goudey
This patch implements the list panel system D7490 for grease pencil modifiers. It also moves their drawing to a callback in GpencilModifierTypeInfo in line with the extensible architecture refactoring goal T75724. This also adds the "set_error" function for grease pencil modifiers, which hadn't been copied from mesh modifiers yet. The implementation is basically exactly the same as for the modifier patch (9b099c86123fc82). Thanks to Matias Mendiola (mendio) for providing mockups for many of the layout changes. Differential Revision: https://developer.blender.org/D7978
2020-05-11GPencil: Cleanup unneeded initializationsAntonio Vazquez
2020-05-11GPencil: Replace material name with material pointer for Modifiers filterAntonio Vazquez
Before, the material name was used to filter the effect of the stroke, but after the last changes in the ID code, now it's not working. After talking with @severin, we agreed to replace the material name with a pointer. Also, this fix a design issue when the materials were linked. Related to T76594 Differential Revision: https://developer.blender.org/D7681 with some minor changes
2020-05-09Cleanup: double-spaces in commentsCampbell Barton
2020-05-08GPencil: Refactor - Rename modifier and shder functionsAntonio Vazquez
This change is to align names with changes in T76498
2020-04-01GPencil: Cleanup typo errorAntonio Vazquez
2020-04-01Grease Pencil: Fix typo in labels and comments.Pablo Vazquez
Hardeness -> Hardness Only changed the labels/tooltips, will leave the internal change to @antoniov.
2020-03-21GPencil: New Hardeness mode for Opacity modifierAntonio Vazquez
Add new option to change the stroke hardeness. This option works at stroke level, not at point level. Also replaced the "Both" name mode by "Stroke and Fill". Differential Revision: https://developer.blender.org/D7195
2020-03-19Cleanup: `make format` after SortedIncludes changeDalai Felinto
2020-03-09GPencil: Refactor of Draw Engine, Vertex Paint and all internal functionsAntonio Vazquez
This commit is a full refactor of the grease pencil modules including Draw Engine, Modifiers, VFX, depsgraph update, improvements in operators and conversion of Sculpt and Weight paint tools to real brushes. Also, a huge code cleanup has been done at all levels. Thanks to @fclem for his work and yo @pepeland and @mendio for the testing and help in the development. Differential Revision: https://developer.blender.org/D6293
2020-03-06Cleanup: use 'BKE_' prefix for BKE_deform API callsCampbell Barton
- Use 'BKE_object_defgroup' prefix for object functions. - Rename 'defvert_verify_index' to 'defvert_ensure_index' since this adds the group if it isn't found.
2020-02-05T73589: Code Quality: Renaming on BKE_material.hAntonio Vazquez
Old Name New Name ========= ========= init_def_material BKE_materials_init BKE_material_gpencil_default_free BKE_materials_exit test_object_materials BKE_object_materials_test test_all_objects_materials BKE_objects_materials_test_all give_matarar BKE_object_material_array give_totcolp BKE_object_material_num give_current_material_p BKE_object_material_get_p give_current_material BKE_object_material_get assign_material BKE_object_material_assign assign_matarar BKE_object_material_array_assign give_matarar_id BKE_id_material_array give_totcolp_id BKE_id_material_num assign_material_id BKE_id_material_assign clear_matcopybuf BKE_material_copybuf_clear free_matcopybuf BKE_material_copybuf_free copy_matcopybuf BKE_material_copybuf_copy paste_matcopybuf BKE_material_copybuf_paste BKE_material_init_gpencil_settings BKE_gpencil_material_attr_init BKE_material_add_gpencil BKE_gpencil_material_add BKE_material_gpencil_get BKE_gpencil_material BKE_material_gpencil_default_get BKE_gpencil_material_default BKE_material_gpencil_settings_get BKE_gpencil_material_settings
2019-10-04GPencil: Reduce VBO memory footprint when using modifiersAntonio Vazquez
Before, the modifiers were evaluated in Draw Engine and this required to calculate a factor to increase the VBO size. Now, the modifiers are evaluated in Depsgraph and the Draw Engine receives the evaluated stroke with the final number of vertices. As the number of vertices is the final value already, if Draw Manager increases the number with the modifiers only increases the memory with empty space because never would be used. This commit removes this double calculation, reducing the memory usage and removes a loop to calculate the size by modifier too. Also, the function getDuplicationFactor() has been removed because is not required anymore.
2019-09-02GPencil: New Strength mode for Opacity modifierAntonio Vazquez
This new option applies the opacity using the strength of the stroke instead to use the alpha channel of the material. Tested in greasepencil-object branch {F7712796} The vertex group filter has been removed because this filter is not logic in Material mode and must be valid only in Strength mode. {F7713147} Reviewers: pepeland, mendio Reviewed By: mendio Differential Revision: https://developer.blender.org/D5650
2019-09-01Fix T69364: GPencil Array Modifiers causes crashAntonio Vazquez
This bug was introduced when adding the support for default materials.
2019-08-21GPencil: add new filter by material to modifiersMatias Mendiola
This commit adds a new filter by material using the name and not only the index. Reviewers: antoniov, pepeland Differential Revision: https://developer.blender.org/D5544
2019-08-02GPencil: Add Frame parameter to modifier deformStroke CallbackAntonio Vazquez
This commit adds the frame to deformStroke Callback as a preparation for new modifiers that will need this variable. Actually, the existing modifiers are not using the frame.
2019-04-22Cleanup: style, use braces for gpencil modifiersCampbell 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-25Cleanup: order of modifiers' headers includes.Bastien Montagne
BLI should always comes first, before DNA, BKE etc. And `BLI_utildefines.h` should come before any other BLI (since it's some sort of system include really, among other things...). Thisi should help to reduce the noise in patches when adding stuff like uint64_t members to DNA structs... ;)
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-20GP: Refactor drawing engine to single VBOAntonioya
This is part of T57829. Reduce the number of batches used to only one by shader type. This reduces GPU overhead and increase a lot the FPS. As the number of batches is small, the time to allocate and free memory was reduced in 90% or more. Also the code has been simplified and all batch management has been removed because this is not necessary. Now, all shading groups are created after all vertex buffer data for all strokes has been created using DRW_shgroup_call_range_add(). All batch cache data has been moved to the Object runtime struct and not as before where some parts (derived data) were saved inside GPD datablock. For particles, now the code is faster and cleaner and gets better FPS. Thanks to Clément Foucault for his help and advices to improve speed.
2018-10-31Cleanup: indentationCampbell Barton
2018-10-24GP: Add new Layer Pass Index filter to modifiersAntonioya
Now the modifier can be filtered using the new layer index. Also changed panels to put layers and passes filter always at the end of the panel.
2018-10-22GP: New Time modifierAntonioya
This modifier allows to offset the keyframe animated to get more variations in the animation when reuse the same datablock.
2018-09-19GP: Verify weight data is correct before assigningAntonioya
2018-08-28Cleanup: indentationCampbell Barton
2018-08-27Cleanup: rename 'vindex' to 'def_nr'Campbell Barton
Name hinted 'vertex index', where it's the index of the vertex group.
2018-08-09GP: Add option to select color affected in modifiersCharlie Jolly
Now it's possible to define if the Tint, Hue and OPacity modifier affect the stroke color, fill color or both.
2018-08-08GP: Fix modifiers Tint, Opacity and Hue and create materials to OpacityAntonioya
Thanks to Charlie Jolly (mistajolly@gmail.com) for his patch D3586 that added create materials to opacity modifier. I had to do some more changes to get all running.
2018-07-31Cleanup: Fix weird comparisonsAntonioya
2018-07-31Cleanup: style, duplicate includesCampbell Barton
2018-07-31New Grease Pencil object for 2D animationAntonioya
This commit merge the full development done in greasepencil-object branch and include mainly the following features. - New grease pencil object. - New drawing engine. - New grease pencil modes Draw/Sculpt/Edit and Weight Paint. - New brushes for grease pencil. - New modifiers for grease pencil. - New shaders FX. - New material system (replace old palettes and colors). - Split of annotations (old grease pencil) and new grease pencil object. - UI adapted to blender 2.8. You can get more info here: https://code.blender.org/2017/12/drawing-2d-animation-in-blender-2-8/ https://code.blender.org/2018/07/grease-pencil-status-update/ This is the result of nearly two years of development and I want thanks firstly the other members of the grease pencil team: Daniel M. Lara, Matias Mendiola and Joshua Leung for their support, ideas and to keep working in the project all the time, without them this project had been impossible. Also, I want thanks other Blender developers for their help, advices and to be there always to help me, and specially to Clément Foucault, Dalai Felinto, Pablo Vázquez and Campbell Barton.