Remove SVG functionality from ice40 main
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
parent
96291f17aa
commit
086bc941a8
@ -45,26 +45,6 @@
|
||||
|
||||
USING_NEXTPNR_NAMESPACE
|
||||
|
||||
void svg_dump_decal(const Context *ctx, const DecalXY &decal)
|
||||
{
|
||||
const float scale = 10.0, offset = 10.0;
|
||||
const std::string style = "stroke=\"black\" stroke-width=\"0.1\" fill=\"none\"";
|
||||
|
||||
for (auto &el : ctx->getDecalGraphics(decal.decal)) {
|
||||
if (el.type == GraphicElement::TYPE_BOX) {
|
||||
std::cout << "<rect x=\"" << (offset + scale * (decal.x + el.x1)) << "\" y=\""
|
||||
<< (offset + scale * (decal.y + el.y1)) << "\" height=\"" << (scale * (el.y2 - el.y1))
|
||||
<< "\" width=\"" << (scale * (el.x2 - el.x1)) << "\" " << style << "/>\n";
|
||||
}
|
||||
|
||||
if (el.type == GraphicElement::TYPE_LINE) {
|
||||
std::cout << "<line x1=\"" << (offset + scale * (decal.x + el.x1)) << "\" y1=\""
|
||||
<< (offset + scale * (decal.y + el.y1)) << "\" x2=\"" << (offset + scale * (decal.x + el.x2))
|
||||
<< "\" y2=\"" << (offset + scale * (decal.y + el.y2)) << "\" " << style << "/>\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void conflicting_options(const boost::program_options::variables_map &vm, const char *opt1, const char *opt2)
|
||||
{
|
||||
if (vm.count(opt1) && !vm[opt1].defaulted() && vm.count(opt2) && !vm[opt2].defaulted()) {
|
||||
@ -91,7 +71,6 @@ int main(int argc, char *argv[])
|
||||
#ifndef NO_GUI
|
||||
options.add_options()("gui", "start gui");
|
||||
#endif
|
||||
options.add_options()("svg", "dump SVG file");
|
||||
options.add_options()("pack-only", "pack design only without placement or routing");
|
||||
|
||||
po::positional_options_description pos;
|
||||
@ -332,16 +311,6 @@ int main(int argc, char *argv[])
|
||||
ctx->placer_constraintWeight = vm["cstrweight"].as<float>();
|
||||
}
|
||||
|
||||
if (vm.count("svg")) {
|
||||
std::cout << "<svg xmlns=\"http://www.w3.org/2000/svg\" "
|
||||
"xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n";
|
||||
for (auto bel : ctx->getBels()) {
|
||||
std::cout << "<!-- " << ctx->getBelName(bel).str(ctx.get()) << " -->\n";
|
||||
svg_dump_decal(ctx.get(), ctx->getBelDecal(bel));
|
||||
}
|
||||
std::cout << "</svg>\n";
|
||||
}
|
||||
|
||||
if (vm.count("test"))
|
||||
ctx->archcheck();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user