[Bf-blender-cvs] [586924bc452] greasepencil-object: GPencil: Replace SVG average factor by stroke thickness factor
Antonio Vazquez
noreply at git.blender.org
Wed Aug 12 23:42:19 CEST 2020
Commit: 586924bc45237997456acdfb91918ebef81cf8dd
Author: Antonio Vazquez
Date: Wed Aug 12 23:42:11 2020 +0200
Branches: greasepencil-object
https://developer.blender.org/rB586924bc45237997456acdfb91918ebef81cf8dd
GPencil: Replace SVG average factor by stroke thickness factor
Instead to change the point pressure, change the stroke thickness.
===================================================================
M source/blender/io/gpencil/intern/gpencil_io_export_svg.cc
===================================================================
diff --git a/source/blender/io/gpencil/intern/gpencil_io_export_svg.cc b/source/blender/io/gpencil/intern/gpencil_io_export_svg.cc
index 4f784eee926..7dd6f06f696 100644
--- a/source/blender/io/gpencil/intern/gpencil_io_export_svg.cc
+++ b/source/blender/io/gpencil/intern/gpencil_io_export_svg.cc
@@ -427,8 +427,6 @@ void GpencilExporterSVG::export_stroke_polyline(pugi::xml_node gpl_node, const b
if (!is_thickness_const) {
avg_pressure = stroke_average_pressure_get(gps);
}
- /* Scale value to get better result in SVG. */
- avg_pressure *= 2.0F;
/* Get the thickness in pixels using a simple 1 point stroke. */
bGPDstroke *gps_temp = BKE_gpencil_stroke_duplicate(gps, false);
@@ -448,7 +446,7 @@ void GpencilExporterSVG::export_stroke_polyline(pugi::xml_node gpl_node, const b
color_string_set(gps_node, is_fill);
if (gp_style_is_stroke() && !is_fill) {
- gps_node.append_attribute("stroke-width").set_value(radius);
+ gps_node.append_attribute("stroke-width").set_value(radius * 2.0f);
}
std::string txt;
More information about the Bf-blender-cvs
mailing list