<p>In OpenSCAD, I am trying to make a linear_extrude on a shape imported from an svg. The svg file contains multiple path. I would like to scale each path separately. I have tried the following code, but the whole import is considered a single shape resulting in the image below.</p>
<pre><code>linear_extrude(height = 5, center = true, scale=1.2)
    import(file = &quot;xxx.svg&quot;, center = true, dpi = 96);
</code></pre>
<p><a href="https://i.stack.imgur.com/cg1Rq.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cg1Rq.png" alt="result" /></a></p>
<p>How can I have each of the letters to have 'its own pyramid' ?</p>
<p>I know I could create one SVG per letter. But for simplicity sake I would like to have only one SVG file, as I want to create much more complex motives in the future. My final goal is to create stamps from SVG drawings.</p>
<p>Edit:
Alternative tried after Mick's comment (same result):</p>
<pre><code>module pyramidChildren(height){
    for ( i= [0:1:$children-1])  
      linear_extrude(height = height, scale=1.5)
        children(i);
 }
 
 pyramidChildren(5)
    import(file = &quot;xxx.svg&quot;, center = true, dpi = 96);
</code></pre>
<p>I have tried to use the basic svg (multiple paths) and also to group each path (with only itself) without changes in the result.</p>

[{'answer_id': 15144, 'author': 'Oneira', 'author_id': 25976, 'author_profile': 'https://3dprinting.stackexchange.com/users/25976', 'pm_score': 2, 'selected': False, 'text': '<p>Lame solution: creating stepped pyramid with offset. I realized that scale will not worked for motives with holes inside. Offset seems then more appropriate than scale for my application (creation of stamps)</p>\n<p>It takes ages to render, but it could be enough for simple patterns. Any better solution are still welcome...</p>\n<pre><code>module buildPyramidalExtrude(height,maxOffset,nSlices){\n    heightIncrement = height/nSlices;\n    offsetIncrement = maxOffset/(nSlices-1);\n    for(i=[1:nSlices])\n        linear_extrude(height=i*heightIncrement)\n              offset(r = maxOffset-(i-1)*offsetIncrement)\n                children();\n}\n\nbuildPyramidalExtrude(4,2.5,20)\n   import(file = &quot;Farm/cow.svg&quot;, center = true);\n</code></pre>\n<p><a href="https://i.stack.imgur.com/pGUnC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pGUnC.png" alt="result" /></a></p>\n'}, {'answer_id': 15147, 'author': 'R.. GitHub STOP HELPING ICE', 'author_id': 11157, 'author_profile': 'https://3dprinting.stackexchange.com/users/11157', 'pm_score': 2, 'selected': False, 'text': '<p>What you seem to want is not per-path scale but offset. This is an <a href="https://github.com/openscad/openscad/pull/2079" rel="nofollow noreferrer">open PR in OpenSCAD</a> and hopefully will be upstream soon.</p>\n'}, {'answer_id': 18922, 'author': 'tarulen', 'author_id': 33113, 'author_profile': 'https://3dprinting.stackexchange.com/users/33113', 'pm_score': 0, 'selected': False, 'text': "<p>One option is to use <code>minkowski()</code> to combine the svg with a cone. On the positive side, it gives a rather nice result, but the downsides are:</p>\n<ul>\n<li>it's pretty slow</li>\n<li>it fattens the bottom rather than shrinking the top, so depending on your needs you may have to invert the image, run <code>minkowski</code>, then invert again.</li>\n</ul>\n<p>Another option is to convert to grayscale <strong>png and apply a blur</strong> with an external tool, then to import using <code>surface()</code> (the gray blur will become a nice slope). That will both fatten the bottom and shrink the top, but keeping only the top half should give the desired result.</p>\n"}]
['https://3dprinting.stackexchange.com/questions/15130', 'https://3dprinting.stackexchange.com', 'https://3dprinting.stackexchange.com/users/25976/']