SVG prefiltering elements based on large faces

This commit is contained in:
Thomas Krijnen
2023-06-29 13:08:22 +02:00
parent 212b707464
commit 09d7cd97c8
3 changed files with 376 additions and 122 deletions
+3
View File
@@ -384,6 +384,8 @@ int main(int argc, char** argv) {
"Stores name and guid in a separate namespace as opposed to data-name, data-guid")
("svg-poly",
"Uses the polygonal algorithm for hidden line rendering")
("svg-prefilter",
"Prefilter faces and shapes before feeding to HLR algorithm")
("svg-write-poly",
"Approximate every curve as polygonal in SVG output")
("svg-project",
@@ -1055,6 +1057,7 @@ int main(int argc, char** argv) {
}
static_cast<SvgSerializer*>(serializer.get())->setUseNamespace(vmap.count("svg-xmlns") > 0);
static_cast<SvgSerializer*>(serializer.get())->setUseHlrPoly(vmap.count("svg-poly") > 0);
static_cast<SvgSerializer*>(serializer.get())->setUsePrefiltering(vmap.count("svg-prefilter") > 0);
static_cast<SvgSerializer*>(serializer.get())->setPolygonal(vmap.count("svg-write-poly") > 0);
static_cast<SvgSerializer*>(serializer.get())->setAlwaysProject(vmap.count("svg-project") > 0);
static_cast<SvgSerializer*>(serializer.get())->setWithoutStoreys(vmap.count("svg-without-storeys") > 0);