Added mutual cut line

This commit is contained in:
Mario Voigt 2020-08-08 23:01:01 +02:00
parent fc960bdc83
commit f190593dfb
11 changed files with 616 additions and 0 deletions

View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Barrel Distortion</name>
<id>fablabchemnitz.de.distorsion</id>
<param name="lambda_coef" type="float" min="-1000.0" max="0.0" precision="2" gui-text="Lambda parameter">-1.0</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Modify existing Path(s)"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_distortion.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,50 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension>
<name>Encoder Disk Generator</name>
<id>fablabchemnitz.de.encoder_disk_generator</id>
<param name="tab" type="notebook">
<page name="rotary_enc" gui-text="Rotary encoder">
<param name="diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the encoder disk">0.0</param>
<param name="hole_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the center hole">0.0</param>
<param name="segments" type="int" min="1" max="10000" gui-text="Number of segments">1</param>
<param name="outer_encoder_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the outer encoder disk">0.0</param>
<param name="outer_encoder_width" type="float" min="1.0" max="1000.0" gui-text="Width of the outer encoder disk">0.0</param>
<param name="inner_encoder_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the inner encoder disk">0.0</param>
<param name="inner_encoder_width" type="float" min="1.0" max="1000.0" gui-text="Width of the inner encoder disk">0.0</param>
</page>
<page name="brgc" gui-text="Binary reflected gray code (BRGC)">
<param name="brgc_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the encoder disk">0.0</param>
<param name="brgc_hole_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the center hole">0.0</param>
<param name="bits" type="int" min="1" max="32" gui-text="Number of bits/tracks">1</param>
<param name="encoder_diameter" type="float" min="1.0" max="1000.0" gui-text="Outer diameter of the last track">0.0</param>
<param name="track_width" type="float" min="1.0" max="1000.0" gui-text="Width of one track">0.0</param>
<param name="track_distance" type="float" min="0.0" max="1000.0" gui-text="Distance between tracks">0.0</param>
</page>
<page name="stgc" gui-text="Single-track gray code (STGC)">
<param name="stgc_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the encoder disk">0.0</param>
<param name="stgc_hole_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the center hole">0.0</param>
<param name="cutouts" type="int" min="1" max="5" gui-text="Number of cutouts">1</param>
<param name="sensors" type="int" min="1" max="36" gui-text="Number of sensors">1</param>
<param name="stgc_encoder_diameter" type="float" min="1.0" max="1000.0" gui-text="Outer diameter of track">0.0</param>
<param name="stgc_track_width" type="float" min="1.0" max="1000.0" gui-text="Width of one track">0.0</param>
</page>
<page name="bitmap_enc" gui-text="Bitmap encoder">
<param name="bm_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the encoder disk">30.0</param>
<param name="bm_hole_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the center hole">5.0</param>
<param name="bm_bits" type="string" gui-text="Bits for segments">010011110111000010001101</param>
<param name="bm_outer_encoder_diameter" type="float" min="0.0" max="1000.0" gui-text="Diameter of the outer encoder disk">25.0</param>
<param name="bm_outer_encoder_width" type="float" min="1.0" max="1000.0" gui-text="Width of the outer encoder disk">10.0</param>
</page>
</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Shape/Pattern from Generator"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_encoder_disk_generator.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Low Poly</name>
<id>fablabchemnitz.de.low_poly</id>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Shape/Pattern from existing Object(s)"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_lowpoly.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Mutual Cut Line</name>
<id>fablabchemnitz.de.mutual_cut_line</id>
<effect>
<object-type>path</object-type>
<effects-menu>
<submenu name="PathMonkey" />
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_mutual_cut_line.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,94 @@
#!/usr/bin/env python3
'''
Mutual Cut Line
This Inkscape extension will take 2 selected line and cut them both
at their intersection point.
Only the first segment of a multi-segment line will be used.
'''
import inkex
from inkex.paths import Path
import simplepath
from math import *
from lxml import etree
def error(message):
inkex.errormsg(message)
exit()
class MultiCutEffect(inkex.Effect):
def __init__(self):
inkex.Effect.__init__(self)
def effect(self):
if len(self.svg.selected.items()) != 2:
error('Please select 2 lines before running this effect.')
line = []
numPaths = 0
for id, path in self.svg.selected.items():
if path.tag == inkex.addNS('path','svg'):
numPaths += 1
style = path.get('style')
np = [style]
p = Path(path.get('d')).to_arrays()
for sp in p:
np.append([sp[1][0], sp[1][1]])
line.append(np)
path.getparent().remove(path) #after cutting we remove the original lines
if numPaths != 2:
error('Please select 2 lines before running this effect.')
# Extract style and points for the first 2 line segments.
astyle = line[0][0]
bstyle = line[1][0]
a1x = line[0][1][0]
a1y = line[0][1][1]
a2x = line[0][2][0]
a2y = line[0][2][1]
b1x = line[1][1][0]
b1y = line[1][1][1]
b2x = line[1][2][0]
b2y = line[1][2][1]
# Calculate intersection point.
adx = a1x - a2x
ady = a1y - a2y
bdx = b1x - b2x
bdy = b1y - b2y
denom = adx * bdy - ady * bdx
numa = (a1x * a2y - a1y * a2x)
numb = (b1x * b2y - b1y * b2x)
x_num = numa * bdx - numb * adx
y_num = numa * bdy - numb * ady
if denom == 0:
error('Lines don\'t intersect in a single point.')
x = x_num / denom
y = y_num / denom
# TODO: Verify that the 2 segments intersect.
# Current code will connect outside the line segments.
# Create 4 line segments from the intersection point.
svg_path = inkex.addNS('path','svg')
sega1 = etree.SubElement(self.svg.get_current_layer(), svg_path)
sega1.set('d', 'M '+str(x)+','+str(y)+' L '+str(a1x)+','+str(a1y))
sega1.set('style', astyle)
sega2 = etree.SubElement(self.svg.get_current_layer(), svg_path)
sega2.set('d', 'M '+str(x)+','+str(y)+' L '+str(a2x)+','+str(a2y))
sega2.set('style', astyle)
segb1 = etree.SubElement(self.svg.get_current_layer(), svg_path)
segb1.set('d', 'M '+str(x)+','+str(y)+' L '+str(b1x)+','+str(b1y))
segb1.set('style', bstyle)
segb2 = etree.SubElement(self.svg.get_current_layer(), svg_path)
segb2.set('d', 'M '+str(x)+','+str(y)+' L '+str(b2x)+','+str(b2y))
segb2.set('style', bstyle)
if __name__ == '__main__':
MultiCutEffect().run()

