[Bf-blender-cvs] [fd0a9d04835] temp-lineart-contained: LineArt: Remove WITH_LINEAR and merge projects
Antonio Vazquez
noreply at git.blender.org
Sat Feb 20 18:06:49 CET 2021
Commit: fd0a9d04835bb5d71d412803b2e4c3a3dd9c7ab8
Author: Antonio Vazquez
Date: Sat Feb 20 18:06:45 2021 +0100
Branches: temp-lineart-contained
https://developer.blender.org/rBfd0a9d04835bb5d71d412803b2e4c3a3dd9c7ab8
LineArt: Remove WITH_LINEAR and merge projects
As Lineart can be considered a grease pencil feature is not logic to have a flag that only adds problems.
Also, the bf_gpencil_lineart has been removed and all code set inside bf_gpencil_modifiers.
===================================================================
M CMakeLists.txt
M release/scripts/startup/bl_ui/__init__.py
M release/scripts/startup/bl_ui/space_view3d.py
M source/blender/blenkernel/CMakeLists.txt
M source/blender/editors/mesh/CMakeLists.txt
M source/blender/editors/mesh/editmesh_tools.c
M source/blender/editors/mesh/mesh_intern.h
M source/blender/editors/mesh/mesh_ops.c
M source/blender/editors/object/CMakeLists.txt
M source/blender/editors/object/object_add.c
M source/blender/editors/render/CMakeLists.txt
M source/blender/editors/space_api/CMakeLists.txt
M source/blender/editors/space_buttons/CMakeLists.txt
M source/blender/editors/space_buttons/buttons_context.c
M source/blender/editors/space_buttons/space_buttons.c
M source/blender/editors/space_view3d/CMakeLists.txt
M source/blender/editors/util/CMakeLists.txt
M source/blender/gpencil_modifiers/CMakeLists.txt
M source/blender/gpencil_modifiers/intern/MOD_gpencillineart.c
D source/blender/gpencil_modifiers/intern/lineart/CMakeLists.txt
M source/blender/gpencil_modifiers/intern/lineart/ED_lineart.h
M source/blender/makesrna/intern/CMakeLists.txt
M source/blender/python/intern/CMakeLists.txt
M source/blender/python/intern/bpy_app_build_options.c
===================================================================
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c8fdf588c15..c95b8f0f7af 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -332,9 +332,6 @@ mark_as_advanced(WITH_SYSTEM_GLOG)
# Freestyle
option(WITH_FREESTYLE "Enable Freestyle (advanced edges rendering)" ON)
-# LRT
-option(WITH_LINEART "Enable LRT (more advanced edges rendering)" ON)
-
# Misc
if(WIN32)
option(WITH_INPUT_IME "Enable Input Method Editor (IME) for complex Asian character input" ON)
@@ -1893,7 +1890,6 @@ if(FIRST_RUN)
info_cfg_option(WITH_IK_SOLVER)
info_cfg_option(WITH_INPUT_NDOF)
info_cfg_option(WITH_INTERNATIONAL)
- info_cfg_option(WITH_LINEART)
info_cfg_option(WITH_OPENCOLLADA)
info_cfg_option(WITH_OPENCOLORIO)
info_cfg_option(WITH_OPENIMAGEDENOISE)
diff --git a/release/scripts/startup/bl_ui/__init__.py b/release/scripts/startup/bl_ui/__init__.py
index 7af6df18724..eef4eb1b2b3 100644
--- a/release/scripts/startup/bl_ui/__init__.py
+++ b/release/scripts/startup/bl_ui/__init__.py
@@ -104,8 +104,7 @@ import bpy
if bpy.app.build_options.freestyle:
_modules.append("properties_freestyle")
-if bpy.app.build_options.lineart:
- _modules.append("properties_lineart")
+_modules.append("properties_lineart")
__import__(name=__name__, fromlist=_modules)
_namespace = globals()
diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py
index e240e3cb7be..36bbe90aa92 100644
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@ -4016,7 +4016,7 @@ class VIEW3D_MT_edit_mesh_edges(Menu):
def draw(self, _context):
layout = self.layout
- with_freestyle = bpy.app.build_options.freestyle or bpy.app.build_options.lineart
+ with_freestyle = bpy.app.build_options.freestyle
layout.operator_context = 'INVOKE_REGION_WIN'
diff --git a/source/blender/blenkernel/CMakeLists.txt b/source/blender/blenkernel/CMakeLists.txt
index d0a9a6104a2..f288bf9aabc 100644
--- a/source/blender/blenkernel/CMakeLists.txt
+++ b/source/blender/blenkernel/CMakeLists.txt
@@ -670,10 +670,6 @@ if(WITH_FREESTYLE)
add_definitions(-DWITH_FREESTYLE)
endif()
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
if(WITH_ALEMBIC)
list(APPEND INC
../io/alembic
diff --git a/source/blender/editors/mesh/CMakeLists.txt b/source/blender/editors/mesh/CMakeLists.txt
index 0a8dbfcc0e0..35bf295a678 100644
--- a/source/blender/editors/mesh/CMakeLists.txt
+++ b/source/blender/editors/mesh/CMakeLists.txt
@@ -85,10 +85,6 @@ if(WITH_FREESTYLE)
add_definitions(-DWITH_FREESTYLE)
endif()
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
if(WITH_BULLET)
add_definitions(-DWITH_BULLET)
endif()
diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c
index a8e5cac3b5f..3d7b92975d1 100644
--- a/source/blender/editors/mesh/editmesh_tools.c
+++ b/source/blender/editors/mesh/editmesh_tools.c
@@ -7752,7 +7752,7 @@ void MESH_OT_symmetry_snap(struct wmOperatorType *ot)
/** \} */
-#if (defined(WITH_FREESTYLE) || defined(WITH_LINEART))
+#if defined(WITH_FREESTYLE)
/* -------------------------------------------------------------------- */
/** \name Mark Edge (Freestyle) Operator
@@ -7912,7 +7912,7 @@ void MESH_OT_mark_freestyle_face(wmOperatorType *ot)
/** \} */
-#endif /* WITH_FREESTYLE || WITH_LINEART */
+#endif /* WITH_FREESTYLE */
/* -------------------------------------------------------------------- */
/** \name Loop Normals Editing Tools Modal Map
diff --git a/source/blender/editors/mesh/mesh_intern.h b/source/blender/editors/mesh/mesh_intern.h
index f9c8bd415dd..763bdf04d83 100644
--- a/source/blender/editors/mesh/mesh_intern.h
+++ b/source/blender/editors/mesh/mesh_intern.h
@@ -267,7 +267,7 @@ void MESH_OT_paint_mask_slice(struct wmOperatorType *ot);
struct wmKeyMap *point_normals_modal_keymap(wmKeyConfig *keyconf);
-#if (defined(WITH_FREESTYLE) || defined(WITH_LINEART))
+#if defined(WITH_FREESTYLE)
void MESH_OT_mark_freestyle_edge(struct wmOperatorType *ot);
void MESH_OT_mark_freestyle_face(struct wmOperatorType *ot);
#endif
diff --git a/source/blender/editors/mesh/mesh_ops.c b/source/blender/editors/mesh/mesh_ops.c
index 88b2b23ee0b..34e9a3f45a5 100644
--- a/source/blender/editors/mesh/mesh_ops.c
+++ b/source/blender/editors/mesh/mesh_ops.c
@@ -130,7 +130,7 @@ void ED_operatortypes_mesh(void)
WM_operatortype_append(MESH_OT_loop_multi_select);
WM_operatortype_append(MESH_OT_mark_seam);
WM_operatortype_append(MESH_OT_mark_sharp);
-#if (defined(WITH_FREESTYLE) || defined(WITH_LINEART))
+#if defined(WITH_FREESTYLE)
WM_operatortype_append(MESH_OT_mark_freestyle_edge);
#endif
WM_operatortype_append(MESH_OT_vertices_smooth);
diff --git a/source/blender/editors/object/CMakeLists.txt b/source/blender/editors/object/CMakeLists.txt
index f594bb79239..77b5379ddd4 100644
--- a/source/blender/editors/object/CMakeLists.txt
+++ b/source/blender/editors/object/CMakeLists.txt
@@ -86,10 +86,6 @@ if(WITH_INTERNATIONAL)
add_definitions(-DWITH_INTERNATIONAL)
endif()
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
if(WITH_EXPERIMENTAL_FEATURES)
add_definitions(-DWITH_GEOMETRY_NODES)
add_definitions(-DWITH_POINT_CLOUD)
diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c
index 100a42ff761..9c42466e5ec 100644
--- a/source/blender/editors/object/object_add.c
+++ b/source/blender/editors/object/object_add.c
@@ -1335,13 +1335,11 @@ static int object_gpencil_add_exec(bContext *C, wmOperator *op)
ob_name = "Stroke";
break;
}
-#ifdef WITH_LINEART
case GP_LRT_OBJECT:
case GP_LRT_COLLECTION: {
ob_name = "Line Art";
break;
}
-#endif
default: {
break;
}
@@ -1382,7 +1380,6 @@ static int object_gpencil_add_exec(bContext *C, wmOperator *op)
ED_gpencil_create_monkey(C, ob, mat);
break;
}
-#ifdef WITH_LINEART
case GP_LRT_SCENE:
case GP_LRT_COLLECTION:
case GP_LRT_OBJECT: {
@@ -1423,7 +1420,6 @@ static int object_gpencil_add_exec(bContext *C, wmOperator *op)
/* Stroke object is drawn in front of meshes by default. */
ob->dtx |= OB_DRAW_IN_FRONT;
}
-#endif
case GP_EMPTY:
/* do nothing */
break;
@@ -1459,7 +1455,6 @@ static const EnumPropertyItem *object_gpencil_add_options(bContext *C,
for (i = 0; i < orig_count; i++) {
if (item_ref[i].value == GP_LRT_OBJECT || item_ref[i].value == GP_LRT_COLLECTION ||
item_ref[i].value == GP_LRT_SCENE) {
-#ifdef WITH_LINEART
if (item_ref[i].value == GP_LRT_SCENE) {
/* separator before line art types */
RNA_enum_item_add_separator(&item, &totitem);
@@ -1470,10 +1465,6 @@ static const EnumPropertyItem *object_gpencil_add_options(bContext *C,
continue;
}
}
-#else
- /* Don't show line art options when not compiled with one. */
- continue;
-#endif
}
RNA_enum_item_add(&item, &totitem, &item_ref[i]);
}
diff --git a/source/blender/editors/render/CMakeLists.txt b/source/blender/editors/render/CMakeLists.txt
index 67f552bd15c..46afa390997 100644
--- a/source/blender/editors/render/CMakeLists.txt
+++ b/source/blender/editors/render/CMakeLists.txt
@@ -66,10 +66,6 @@ if(WITH_FREESTYLE)
add_definitions(-DWITH_FREESTYLE)
endif()
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
if(WITH_INTERNATIONAL)
add_definitions(-DWITH_INTERNATIONAL)
endif()
diff --git a/source/blender/editors/space_api/CMakeLists.txt b/source/blender/editors/space_api/CMakeLists.txt
index 4b77b4da668..573afb76f0e 100644
--- a/source/blender/editors/space_api/CMakeLists.txt
+++ b/source/blender/editors/space_api/CMakeLists.txt
@@ -57,8 +57,4 @@ set(LIB
bf_editor_space_view3d
)
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
blender_add_lib(bf_editor_space_api "${SRC}" "${INC}" "${INC_SYS}" "${LIB}")
diff --git a/source/blender/editors/space_buttons/CMakeLists.txt b/source/blender/editors/space_buttons/CMakeLists.txt
index d173adafeaa..c71e5e49d8d 100644
--- a/source/blender/editors/space_buttons/CMakeLists.txt
+++ b/source/blender/editors/space_buttons/CMakeLists.txt
@@ -55,8 +55,4 @@ if(WITH_EXPERIMENTAL_FEATURES)
add_definitions(-DWITH_HAIR_NODES)
endif()
-if(WITH_LINEART)
- add_definitions(-DWITH_LINEART)
-endif()
-
blender_add_lib(bf_editor_space_buttons "${SRC}" "${INC}" "${INC_SYS}" "${LIB}")
diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c
index 2c98eeb40a5..13762b348c2 100644
--- a/source/blender/editors/space_buttons/buttons_context.c
+++ b/source/blender/editors/space_buttons/buttons_context.c
@@ -600,11 +600,7 @@ static bool buttons_context_path(
found = buttons_context_path_world(path);
break;
case BCONTEXT_COLLECTION: /* This is for Line Art collection flags */
-#ifdef WITH_LINEART
found = buttons_context_path_collection(path, window);
-#else
- BLI_assert(!"'WITH_LINEART' is off.");
-#endif
break;
case BCONTEXT_TOOL:
found = true;
diff --git a/source/blender/editors/space_buttons/space_buttons.c b/source/blender/editors/space_buttons/space_buttons.c
index e1cb84108ae..4df786b3d6d 100644
--- a/source/blender/editors/space_buttons/space_buttons.c
+++ b/source/blender/editors/space_buttons/space_buttons.c
@@ -276,11 +276,7 @@ static const char *buttons_main_region_context_string(const short mainb)
case BCONTEXT_WORLD:
return "world";
case BCONTEXT_COLLECTION:
-#ifdef WITH_LINEART
return "collection";
-#else
- BLI_assert(!"'WITH_LINEART' is off.");
-#endif
case BCONTEXT_OBJECT:
return "object";
case BCONTEXT_DATA:
diff --git a/source/blender/editors/space_view3d/CMakeLists.txt b/source/blender/editors/space_view3d/CMakeLists.txt
index 0f1d16e18b3..9242fc15021 100644
--- a/source/blender/editors/space_view3d/CMakeLists.txt
+++ b/source/blender/editors/space_view3d/CMakeLists.txt
@@ -91,10 +91,6 @@ if(WITH_FREESTYLE)
add_defin
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list