Skip to content
arnholm edited this page May 1, 2017 · 1 revision

square

A square is defined by its size. It extends from the origin in x and y directons, unless the “center” option is specified, in which case the geometric centre of the square will coincide with the origin.

Parameter name Description Status
size Extent in x and y required
center center on origin (true/false) optional (default=false)

XML syntax for basic square primitive (2d)

<square size="20" center="false"/>

Complete example with a square extruded to create a 3d solid

<?xml version="1.0" encoding="utf-8"?>
<xcsg version="1.0">
    <linear_extrude dz="1">
        <square size="20" center="false"/>
    </linear_extrude>
</xcsg>

square with center="false"

square with center="true"

Clone this wiki locally