multiple splines for a wall with window?

MarkusR

Member
hello, is it possible to create multiple splines for one extrude.
I try to create a script that produce a wall with window.
if the window have different size sometimes the surface front and back is wrong at extrude.
somehow in need a rectangle with a hole rectangle spline.
good.png

wrong.jpeg
script.png
scriptinput.jpeg
 
hello Helmut,
that is good to know and works well in the 3d editor but i not found this merge tool in script syntax.

i need to start from function buildObject(obj)
it create a spline in real time if parameters are changed.

i look for something like this
var outer = new Spline()
var inner = new Spline()
var inner = new Spline()
var result = Spline.merge([outer,inner,inner])
 
Last edited:
:sick: Sorry Markus, I have no idea how to simulate that in Java script.
:) Servus aus Wien

PS: If you need to animate the control points of the merged splines (be it the frame or the window), you can achieve that without scripting via Record Points.
 
Actually, this usually works, although it creates double geometry, so I would not prefer this method.
However, we may also encounter an error in the way Cheetah3D handles combined paths - see the examples on the left:
CompoundPath.png

Fill rule "nonzero" in the SVG world:
NoneZero.png
 

Attachments

  • CompoundPathIssue.jas.zip
    11.6 KB · Views: 28
Last edited:
@Helmut DE: Grüße aus Oederquart und danke für den Tipp, das Skript soll mir nur helfen für ein Gebäude.
 
Last edited:
if merge does not exists in scripting i think i will create this wall by boxes.
merge (by script) would be so powerfull for multiple window frames in the wall.
 
if merge does not exists in scripting i think i will create this wall by boxes.
merge (by script) would be so powerfull for multiple window frames in the wall.
I don't know java scripting but maybe you can use the Create Spline command.

If I call up a Rectangular Spline, make it editable and select it.
Then click on New Spline in the Create Spline Panel.
This automatically "merges" the new spline with the selected spline.
Four clicks to make a square, but to finish and close the new spline,
you need to click Close Spline in the same panel.
 
I may have encountered a bug. In 7.5.3 we could still distribute spline objects via the particle system, which does not work in 8.x at the moment. This doesn't help with scripting, but a facade with window openings is created in no time.
ParticleSysSplineDistro.png
 
the trick with splines is as Helmut mentioned,
you need path for the border, and a path for each window.
a new path is started by .move(pos); then extrude works fine.
downside with spline and extrude there is no window object inside.
advantage multiple window holes.
Mittel (Bildschirmfoto 2024-02-17 um 15.48.17).jpeg

i think i will create a extra script for window frame and glass.
 
Last edited:
Back
Top