[Bf-blender-cvs] [4885b649ef0] lanpr-under-gp: Merge remote-tracking branch 'origin/master' into lanpr-under-gp
YimingWu
noreply at git.blender.org
Sat Dec 19 05:48:13 CET 2020
Commit: 4885b649ef08abe189ae332fb5fa04fc5ea49698
Author: YimingWu
Date: Sat Dec 19 12:04:26 2020 +0800
Branches: lanpr-under-gp
https://developer.blender.org/rB4885b649ef08abe189ae332fb5fa04fc5ea49698
Merge remote-tracking branch 'origin/master' into lanpr-under-gp
# Conflicts:
# release/datafiles/locale
# release/scripts/addons
# release/scripts/addons_contrib
# source/blender/blenloader/intern/versioning_290.c
# source/blender/makesdna/DNA_brush_types.h
# source/blender/makesdna/DNA_gpencil_modifier_types.h
# source/blender/makesrna/intern/rna_scene.c
# source/tools
===================================================================
===================================================================
diff --cc source/blender/blenloader/intern/versioning_290.c
index 3db14e9e88d,86293f273b3..d008e740f6e
--- a/source/blender/blenloader/intern/versioning_290.c
+++ b/source/blender/blenloader/intern/versioning_290.c
@@@ -1166,16 -1449,6 +1449,17 @@@ void blo_do_versions_290(FileData *fd,
}
}
}
+ FOREACH_NODETREE_END;
+
+ if (!DNA_struct_find(fd->filesdna, "SceneLineArt")) {
+ LISTBASE_FOREACH (Scene *, sc, &bmain->scenes) {
+ sc->lineart.crease_threshold = DEG2RAD(140.0f);
+ sc->lineart.line_types |= LRT_EDGE_FLAG_ALL_TYPE;
+ sc->lineart.flags |= (LRT_ALLOW_DUPLI_OBJECTS | LRT_REMOVE_DOUBLES);
+ sc->lineart.angle_splitting_threshold = DEG2RAD(60.0f);
+ sc->lineart.chaining_geometry_threshold = 0.001f;
+ sc->lineart.chaining_image_threshold = 0.001f;
+ }
+ }
}
}
diff --cc source/blender/blenloader/intern/writefile.c
index 86f069622ce,0a4f2fde93f..c323647053b
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@@ -93,8 -93,8 +93,9 @@@
/* allow writefile to use deprecated functionality (for forward compatibility code) */
#define DNA_DEPRECATED_ALLOW
+ #include "DNA_collection_types.h"
#include "DNA_fileglobal_types.h"
+#include "DNA_lineart_types.h"
#include "DNA_genfile.h"
#include "DNA_sdna_types.h"
diff --cc source/blender/editors/space_api/spacetypes.c
index 329bb7a7633,10fa2c19919..a4e188f642c
--- a/source/blender/editors/space_api/spacetypes.c
+++ b/source/blender/editors/space_api/spacetypes.c
@@@ -64,12 -65,9 +65,13 @@@
#include "ED_space_api.h"
#include "ED_transform.h"
#include "ED_userpref.h"
+ #include "ED_util.h"
#include "ED_uvedit.h"
+#ifdef WITH_LINEART
+# include "ED_lineart.h"
+#endif
+
#include "io_ops.h"
/* only call once on startup, storage is global in BKE kernel listbase */
diff --cc source/blender/makesdna/DNA_gpencil_modifier_types.h
index 8be456b0272,9ac40495887..65972b07d0d
--- a/source/blender/makesdna/DNA_gpencil_modifier_types.h
+++ b/source/blender/makesdna/DNA_gpencil_modifier_types.h
@@@ -803,55 -807,6 +808,59 @@@ typedef enum eTextureGpencil_Mode
STROKE_AND_FILL = 2,
} eTextureGpencil_Mode;
+typedef enum eLineartGpencilModifierSource {
+ LRT_SOURCE_COLLECTION = 0,
+ LRT_SOURCE_OBJECT = 1,
+ LRT_SOURCE_SCENE = 2,
+} eLineartGpencilModifierSource;
+
+typedef enum eLineArtGPencilModifierFlags {
+ LRT_GPENCIL_INVERT_SOURCE_VGROUP = (1 << 0),
+ LRT_GPENCIL_MATCH_OUTPUT_VGROUP = (1 << 1),
+ LRT_GPENCIL_SOFT_SELECTION = (1 << 2),
+} eLineArtGPencilModifierFlags;
+
+typedef enum eLineartGpencilTransparencyFlags {
+ LRT_GPENCIL_TRANSPARENCY_ENABLE = (1 << 0),
+ /** Set to true means using "and" instead of "or" logic on mask bits. */
+ LRT_GPENCIL_TRANSPARENCY_MATCH = (1 << 1),
+} eLineartGpencilTransparencyFlags;
+
+typedef struct LineartGpencilModifierData {
+ GpencilModifierData modifier;
+
+ short line_types; /* line type enable flags, bits in eLineartEdgeFlag */
+
+ char source_type; /* Object or Collection, from eLineartGpencilModifierSource */
+
+ char use_multiple_levels;
+ short level_start;
+ short level_end;
+
+ struct Object *source_object;
+ struct Collection *source_collection;
+
+ struct Material *target_material;
+ char target_layer[64];
+
+ /** These two variables are to pass on vertex group information from mesh to strokes.
+ * vgname specifies which vertex groups our strokes from source_vertex_group will go to. */
+ char source_vertex_group[64];
+ char vgname[64];
+
+ float opacity;
+ short thickness;
+
+ unsigned char transparency_flags; /* eLineartGpencilTransparencyFlags */
+ unsigned char transparency_mask;
+
+ float pre_sample_length;
+
+ /* Additional Switches */
+ int flags;
+
+} LineartGpencilModifierData;
++
+ #ifdef __cplusplus
+ }
+ #endif
diff --cc source/blender/makesdna/DNA_scene_types.h
index 8066b95f152,f73f99eb4e7..4fd93305120
--- a/source/blender/makesdna/DNA_scene_types.h
+++ b/source/blender/makesdna/DNA_scene_types.h
@@@ -33,16 -33,10 +33,11 @@@
#define USE_SETSCENE_CHECK
#include "DNA_ID.h"
- #include "DNA_collection_types.h"
- #include "DNA_color_types.h" /* color management */
- #include "DNA_curveprofile_types.h"
+ #include "DNA_color_types.h" /* color management */
#include "DNA_customdata_types.h" /* Scene's runtime cddata masks. */
- #include "DNA_freestyle_types.h"
#include "DNA_layer_types.h"
+#include "DNA_lineart_types.h"
#include "DNA_listBase.h"
- #include "DNA_material_types.h"
- #include "DNA_userdef_types.h"
#include "DNA_vec_types.h"
#include "DNA_view3d_types.h"
diff --cc source/blender/makesrna/intern/rna_scene.c
index 3a48cacb51c,84222347425..f969f7ef28b
--- a/source/blender/makesrna/intern/rna_scene.c
+++ b/source/blender/makesrna/intern/rna_scene.c
@@@ -4087,8 -4239,8 +4264,9 @@@ void rna_def_view_layer_common(StructRN
prop = RNA_def_property(srna, "use_ztransp", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "layflag", SCE_LAY_ZTRA);
-- RNA_def_property_ui_text(
- prop, "ZTransp", "Render Z-Transparent faces in this Layer (on top of Solid and Halos)");
- prop, "Z-Transparent", "Render Z-transparent faces in this layer (on top of Solid and Halos)");
++ RNA_def_property_ui_text(prop,
++ "Z-Transparent",
++ "Render Z-transparent faces in this layer (on top of Solid and Halos)");
if (scene) {
RNA_def_property_update(prop, NC_SCENE | ND_RENDER_OPTIONS, NULL);
}
@@@ -8010,13 -7991,8 +8188,13 @@@ void RNA_def_scene(BlenderRNA *brna
/* EEVEE */
prop = RNA_def_property(srna, "eevee", PROP_POINTER, PROP_NONE);
RNA_def_property_struct_type(prop, "SceneEEVEE");
- RNA_def_property_ui_text(prop, "EEVEE", "EEVEE settings for the scene");
+ RNA_def_property_ui_text(prop, "Eevee", "Eevee settings for the scene");
+ /* Line Art */
+ prop = RNA_def_property(srna, "lineart", PROP_POINTER, PROP_NONE);
+ RNA_def_property_struct_type(prop, "SceneLineArt");
+ RNA_def_property_ui_text(prop, "Line Art", "Line Art settings for the scene");
+
/* Grease Pencil */
prop = RNA_def_property(srna, "grease_pencil_settings", PROP_POINTER, PROP_NONE);
RNA_def_property_struct_type(prop, "SceneGpencil");
@@@ -8039,7 -8016,7 +8218,8 @@@
rna_def_display_safe_areas(brna);
rna_def_scene_display(brna);
rna_def_scene_eevee(brna);
+ rna_def_scene_lineart(brna);
+ rna_def_view_layer_aov(brna);
rna_def_view_layer_eevee(brna);
rna_def_scene_gpencil(brna);
RNA_define_animate_sdna(true);
More information about the Bf-blender-cvs
mailing list