View File

@ -0,0 +1,92 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Origami Pattern - Kresling tower</name>
<id>fablabchemnitz.de.origami_patterns.kresling_full</id>
<param name='active-tab' type="notebook">
<page name="title" gui-text="Options">
<param name="pattern" type="optiongroup" appearance="combo" gui-text="Type of Kresling tower">
<option value="regular">Regular</option>
<option value="mirrowed">Mirror odd cells</option>
</param>
<param name="help" type="description" xml:space="preserve">------------------------------------------------------------</param>
<param name="lines" type="int" min="1" max="100" gui-text="Number of cells">3</param>
<param name="sides" type="int" min="3" max="100" gui-text="Number of polygon sides">6</param>
<param name="help" type="description" xml:space="preserve">------------------------------------------------------------</param>
<param name="measure_value" type="float" max="10000" precision="3" gui-text="Measure value:">10.0</param>
<param name="measure_type" type="optiongroup" appearance="combo" gui-text="Measure type:">
<option value="a">Polygon side (a)</option>
<option value="b">Vertical mountain crease (b)</option>
<option value="l">Diagonal valley crease (l)</option>
<option value="radius_external">External radius</option>
<option value="radius_internal">Internal radius (totally closed)</option>
<option value="diameter_external">External diameter</option>
<option value="diameter_internal">Internal diameter (totally closed)</option>
<!--
<option value="a_l_angle">Angle between valley crease and horizontal polygon side</option>
-->
</param>
<param name="units" type="optiongroup" appearance="combo" gui-text=" ">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option></param>
<param name="help" type="description" xml:space="preserve">------------------------------------------------------------</param>
<param name="parameter_type" type="optiongroup" appearance="combo" gui-text="Parameter type:">
<option value="angle_ratio">Angle ratio (lambda)</option>
<option value="radial_ratio">Radial ratio</option>
<option value="lambdatheta">Angle between a and l (lambda * theta)</option></param>
<param name="radial_ratio" type="float" min="0" max="0.7" precision="3" gui-text="Radial ratio:">0.5</param>
<param name="angle_ratio" type="float" min="0.5" max="1" precision="3" gui-text="Angle ratio:">0.5</param>
<param name="lambdatheta" type="float" min="15" max="90" precision="2" gui-text="Angle between a and l">60.0</param>
<!-- <option value="angle">Angle between l and a</option>-->
</page>
<page name="extraoptions" gui-text="Extra Options">
<param name="add_attachment" type="bool" gui-text="Add one more facet to close tower?">false</param>
<param name="attachment_percentage" type="float" min="0" max="100" precision="1" appearance="full" gui-text="Length percentage of extra facet">100</param>
<param name="help" type="description" xml:space="preserve">------------------------------------------------------------</param>
</page>
<page name="mountains" gui-text="Mountain creases">
<param name="mountain_bool" type="bool" gui-text="Draw mountains?">true</param>
<param name="mountain_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="mountain_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Mountain dash + gap length">1</param>
<param name="mountain_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Mountain dash duty cycle">0.5</param>
<param name="mountain_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of mountain strokes">0.1</param>
<param name="mountain_stroke_color" type="color" gui-text="Mountain creases color: ">4278190335</param>
</page>
<page name="valleys" gui-text="Valley creases">
<param name="valley_bool" type="bool" gui-text="Draw valley?">true</param>
<param name="valley_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="valley_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Valley dash + gap length">1</param>
<param name="valley_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Valley dash duty cycle">0.25</param>
<param name="valley_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of valley strokes">0.1</param>
<param name="valley_stroke_color" type="color" gui-text="Valley creases color: ">65535</param>
</page>
<page name="edge" gui-text="Edge">
<param name="edge_bool" type="bool" gui-text="Draw edges?">true</param>
<param name="edge_single_path" type="bool" gui-text="Edges as single path?">true</param>
<param name="edge_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>
<param name="edge_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Edge dash + gap length">1</param>
<param name="edge_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Edge dash duty cycle">0.25</param>
<param name="edge_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of edge strokes">0.1</param>
<param name="edge_stroke_color" type="color" gui-text="Edge color: ">255</param>
</page>
<page name="vertices" gui-text="Vertices">
<param name="vertex_bool" type="bool" gui-text="Draw vertices?">false</param>
<param name="vertex_radius" type="float" min="0.01" max="50" appearance="full" gui-text="Radius of vertices">0.1</param>
<param name="vertex_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of vertex strokes">0.1</param>
<param name="vertex_stroke_color" type="color" gui-text="Vertices\' color: ">255</param>
</page>
</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Paper/Cardboard Boxes"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">OrigamiPatterns/Kresling_full.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Origami Pattern - N-sided Hypar</name>
<id>fablabchemnitz.de.origami_patterns.pleat_hypar</id>
<param name='active-tab' type="notebook">
<page name="title" gui-text="Options">
<param name="pattern" type="optiongroup" appearance="combo" gui-text="Type of Hypar">
<option value="classic">Classic Hypar</option>
<option value="asymmetric">Asymmetric triangulation</option>
<option value="alternate_asymmetric">Alternating asymmetric triangulation</option>
</param>
<param name="radius" type="float" max="10000" precision="3" gui-text="Radius of polygon">100.0</param>
<param name="units" type="optiongroup" appearance="combo" gui-text=" ">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option>
</param>
<param name="sides" type="int" min="3" max="100" gui-text="Number of polygon sides">4</param>
<param name="rings" type="int" min="1" max="100" gui-text="Number of rings">7</param>
<param name="simplify_center" type="bool" gui-text="Simplify center (probably not suited for odd number of sides)">false</param>
<param name="help" type="description" xml:space="preserve">Implements Hypar (classical hyperbolic paraboloid approximate). Classic Hypar is the easiest one to fold. However, it's not rigid foldable. More information in: Demaine, E. D., Demaine, M. L., Hart, V., Price, G. N. and Tachi, T. (2011). (Non)Existence of Pleated Folds: How Paper Folds Between Creases. Graphs and Combinatorics, 27(3), 377397. https://doi.org/10.1007/s00373-011-1025-2</param>
</page>
<page name="mountains" gui-text="Mountain creases">
<param name="mountain_bool" type="bool" gui-text="Draw mountains?">true</param>
<param name="mountain_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="mountain_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Mountain dash + gap length">1</param>
<param name="mountain_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Mountain dash duty cycle">0.5</param>
<param name="mountain_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of mountain strokes">0.1</param>
<param name="mountain_stroke_color" type="color" gui-text="Mountain creases color: ">4278190335</param>
</page>
<page name="valleys" gui-text="Valley creases">
<param name="valley_bool" type="bool" gui-text="Draw valley?">true</param>
<param name="valley_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="valley_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Valley dash + gap length">1</param>
<param name="valley_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Valley dash duty cycle">0.25</param>
<param name="valley_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of valley strokes">0.1</param>
<param name="valley_stroke_color" type="color" gui-text="Valley creases color: ">65535</param>
</page>
<page name="universal" gui-text="Universal creases">
<param name="universal_bool" type="bool" gui-text="Draw universal creases?">true</param>
<param name="universal_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>
<param name="universal_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Universal dash + gap length">1</param>
<param name="universal_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Universal dash duty cycle">0.25</param>
<param name="universal_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of universal strokes">0.1</param>
<param name="universal_stroke_color" type="color" gui-text="Universal creases color: ">4278255615</param>
</page>
<page name="edge" gui-text="Edge">
<param name="edge_bool" type="bool" gui-text="Draw edges?">true</param>
<param name="edge_single_path" type="bool" gui-text="Edges as single path?">true</param>
<param name="edge_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>
<param name="edge_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Edge dash + gap length">1</param>
<param name="edge_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Edge dash duty cycle">0.25</param>
<param name="edge_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of edge strokes">0.1</param>
<param name="edge_stroke_color" type="color" gui-text="Edge color: ">255</param>
</page>
<page name="vertices" gui-text="Vertices">
<param name="vertex_bool" type="bool" gui-text="Draw vertices?">false</param>
<param name="vertex_radius" type="float" min="0.01" max="50" appearance="full" gui-text="Radius of vertices">0.1</param>
<param name="vertex_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of vertex strokes">0.1</param>
<param name="vertex_stroke_color" type="color" gui-text="Vertices\' color: ">255</param>
</page>
</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Paper/Cardboard Boxes"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">OrigamiPatterns/Hypar.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,90 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Origami Pattern - Template effect</name>
<id>fablabchemnitz.de.origami_patterns.template</id>
<param name='active-tab' type="notebook">
<page name="title" gui-text="Options">
<param name="pattern" type="optiongroup" appearance="combo" gui-text="Type of template">
<option value="template1">Template pattern 1</option>
<option value="template2">Template pattern 2</option>
</param>
<param name="length" type="float" max="10000" precision="3" gui-text="Length of grid square">10.0</param>
<param name="units" type="optiongroup" appearance="combo" gui-text=" ">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option></param>
<param name="theta" type="int" min="0" max="360" gui-text="Rotation angle (degree)">0</param>
<param name="help" type="description" xml:space="preserve">The .inx file defines the bridge between Inkscape's interface and the python script.</param>
</page>
<page name="mountains" gui-text="Mountain creases">
<param name="mountain_bool" type="bool" gui-text="Draw mountains?">true</param>
<param name="mountain_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="mountain_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Mountain dash + gap length">1</param>
<param name="mountain_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Mountain dash duty cycle">0.5</param>
<param name="mountain_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of mountain strokes">0.1</param>
<param name="mountain_stroke_color" type="color" gui-text="Mountain creases color: ">4278190335</param>
</page>
<page name="valleys" gui-text="Valley creases">
<param name="valley_bool" type="bool" gui-text="Draw valley?">true</param>
<param name="valley_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="valley_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Valley dash + gap length">1</param>
<param name="valley_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Valley dash duty cycle">0.25</param>
<param name="valley_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of valley strokes">0.1</param>
<param name="valley_stroke_color" type="color" gui-text="Valley creases color: ">65535</param>
</page>
<page name="edge" gui-text="Edge">
<param name="edge_bool" type="bool" gui-text="Draw edges?">true</param>
<param name="edge_single_path" type="bool" gui-text="Edges as single path?">true</param>
<param name="edge_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>
<param name="edge_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Edge dash + gap length">1</param>
<param name="edge_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Edge dash duty cycle">0.25</param>
<param name="edge_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of edge strokes">0.1</param>
<param name="edge_stroke_color" type="color" gui-text="Edge color: ">255</param>
</page>
<page name="vertices" gui-text="Vertices">
<param name="vertex_bool" type="bool" gui-text="Draw vertices?">true</param>
<param name="vertex_radius" type="float" min="0.01" max="50" appearance="full" gui-text="Radius of vertices">0.1</param>
<param name="vertex_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of vertex strokes">0.1</param>
<param name="vertex_stroke_color" type="color" gui-text="Vertices\' color: ">255</param>
</page>
<!-- UNCOMMENT UNIVERSAL CREASES, CUTS AND/OR SEMICREASES IF NEEDED-->
<!-- <page name="universal" gui-text="Universal creases">-->
<!-- <param name="universal_bool" type="bool" gui-text="Draw universal creases?">true</param>-->
<!-- <param name="universal_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>-->
<!-- <param name="universal_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Universal dash + gap length">1</param>-->
<!-- <param name="universal_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Universal dash duty cycle">0.25</param>-->
<!-- <param name="universal_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of universal strokes">0.1</param> -->
<!-- <param name="universal_stroke_color" type="color" gui-text="Universal creases color: ">4278255615</param>-->
<!-- </page>-->
<!-- <page name="semicrease" gui-text="Semicreases">-->
<!-- <param name="semicrease_bool" type="bool" gui-text="Draw semicreases?">true</param>-->
<!-- <param name="semicrease_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>-->
<!-- <param name="semicrease_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Semicrease dash + gap length">1</param>-->
<!-- <param name="semicrease_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Semicrease dash duty cycle">0.25</param>-->
<!-- <param name="semicrease_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of semicrease strokes">0.1</param>-->
<!-- <param name="semicrease_stroke_color" type="color" gui-text="Semicreases color: ">4294902015</param>-->
<!-- </page>-->
<!-- <page name="cuts" gui-text="Cuts">-->
<!-- <param name="cut_bool" type="bool" gui-text="Draw cuts?">true</param>-->
<!-- <param name="cut_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>-->
<!-- <param name="cut_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Cut dash + gap length">1</param>-->
<!-- <param name="cut_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Cut dash duty cycle">0.25</param>-->
<!-- <param name="cut_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of cut strokes">0.1</param>-->
<!-- <param name="cut_stroke_color" type="color" gui-text="Cut creases color: ">16711935</param>-->
<!-- </page>-->
</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Paper/Cardboard Boxes"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">OrigamiPatterns/Template.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,73 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Origami Pattern - Waterbomb</name>
<id>fablabchemnitz.de.origami_patterns.magic_ball</id>
<param name='active-tab' type="notebook">
<page name="title" gui-text="Options">
<param name="pattern_first_line" type="optiongroup" appearance="combo" gui-text="First line:">
<option value="waterbomb">Regular waterbomb</option>
<option value="magic_ball">Magic ball</option>
</param>
<param name="pattern_last_line" type="optiongroup" appearance="combo" gui-text="Last line:">
<option value="waterbomb">Regular waterbomb</option>
<option value="magic_ball">Magic ball</option>
</param>
<param name="phase_shift" type="bool" gui-text="Shift phase?">false</param>
<param name="help" type="description" xml:space="preserve">------------------------------</param>
<param name="lines" type="int" min="1" max="100" gui-text="Number of lines">8</param>
<param name="columns" type="int" min="1" max="100" gui-text="Number of columns">16</param>
<param name="help" type="description" xml:space="preserve">------------------------------</param>
<param name="length" type="float" max="10000" precision="3" gui-text="Length of grid square">10.0</param>
<param name="units" type="optiongroup" appearance="combo" gui-text=" ">
<option value="mm">mm</option>
<option value="cm">cm</option>
<option value="in">in</option>
<option value="pt">pt</option>
<option value="px">px</option></param>
<param name="help" type="description" xml:space="preserve">"Waterbomb tessellation" creates a simple tessellation pattern repeating the Waterbomb base, with a half-step phase shift between each line.&#xA;The Magic ball is a different design that inverts both the upper half of the first line and the bottom half of the last line.</param>
</page>
<page name="mountains" gui-text="Mountain creases">
<param name="mountain_bool" type="bool" gui-text="Draw mountains?">true</param>
<param name="mountain_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="mountain_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Mountain dash + gap length">1</param>
<param name="mountain_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Mountain dash duty cycle">0.5</param>
<param name="mountain_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of mountain strokes">0.1</param>
<param name="mountain_stroke_color" type="color" gui-text="Mountain creases color: ">4278190335</param>
</page>
<page name="valleys" gui-text="Valley creases">
<param name="valley_bool" type="bool" gui-text="Draw valley?">true</param>
<param name="valley_dashes_bool" type="bool" gui-text="Dashed strokes?">true</param>
<param name="valley_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Valley dash + gap length">1</param>
<param name="valley_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Valley dash duty cycle">0.25</param>
<param name="valley_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of valley strokes">0.1</param>
<param name="valley_stroke_color" type="color" gui-text="Valley creases color: ">65535</param>
</page>
<page name="edge" gui-text="Edge">
<param name="edge_bool" type="bool" gui-text="Draw edges?">true</param>
<param name="edge_single_path" type="bool" gui-text="Edges as single path?">true</param>
<param name="edge_dashes_bool" type="bool" gui-text="Dashed strokes?">false</param>
<param name="edge_dashes_len" type="float" min="0.1" max="10" appearance="full" precision="2" gui-text="Edge dash + gap length">1</param>
<param name="edge_dashes_duty" type="float" min="0.1" max="1" appearance="full" precision="2" gui-text="Edge dash duty cycle">0.25</param>
<param name="edge_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of edge strokes">0.1</param>
<param name="edge_stroke_color" type="color" gui-text="Edge color: ">255</param>
</page>
<page name="vertices" gui-text="Vertices">
<param name="vertex_bool" type="bool" gui-text="Draw vertices?">false</param>
<param name="vertex_radius" type="float" min="0.01" max="50" appearance="full" gui-text="Radius of vertices">0.1</param>
<param name="vertex_stroke_width" type="float" min="0.01" max="3" appearance="full" gui-text="Width of vertex strokes">0.1</param>
<param name="vertex_stroke_color" type="color" gui-text="Vertices\' color: ">255</param>
</page>
</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Paper/Cardboard Boxes"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">OrigamiPatterns/Waterbomb.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Parametric Shelves</name>
<id>fablabchemnitz.de.shelves</id>
<param name="unit" type="optiongroup" appearance="combo" gui-text="Unit">
<_item value="mm">mm</_item>
<_item value="cm">cm</_item>
<_item value="m">m</_item>
<_item value="km">km</_item>
<_item value="in">in</_item>
<_item value="ft">ft</_item>
<_item value="yd">yd</_item>
<_item value="pt">pt</_item>
<_item value="px">px</_item>
<_item value="pc">pc</_item>
</param>
<param name="thickness" type="float" min="1.0" max="100.0" gui-text="Material thickness">1.2</param>
<param name="tool_diameter" type="float" min="0.0" gui-text="Tool diameter (mind the units!)">0.3</param>
<param name="tolerance" type="float" min="-10000.0" max="10000.0" gui-text="Tolerance">0.05</param>
<param name="height" type="float" min="0.0" max="10000.0" gui-text="Height">100</param>
<param name="width" type="float" min="0.0" max="10000.0" gui-text="Width">100</param>
<param name="depth" type="float" min="0.0" max="10000.0" gui-text="Depth">40</param>
<param name="shelve_list" type="string" min="0.0" max="10000.0" gui-text="Shelve heigths (semicolon separated list)">10; 20; 35</param>
<param name="groove_depth" type="float" min="0.0" max="10000.0" gui-text="Groove depth">0.6</param>
<param name="tab_size" type="float" min="0.0" max="10000.0" gui-text="Tab size (approximate; will be resized to evenly fit the side)">10</param>
<effect>
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Finger-jointed/Tabbed Boxes"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_shelves.py</command>
</script>
</inkscape-extension>

