figureone
    Preparing search index...

    Star options object that extends OBJ_Generic (without drawType) and OBJ_FigurePrimitive

    • sides number — (4)
    • radius number — (1)
    • innerRadius number — (radius / 2)
    • rotation number — shape rotation during vertex definition (different to a rotation step in a trasform) (0)
    • offset TypeParsablePoint — shape center offset from origin during vertex definition (different to a translation step in a transform) ([0, 0])
    • line OBJ_LineStyleSimple — line style options
    • drawBorderBuffer (number | TypeParsableBorder) & TypeParsableBorder — override the OBJ_Generic drawBorderBuffer with number to make the drawBorderBuffer a polygon that is number thicker than the radius (0)

    To test examples, append them to the boilerplate

    // Simple 5 pointed star
    figure.add({
    name: 's',
    make: 'star',
    radius: 0.5,
    sides: 5,
    });
    // 7 pointed dashed line star
    figure.add({
    name: 's',
    make: 'star',
    radius: 0.5,
    innerRadius: 0.3,
    sides: 7,
    line: {
    width: 0.02,
    dash: [0.05, 0.01],
    },
    });
    // Star surrounded by stars
    figure.add({
    name: 's',
    make: 'star',
    radius: 0.1,
    sides: 5,
    rotation: -Math.PI / 2,
    // line: { width: 0.01 },
    copy: [
    {
    to: [0.6, 0],
    original: false,
    },
    {
    along: 'rotation',
    num: 16,
    step: Math.PI * 2 / 16,
    start: 1,
    },
    {
    to: new Fig.Transform().scale(3, 3).rotate(Math.PI / 2),
    start: 0,
    end: 1,
    },
    ],
    });
    @interface