https://github.com/piebro/factorio-blueprint-visualizer Skip to content Sign up * Why GitHub? + Features - + Mobile - + Actions - + Codespaces - + Packages - + Security - + Code review - + Issues - + Integrations - + GitHub Sponsors - + Customer stories - * Team * Enterprise * Explore + Explore GitHub - + Learn and contribute + Topics - + Collections - + Trending - + Learning Lab - + Open source guides - + Connect with others + The ReadME Project - + Events - + Community forum - + GitHub Education - + GitHub Stars program - * Marketplace * Pricing + Plans - + Compare plans - + Contact Sales - + Education - [ ] * # In this repository All GitHub | Jump to | * No suggested jump to results * # In this repository All GitHub | Jump to | * # In this user All GitHub | Jump to | * # In this repository All GitHub | Jump to | Sign in Sign up {{ message }} piebro / factorio-blueprint-visualizer Public * Notifications * Star 50 * Fork 1 * A python library to artfully visualize Factorio Blueprints and an interactive web demo for using it. piebro.github.io/factorio-blueprint-visualizer/ MIT License 50 stars 1 fork Star Notifications * Code * Issues 0 * Pull requests 0 * Actions * Projects 0 * Wiki * Security * Insights More * Code * Issues * Pull requests * Actions * Projects * Wiki * Security * Insights master Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show Loading {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default Loading View all tags 1 branch 1 tag Code Loading Latest commit @piebro piebro added online demo link ... 561bae8 Nov 29, 2021 added online demo link 561bae8 Git stats * 52 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time example_svgs updated examples and readme Nov 28, 2021 factorioBlueprintVisualizer added a second random drawing settings function Nov 28, 2021 website updated website to 1.0.0 Nov 28, 2021 .gitignore refactoring and cleanup Nov 12, 2021 LICENSE added License Oct 28, 2021 README.md added online demo link Nov 29, 2021 index.html updated website to 1.0.0 Nov 28, 2021 notebook.ipynb updated notebook Nov 28, 2021 requirements.txt updated website Nov 15, 2021 setup.py added curcuit and electricity connections Nov 22, 2021 View code [ ] Factorio Blueprint Visualizer Examples Usage Drawing Settings Pen Plotting verilog2factorio Convert to PNGs Contribute README.md Factorio Blueprint Visualizer [example_08] I love the game Factorio and I really like the look of factories after growing for many hours or blueprints after tweaking them for perfection. So I thought about visualizing the factories and blueprints. All factorio buildings with their bounding boxes and belt, pipe, inserter, wire and electricity connections can be visualized. Everything is drawn in vector graphics (SVG) to be able to view it in any resolution. The hardest part was writing the logic for connecting rails, belts and pipes. After many failed attempts with lots of bugs, I wrote a system that works pretty well. The next step was, to be able to be creative with drawing different connections and bounding boxes of buildings. Therefor, I created configurable drawing settings to experiment with and a random draw settings generator. After some tweaking, I got nice visualizations. To make the visualization tool easily accessible, I created an online demo that uses the original python code with pyodide in the browser (that's why the website might take some time to load) and an easy-to-use notebook. Examples [random_0077] [example_06] [example_12] [example_23] [example_24] [example_21] The last three blueprints are by Josh Ventura and can be found here. Usage You can visualize your own blueprint with random drawing settings at: https://piebro.github.io/factorio-blueprint-visualizer (You can use the arrow keys for going through the visualization). You can use the notebook, if you want to create your own drawing settings or tinker some more. For an easy setup, you can open the example notebook in colab or binder. You can find many blueprints at: https:// factorioprints.com. Open In Colab Binder Drawing Settings To visualize a blueprint you need drawing settings that define what is drawn, in which order and in what kind of style. Drawing settings are a list of option that are executed one after the other. You can decide which bounding box to draw with an allow or deny list of building names. You can also draw connected belt, underground-belts, pipes, underground-pipes, inserter, rail, electricity, red-circuits and green-circuits. Furthermore, you can define the style of each drawing command or set a new default drawing style. You can use fill, stroke, stroke-width, stroke-linecap, stroke-opacity, fill-opacity, bbox-scale, bbox-rx and bbox-ry as properties and every SVG tag should also work. Every visualization has the used drawing settings and blueprint saved with it, so you can check out the drawing settings of the examples blueprints inspiration. Pen Plotting I have a pen plotter, and one of my initial ideas was also to be able to plot my factories. You can create visualizations you can easily draw. I recommend using https://github.com/abey79/vpype for merging lines together before plotting. An example of a visualization for plotting is here: [example_25] verilog2factorio It's possible to use https://github.com/redcrafter/verilog2factorio to create factorio verilog blueprints and visualize the buildings and wire connections like this. [example_19] Convert to PNGs To easily convert all SVGs in a folder, you can use a terminal and Inkscape like this. mkdir pngs; for f in *.svg; do inkscape -w 1000 "$f" -e "pngs/${f::-3}png"; done Contribute Contributions to this project are welcome. Feel free to report bugs or post ideas you have. To update the python code for the website, you have to update the python wheel in the website folder. To update it, just run: python setup.py bdist_wheel --universal --dist-dir=website About A python library to artfully visualize Factorio Blueprints and an interactive web demo for using it. piebro.github.io/factorio-blueprint-visualizer/ Topics visualization python factorio generative-art factorio-blueprints Resources Readme License MIT License Languages * Jupyter Notebook 63.0% * Python 35.8% * HTML 1.2% * (c) 2021 GitHub, Inc. * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.