View File

@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8"?>
<inkscape-extension xmlns="http://www.inkscape.org/namespace/inkscape/extension">
<name>Tool Covers</name>
<id>fablabchemnitz.de.tool_covers</id>
<param name="tabs" type="notebook">
<page name="parameters" gui-text="Basic parameters">
<param name="title_base" type="description">base</param>
<param name="w1" type="float" min="1" max="200" indent="2" gui-text="Width of tip (w1)[mm]">20</param>
<param name="w2" type="float" min="2" max="200" indent="2" gui-text="Maximum width (w2)[mm]">40</param>
<param name="h1" type="float" min="1" max="200" indent="2" gui-text="Tip length (h1)[mm]">40</param>
<param name="h2" type="float" min="1" max="200" indent="2" gui-text="Length other than tip (h2)[mm]">20</param>
<param name="title_base" type="description">band</param>
<param name="bw" type="float" min="1" max="30" indent="2" gui-text="Band width (bw)[mm]">15</param>
<param name="bl" type="float" min="1" max="90" indent="2" gui-text="Band length (bl)[mm]">30</param>
<param name="title_base" type="description">fastener</param>
<param name="dia1" type="float" min="1" max="50" indent="2" gui-text="Fastener female diameter (dia1)[mm]">10</param>
<param name="dia2" type="float" min="1" max="50" indent="2" gui-text="Fastener male diameter (dia2)[mm]">10</param>
<param name="title_nuishiro" type="description">margin and needle hole</param>
<param name="d1" type="float" min="1" max="5" indent="2" gui-text="Sew it up (d1)[mm]">3</param>
<param name="d2" type="float" min="1" max="10" indent="2" gui-text="Needle hole spacing (d2)[mm]">3</param>
</page>
<page name="details" gui-text="Detailed parameters">
<param name="title_base" type="description">band</param>
<param name="bf" type="float" min="0.1" max="1" indent="2" gui-text="curve coefficient (bf)">0.7</param>
<param name="title_nuishiro" type="description">needle hole</param>
<param name="needle_w" type="float" min="0.5" max="4" indent="2" gui-text="Acupoint width (needle_w)[mm]">1</param>
<param name="needle_h" type="float" min="0.5" max="4" indent="2" gui-text="Height of the needle hole (needle_h)[mm]">1</param>
<param name="needle_tf" type="float" min="-2" max="2" indent="2" gui-text="Needle slope coefficient (needle_tf)">1</param>
<param name="needle_corner_rotation" type="bool" indent="2" gui-text="Angle Tilt Adjustment">true</param>
</page>
<page name="about" gui-text="PliersCover - about">
<param name="version" type="description" xml:space="preserve">PiersCover Inkscape extension
Version 0.92
by Yoichi Tanibayashi
https://ytani01.github.io/PliersCover/
</param>
</page>
</param>
<effect needs-live-preview="true">
<object-type>all</object-type>
<effects-menu>
<submenu name="FabLab Chemnitz">
<submenu name="Shape/Pattern from Generator"/>
</submenu>
</effects-menu>
</effect>
<script>
<command reldir="extensions" interpreter="python">fablabchemnitz_tool_covers.py</command>
</script>
</inkscape-extension>