リファレンス › Shapes and Graphics — 206 個のコマンド
amigaball
別名: ab
入力: radius (number) | stacks (number) | sectors (number)
出力: none
Creates an 'Amiga ball', a sphere that alternates sectors between the pen color and the fill color.
amigaball 50 10 20
amigaballoid
別名: abo
入力: radius (number) | stacks (number) | sectors (number) | ratio (number)
出力: none
Creates a stretched or flattened Amiga ball, based on the supplied ratio. Respects setspheroidaxis
amigaballoid 50 10 20 0.5
arc
入力: degrees | radius
出力: none
Creates an arc. The arc is created around the turtle, and the turtle does not move. For arcs the turtle moves along, see leftarc, rightarc
arc 90 20
beginfill
入力: none
出力: none
Starts the collection of points used in creating an arbitrary (user-designed) 2D shape. The turtle's z-position must not change while drawing the shape. The path must not overlap. Once the path is completed, use endfill to generate the shape. See endfill
beginfill
billboard
入力: name (word) | dimensions (list)
出力: none
Creates a 'billboard' using the specified image and the specified list of dimensions [x y]. If the width or height of the billboard is given as a single list item, eg [20], billboard will center the image on the turtle appropriately. See sample
billboard "marquee [100 200]
billboard "image [[100][100]]
box
入力: size (number)
出力: none
Creates a lined square of the specified size. If the parameter is supplied as a single-item list, the box is centered on the turtle. See rect
box 20
box [20]
cappedcutsphere
入力: radius (number) | stacks (number) | sectors (number) | minstack (number) | maxstack (number)
出力: none
Creates a truncated, or cut, sphere with caps on the cut ends. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. See cappedcutspheroid
cappedcutsphere 30 14 32 4 13
cappedcutspheroid
入力: radius (number) | stacks (number) | sectors (number) | minstack (number) | maxstack (number) | ratio
出力: none
Creates a truncated, or cut, spheroid with caps on the cut ends stretched by the specified ratio. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. See cappedcutspheroid, setspheroidaxis
cappedcutspheroid 30 14 32 4 13 2
cappeddome
入力: radius (number) | stacks (number) | sectors (number)
出力: none
Creates a 'capped' dome, a dome with a circle 'sealing' its bottom. See dome, cappeddomoid
cappeddome 30 20 20
cappeddomoid
入力: radius (number) | stacks (number) | sectors (number) | ratio
出力: none
Creates a capped dome stretched by the given ratio. See cappeddome, setspheroidaxis
cappeddomoid 30 20 20 0.5
cappedsphereslice
入力: radius (number) | stacks (number) | sectorstotal (number) | sectorsused (number)
出力: none
Creates a partial sphere of the overall specified radius, using the specified number of vertical 'stacks', and specified number of horizontal 'sectors', based on the given total number of sectors, and the used (displayed) number of sectors. Like an orange cut vertically. See cutsphere, cutsphereslice
sphereslice 20 10 10 5
cappedspheroidslice
入力: radius (number) | stacks (number) | sectorstotal (number) | startsector (number) | endsector (number) | multiplier (number)
出力: none
Creates a partial spheroid of the overall specified radius, using the specified number of vertical 'stacks', and specified number of horizontal 'sectors', based on the given total number of sectors, and the startsector and endsector values, and stretched using the provided multiplier. Like a squashed orange cut vertically. See cutspheroid, cutspheroidslice
spheroidslice 20 10 10 5 10 2
circle
別名: cir
入力: radius
出力: none
Creates a lined circle at the specified radius around the turtle
circle 50
repeat 18 [circle 50 rr 10]
clearimage
入力: imagename (word)
出力: none
Clears the specified image from memory.
clearimage "image
clearimages
入力: none
出力: none
Clears all iamges from memory.
clearimages
clearpins
入力: none
出力: none
Clears the list of pins. See pin
clearpins
cone
別名: cn
入力: radius (number) | depth (number) | sides (number)
出力: none
Creates a cone pointing downward from and centered on the calling turtle.
cone 20 10 20
coneslice
別名: csl
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number)
出力: none
Creates a sliced cone.
coneslice 20 20 20 10
conoid
別名: cno
入力: radius (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a conoid, a cone stretched or compressed based on the provided ratio (1 is normal, 2 is stretched twice as much, 0.5 half as much, etc.)
conoid 20 40 20 2
conoidslice
別名: cosl
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number) | ratio (number)
出力: none
Creates a sliced conoid.
conoidslice 20 20 20 10 2
cube
別名: cb
入力: size or [size]
出力: none
Creates a wireframe cube of the specified size up, right and below the turtle unless the size is given as a [list] in which case it centers around the turtle
cube 20
cuboid
別名: cbo
入力: width | height | depth
出力: none
Creates a wireframe cuboid of the specified dimensions
cuboid 30 20 10
cutcone
別名: cc
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number)
出力: none
Creates a truncated, or cut, cone. See cone
cutcone 10 20 30 30
cutconeslice
別名: ccs
入力: radiusnear (number) | radiusfar (number) | depth (number) | sidestotal (number) | sidesused (number)
出力: none
Creats a cut, sliced cone. See coneslice
cutconeslice 20 40 20 20 10
cutconoid
別名: cco
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a truncated, or cut, conoid, stretched based on the provided ratio. See conoid
cutconoid 10 20 30 30 2
cutconoidslice
別名: ccos
入力: radiusnear (number) | radiusfar (number) | depth (number) | sidestotal (number) | sidesused (number) | ratio (number)
出力: none
Creates a cut, sliced conoid, stretched based on the provided ratio. See conoid
cutconoidslice 10 20 30 30 15 2
cutfunnel
別名: cf
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number)
出力: none
Creates a cut funnel (an uncapped cut cone).
cutfunnel 20 10 20 20
cutfunneloid
別名: cfo
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a cut funneloid (an uncapped cut conoid).
cutfunneloid 20 30 20 20 0.5
cutfunneloidslice
別名: cfos
入力: radiusnear (number) | radiusfar (number) | depth (number) | sidestotal (number) | sidesused (number) | ratio (number)
出力: none
Creates a cut, sliced funneloid (an uncapped cut conoid).
cutfunneloidslice 20 30 20 20 10 0.5
cutfunnelslice
別名: cfs
入力: radiusnear (number) | radiusfar (number) | depth (number) | sidestotal (number) | sidesused (number)
出力: none
Creates a sliced, cut funnel (an uncapped cut cone).
cutfunnelslice 20 10 20 20 10
cutsphere
別名: csp
入力: radius (number) | stacks (number) | sectors (number) | minstack (number) | maxstack (number)
出力: none
Creates a truncated, or cut, sphere. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. See sphere
cutsphere 30 14 32 4 13
cutsphereslice
別名: css
入力: radius (number) | stacks (number) | totalsectors (number) | minstack (number) | maxstack (number) | usedsectors (number)
出力: none
Creates a sliced and cut sphere. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. Displays the portion specified by totalsectors and usedsectors. If usedsector is supplied as a single list value eg [5], cutsphereslice renders only that sector. See sphereslice, cutsphere
cutsphereslice 30 20 20 5 15 10
cutspheroid
別名: cso
入力: radius (number) | stacks (number) | sectors (number) | minstack (number) | maxstack (number) | ratio (number)
出力: none
Creates a truncated, or cut, sphere, stretched by the provided ratio. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. See spheroid
cutspheroid 30 14 32 4 13 0.5
cutspheroidslice
別名: csos
入力: radius (number) | stacks (number) | totalsectors (number) | minstack (number) | maxstack (number) | startsector (number) | endsector (number) | ratio (number)
出力: none
Creates a sliced and cut spheroid. Can be cut on the top, bottom, or both based on specified minstack and maxstack values. Displays the portion specified by startsector and endsector. Is stretched by the ratio provided. See spheroidslice, cutspheroid
cutspheroidslice 30 20 20 5 15 5 10 2
cylinder
別名: cy
入力: radius (number) | depth (number) | sides (number)
出力: none
Creates a cylinder. If depth is provided as a list, centers the cylinder on the turtle
cylinder 20 30 10
cylinderarc
別名: cya
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number)
出力: none
Creates a partial torus, or curved cylinder.
cylinderarc 5 15 20 20 10
cylinderarcslice
別名: cyas
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number) | startsides (number) | endsides (number)
出力: none
Creates a slice of a partial torus, or curved cylinder. If arcsegments is provided as a single list value eg [5] then cylinderarcslice renders only that segment. Note: If you invert the thickness value, you can 'slice' the opposite side.
cylinderarcslice 5 15 20 20 10 5 15
cylinderslice
別名: cys
入力: radius (number) | depth (number) | totalsides (number) | slicesides (number)
出力: none
Creates a rounded wedge shape, like a slice of a round of cheese, starting at the turtle's right vector and moving counter-clockwise.
cylinderslice 20 10 20 10
cylindroid
別名: cyo
入力: radius (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a cylindoid. If the depth parameter is provided as a list, centers the cylindroid on the turtle
cylindroid 20 30 10 2
cylindroidarc
別名: cyoa
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number) | ratio (number)
出力: none
Creates a cylinder arc extruded by the provided ratio.
cylindroidarc 5 15 20 20 10 2
cylindroidarcslice
別名: cyoas
入力: thickness (number) | radius (number) | totalsides (number) | totalsegments (number) | arcsegments (number) | startsides (number) | endsides | ratio (number)
出力: none
Creates a cylinder arc sliced by the provided sides values and extruded by the provided ratio.
cylindroidarcslice 5 15 20 20 10 10 15 2
cylindroidslice
別名: cyos
入力: radius (number) | depth (number) | totalsides (number) | slicesides (number) | ratio (number)
出力: none
Creates a stretched rounded wedge shape, like a slice of a round of cheese, starting at the turtle's right vector and moving counter-clockwise, and stretched using the provided ratio, where 1 is normal, 0.5 is half, 2 is double etc.
cylindroidslice 20 10 20 10 0.5
deformed
別名: dfm
入力: "shape (word) | radius (number) or [X Y (Z)] (list) | [points-x points-y (points-z)] (list) | "tablename (word) | smoothing (number)
出力: none
Creates a quad, voxeloid or sphere out of a lattice of division points, displaces each of those points by the amount held in the matching cell of the named table, then inserts smoothing extra points between each pair of division points using a spline. A single size value is a radius, applied to every axis, while a list gives the shape's full width, height and depth. Division counts are numbers of points, with a minimum of 2. Table values are in turtle-steps and negative values pull a point inwards, while empty, missing or non-numeric cells read as 0. X is to the right of the turtle, Y is forward and Z is up. quad reads sheet 1, cell [y x], and pushes each point along Z, ignoring points-z. sphere reads sheet 1, cell [latitude longitude], as a deviation of that point's radius, ignoring points-z, with latitude running from the -Z pole to the +Z pole and longitude wrapping around. voxeloid reads one sheet per face, in the order +X, -X, +Y, -Y, +Z, -Z, each pushing that face's points along its own outward normal. voxeloid faces are welded at their shared edges and corners, so they never pull apart: where faces meet, their deviations compose, meaning a corner pushed by three sheets travels diagonally. See voxeloid, sphere, quad, newtable, setcell
newtable "bumps [8 12 6]
setcell "bumps [3 3] 40
deformed "quad 100 [5 5] "bumps 0
deformed "sphere 100 [12 8] "bumps 3
deformed "voxeloid 100 [5 5 5] "bumps 2
deleteoverlay
入力: name (word)
出力: none
Deletes the named overlay.
deleteoverlay "myrtlesview
deletesticker
入力: name (word)
出力: none
Deletes the sticker with the specified name. See placesticker.
deletesticker "marquee
dodecahedron
別名: dod
入力: size (number)
出力: none
Creates a dodecahedron (12-sided shape) of the specified size.
dodecahedron 5
dodecahedroid
別名: dodo
入力: size (number) | ratio (number)
出力: none
Creates a dodecahedroid (12-sided shape) of the specified size and stretched using the specified ratio.
dodecahedroid 5 2
dodecahedroid 10 0.5
dome
別名: dm
入力: radius (number) | stacks (number) | sectors (number)
出力: none
Creates a dome
dome 20 10 10
domoid
別名: dmo
入力: radius (number) | stacks (number) | sectors (number) | stretch (number)
出力: none
Creates a stretched dome.
domoid 20 10 10 2
doppel
入力: modelname (word)
出力: none
Like stamp, except creates a reference to the provided model rather than copying the model into the turtle track. This means that if the model changes, its doppel representation will also change.
doppel "myrtle
dot
入力: [x y (z)] (list)
出力: none
Puts a dot at the specified co-ordinates using the specified _pen_ color (this is for Apple Logo compatibility). If z is not specified, z = 0. Dots are removed by clearscreen but not clean (this is a slight deviation from Apple Logo's behavior, for utility.) See dots, dotp, dotsize.
dot [10 10]
dots
入力: none
出力: list
Returns a list of the co-ordinates of all the dots currently in the calling turtle's turtle track. See dot, dotp
show dots
dotsize
入力: none
出力: size (number)
Returns the calling turtle's current dot size. See setdotsize, dot, dotp.
show dotsize
duocutconoid
別名: dcc
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number) | ratio1 (number) | ratio2 (number)
出力: none
Creates a cut conoid with two different oid (stretch) ratios, one for each end. See cutconoid, duocutfunneloid
duocutconoid 20 30 20 20 0.5 2
duocutfunneloid
別名: dcfo
入力: radiusnear (number) | radiusfar (number) | depth (number) | sides (number) | ratio1 (number) | ratio2 (number)
出力: none
Creates a cut funneloid (an uncapped cut conoid) with two different oid (stretch) ratios, one for each end. See cutfunneloid
duocutfunneloid 20 30 20 20 0.5 2
duocylindroid
別名: dco
入力: radius (number) | depth (number) | sides (number) | ratio1 (number) | ratio2 (number)
出力: none
Creates a cylindroid with two different oid (stretch) ratios, one for each end. See cylindroid, duotuboid
duocylindroid 20 20 20 0.5 2
duotuboid
別名: dto
入力: radius (number) | depth (number) | sides (number) | ratio1 (number) | ratio2 (number)
出力: none
Creates a tuboid, or stretched tube, with two different oid (stretch) values, one for each end. Can be used to transition between non-oids and oids, or between two oids. See tuboid
duotuboid 10 20 20 0.5 2
ellipse
別名: ell
入力: half-width (number) | half-height (number)
出力: none
Creates a pen-drawn ellipse of the specified width and height. See oval
ellipse 50 20
endfill
入力: none
出力: none
Concludes the collection of points used in the creation of an arbitrary (user-created) 2D shape. If the path overlaps or changes Z-position the creation of the shape may fail, try can be used to mitigate this. See beginfill
endfill
fiso
入力: half-width height OR [height]
出力: none
Creates a filled isosceles triangle with the center of its base at the root of the selected turtle OR [centered on turtle] and aligned with the turtle's orientation. See iso.
fiso 20 10
funnel
別名: fu
入力: radius (number) | depth (number) | sides (number)
出力: none
Creates a funnel (an uncapped cone).
funnel 20 20 20
funnelslice
別名: fus
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number)
出力: none
Creates a sliced funnel.
funnelslice 20 20 20 10
funneloid
別名: fuo
入力: radius (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a funneloid (an uncapped conoid).
funneloid 20 20 20 0.5
funneloidslice
別名: fuos
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number) | ratio (number)
出力: none
Creates a sliced funneloid.
funneloidslice 20 20 20 10 2
hideoverlay
入力: name (word)
出力: none
Hides the specified overlay. See newoverlay
hideoverlay "myrtlesview
hidesticker
入力: name (word)
出力: none
Hides the sticker specified by the provided name parameter. See placesticker
hidesticker "marquee
icosphere
別名: ico
入力: radius (number)
出力: none
Creates an icosphere of a specified radius. See icosphereoid
icosphere 10
icospheroid
別名: icd
入力: radius (number) | multiplier (number)
出力: none
Creates an icosphereoid of a specified radius, stretched using the provided multiplier.
icosphereoid 10 2
images
入力: none
出力: list
Returns a list of the currently defined images.
show images
iso
入力: half-width height OR [height]
出力: none
Draws an isosceles triangle of the specified width and height, with the turtle positioned at the center of the lower side OR [centered on the turtle], and the triangle pointing in line with the turtle's current orientation.
repeat 18 [iso 20 60 rollright 10]
lat
入力: size
出力: none
Creates a left-facing right-angle triangle. See rat
lat 20
line
入力: length (number)
出力: none
Creates a line of the specified length in front of the calling turtle, without moving that turtle. Line does not respect penup / pendown. If length specified as a [list] eg [5], centres line on turtle.
repeat 36 [if oddp repcount [line 20] else [line 40] rt 10]
listanimations
入力: none
出力: none
Prints out a list of all models that have animations, showing each model name followed by its available animation names.
listanimations
listimages
入力: none
出力: none
Lists the calling turtle's images
listimages
listoverlays
入力: none
出力: none
Prints a list of the currently defined overlays.
listoverlays
liststickers
入力: none
出力: none
Prints the names of the currently defined stickers, one per line. See newsticker, stickers
liststickers
newoverlay
入力: name (word) | turtle (word)
出力: none
Creates a new camera 'overlay' or picture-in-picture with the specified name using the point of view of the specified turtle. You position the overlay on the screen using placeoverlay
newoverlay "myrtlesview "myrtle
newsticker
入力: name (word) | image (word)
出力: none
Defines a new sticker using the provided image. See placesticker
loadimage "marqueeimage "marquee.png
newsticker "marqueesticker "marqueeimage
nextframe
入力: none
出力: none
Waits until the next frame of video is rendered. Useful for creating smooth animations in combination with norender and render (eg render nextframe norender) by otherwise disabling rendering except for one nextframe per loop. Warning: If norender is currently set, nextframe will wait indefinitely!
render nextframe norender
nooverlayrender
入力: "name (word)
出力: none
Suspends rendering (updating) of the named overlay. See overlayrender, which resumes it.
nooverlayrender "overlay
norender
入力: none
出力: none
Disables the renderer. There will be no updates to the graphical output while norender is enabled. This includes view turtle (camera) movement! Pressing the escape key will re-enable render, as will the render primitive. See render
norender
nospeckle
入力: none
出力: none
Disables speckling of voxels and quads. See speckle
nospeckle
notwosided
別名: ntws
入力: none
出力: none
Causes the surface of shapes to only be 'lit' from one side – in OpenGL parlance, only one side has 'normals'. This is the default. If you wish both sides of a shape's surface to be lit, invoke twosided. See twosided
notwosided
noupdatestamp
入力: none
出力: none
Disables automatic stamp updating. See updatestamp.
noupdatestamp
octahedron
別名: oct
入力: size (number)
出力: none
Creates a octahedron (8-sided shape) of the specified size, which is the distance to the farthest tips of the octahedron.
octahedron 5
octahedroid
別名: octo
入力: size (number) | ratio (number)
出力: none
Creates a octahedroid (8-sided shape) of the specified size and stretched using the specified ratio.
octahedroid 5 2
octahedroid 10 0.5
oval
入力: half-width (number) | half-height (number)
出力: none
Creates a filled oval of the specified dimensions. See ellipse
oval 50 20
ovalpie
入力: degrees (number) | half-width (number) | half-height (number)
出力: none
Creates a filled oval-shaped 'pie' of the specified degrees and dimensions. See pie, oval
ovalpie 90 50 20
overlayrender
入力: name (word)
出力: none
Resumes rendering (updating) the selected overlay. See nooverlayrender, which suspends it.
overlayrender "overlay
overlays
入力: none
出力: list
Returns a list of the currently defined overlays.
show overlays
peak
入力: width | height | depth
出力: none
Creates a lined wedge around and beneath the calling turtle. The width distance is the distance to one side of the turtle (the total width of the peak is double the provided width value).
peak 10 20 30
pie
入力: degrees (number) | radius (number)
出力: none
Creates a pie-chart like object of the specified radius and degrees, starting at the turtle's right vector and moving counter-clockwise.
pie 270 20
pin
入力: none
出力: none
Drops a 'pin', for use with pinfill, pinline and pinshard
pin
pinfill
入力: none
出力: none
Creates an arbitrary shape based on the previously dropped pins. Note that pinfill may not work if the lines created by the pins cross! pinfill erases the list of pins. See pin, pinline, pinshard.
pinfill
pinline
入力: number (X)
出力: none
Creates a line using the last X dropped 'pins' in reverse sequential order. See pin
pinline 3
pins
入力: none
出力: list
Returns a list of the currently placed pins. See setpins, pinfill, pinspline
show pins
pinshard
入力: depth (number)
出力: none
Creates a 'shard' (an arbitrary shape of the given depth) using the list of dropped 'pins'. Note that pinshard may fail if the lines created by the pins cross! See pin, pinfill, pinspline
pinshard 5
pinspline
入力: resolution
出力: none
Creates a spline of the given resolution using the previously placed pins as base points. Replaces the existing pins with the resolved pins. Does not erase the list of pins. Can be subsequently used with pinfill (to fill the spline, if it is connected). See pin, pinfill
pinspline 5
placeoverlay
入力: name (word) | [x1% y1% x2% y2%] (list)
出力: none
Places the named overlay on the screen over the list of co-ordinates which are specified in terms of percentages. See newoverlay
placeoverlay "myrtlesview [0 0 50 50]
placesticker
入力: name (word) | [x1% y1% x2% y2%] (list)
出力: none
Places the sticker with the provided name over the area of the screen specified by the provided list, which is in terms of percentages of the screen dimensions, where 100% is the right / bottom and 0% is the left / top. As the name suggests, a sticker is a static image which does not move with the camera view, as if you stuck a sticker to your display. See stickers, stickerp
loadimage "marquee "marquee.png
newsticker "marqueesticker "marquee
placesticker "marqueesticker [25 25 75 75]
poly
入力: radius (number) OR [radius1 radius2 radius3…]| sides (number)
出力: none
Draws a convex polygon of the specified radius (either a single value or list of radii) and number of sides (must equal number of radii if radii provided in a list).
poly 10 6
poly [5 10 5 20] 4
polyellipse
入力: width (number) | height (number) | sides (number)
出力: none
Draws a convex polygon of the specified dimensions and sides.
polyellipse 20 10 10
polyoval
入力: width (number) | height (number) | sides (number)
出力: none
Creates a filled convex polygon of the specified dimensions and sides.
polyoval 10 20 5
polyspot
別名: ps
入力: radius (number) OR [radius1 radius2 radius3…] | sides (number)
出力: none
Creates a filled convex polygon of the specified radius (or radii if provided in a list) and number of sides (must equal number of radii, if list of radii provided).
polyspot 20 5
polyspot [10 5 20 30] 4
prism
別名: pri
入力: width | height | depth
出力: none
Creates a lined prism to the right, forward and under the turtle.
prism 20 10 30
pyramid
別名: py
入力: size (number) OR [width height depth] (list)
出力: none
Creates a pyramid (5-sided shape) of the specified size.
pyramid 10
pyramid [5 10 20]
pyramoid
別名: pyo
入力: size (number) | ratio (number)
出力: none
Creates a pyramoid (stretched pyramid) of the specified size and stretch ratio.
pyramoid 10 2
quad
別名: qd
入力: width | height
出力: none
Creates a 'quad', a two-dimensional filled rectangle of the specified width and height, to the front and right of the turtle, unless negative values are provided. If a list of a single item is provided for either parameter, quad will center the shape created on the appropriate turtle axis. See square
quad 20 10
quad -20 -10
ramp
入力: width (number) | height (number) | depth (number)
出力: none
Creates a filled wedge, or 'ramp' using the provided dimensions.
ramp 10 20 30
rat
入力: length
出力: none
Creates a filled isosceles right angle triangle with two sides of the same specified length.
rat 20
rect
入力: width (number) | height (number)
出力: none
Creates a pen-drawn rectangle of the specified width and height to the front and right of the current turtle, unless a parameter is supplied as a single-item list, in which case the rect is centered on the appropriate turtle axis. See quad, square
rect 10 20
rect [10] 20
resize
入力: imagename (word) | [width height] (list)
出力: none
Resizes the specified image and replaces it.
resize "image [100 50]
rhombus
入力: width (number) | height (number)
出力: none
Creates a 2D rhombus of the specified width and height.
rhombus 30 10
ring
入力: thickness (number) | inner radius (number) | segments (number)
出力: none
Creates a two-dimensional ring of the specified thickness, inner radius and segments. A segment number of 4 creates a square picture frame, while 3 creates a triangle. See ringarc
ring 10 30 10
ringarc
入力: thickness (number) | inner radius (number) | totalsegments (number) | arcsegments (number)
出力: none
Creates a partial ring of the specified number of segments. So, if the totalsegments specified were 10, an arcsegments value of 5 would create a half-ring.
ringarc 10 30 10 5
ringoid
入力: thickness (number) | inner radius (number) | segments (number) | ratio (number)
出力: none
Creates a two-dimensional ring of the specified thickness, inner radius and segments, stretched by the provided ratio. See ring
ringoid 10 30 10 2
ringoidarc
入力: thickness (number) | inner radius (number) | totalsegments (number) | arcsegments (number) | ratio (number)
出力: none
Creates a partial ringoid of the specified number of segments. So, if the totalsegments specified were 10, an arcsegments value of 5 would create a half-ring. If the arcsegments value provided is a list of two, the segments are created from the first value in the list to the second value. See ringarc, ringoid
ringoidarc 10 30 10 5
ringoidarc 5 10 20 [3 5]
roller
入力: thickness inner-radius OR [inner-radius near inner-radius far] depth sides
出力: none
Creates a roller-shaped 3D object of the given composition. See rollerarc
roller 10 30 30 20
rollerarc
入力: thickness inner-radius OR [inner-radius near inner-radius far] depth sides-total sides-used
出力: none
Creates a portion of a roller of the given sectors-used. See roller
rollerarc 10 30 20 10 2
sample
入力: image (word) | position (list)
出力: RGBA (list)
Sample returns a list of the RGBA values of the pixel at the specified position (given in terms of percentages, measured from the bottom-left corner of the image) in the specified loaded image. For example, sample "frog [50 50] will return the color of the pixel located at 50% of frog's height, and 50% of frog's width. Sample can be used to determine the color of a pixel underneath a turtle, for example, by doing a bit of funky math.
show sample "frog [50 50]
saveimage
入力: image | filename
出力: none
Saves an internally stored image. Useful for saving internally created or modified images.
saveimage "myimage "imagefile
setdotsize
入力: size (number)
出力: none
Sets the calling turtle's dot size. All of a turtle's dots are of the same size, but different turtles can have different-sized dots. See dotsize, dot, dotp.
setdotsize 5
seticosphereiterations
別名: sisi
入力: number
出力: none
Sets the complexity of the icosphere, from 0 to 3
seticosphereiterations 3
setoverlayresolution
入力: name (word) | ratio (number)
出力: none
Sets the resolution or pixel density of the named overlay, based on a ratio where 1 is 512 pixels by 384 pixels (at a 16:9 ratio)
setoverlayresolution "myrtlesview 2
setoverlaytransparency
入力: name (word) | boolean
出力: none
Turns on background transparency for the specified overlay. If transparency is off, the background color in the overlay view is solid.
setoverlaytransparency "myrtlesview on
setoverlayupdate
入力: name (word) | frames per second (number)
出力: none
Sets the update frequency of the named overlay to the provided number of frames per second. See newoverlay
setoverlayupdate "myrtlesview 10
setpins
入力: list of positions
出力: none
Sets the list of pins to the given list of lists.
setpins [[0 0 0] [10 10 10]]
setspecklecolors
入力: list
出力: none
Takes a list of colors to be used in the generation of speckle patterns. If you want to weight a random speckle towards a particular color, simply include it more than once in the request, such as the example below.
setspecklecolors [1 1 1 1 2 2 3]
setspecklecolors {:col1 :col1 :col2}
setspeckleplot
入力: plotname (word)
出力: none
Selects the name of the plot to use to generate a speckle, if using the plot style with speckle.
setspeckleplot "myplot
setspecklesize
入力: turtleSteps
出力: none
Sets the pixel size used in generating speckles, in turtleSteps.
setspecklesize 1
setspecklestyle
入力: "styletype
出力: none
Selects the style to use when generating speckles. You can choose from "repeat "dither "random or "plot.
setspecklestyle "random
setspheroidaxis
別名: ssa
入力: boolean
出力: none
Sets the axis by which spheroids are stretched. 0 is equatorial while 1 is polar. See spheroidaxis
setspheroidaxis 1
showoverlay
入力: name (word)
出力: none
Shows the specified overlay. See newoverlay
showoverlay "myrtlesview
showsticker
入力: name (word)
出力: none
Shows the sticker with the provided name. See placesticker
showsticker "marqueesticker
skewfiso
別名: skf
入力: half-width (turtle-units) | height | degrees
出力: none
Creates a filled isosceles triangle "skewed" by the given number of degrees in the X axis. Negative degree values are an acceptable input. See fiso
skewfiso 50 100 45
skewiso
別名: ski
入力: width (turtle-units) | height | degrees
出力: none
Creates an isosceles triangle "skewed" by the given number of degrees in the X axis. Negative degree values are an acceptable input. See iso
skewiso 50 100 45
skewpyramid
別名: skp
入力: size (turtle-units) OR [width height depth] (list) | degrees X | degrees Z
出力: none
Creates a pyramid "skewed" by the specified number of degrees in the X and Z directions.
skewpyramid 50 45 45
skewpyramoid
別名: skpo
入力: size (turtle-units) OR [width height depth] | stretch (ratio) | degrees X | degrees Z
出力: none
Creates a pyramid "skewed" by the specified number of degrees in the X and Z directions, and stretched by the specified ratio
skewpyramoid 50 3 45 45
skewquad
別名: skq
入力: width (turtle-units) | height (turtle-units) | degrees
出力: none
Creates a quad "skewed" by the specified number of degrees, a value which can be negative. See quad
skewquad 50 50 45
skewrect
別名: skr
入力: width (turtle-units) | height | degrees
出力: none
Creates a "skewed" rectangle of the given width and height, skewed by the specified number of degrees, a value which can be negative.
skewrect 100 50 -45
skewtraperect
別名: sktr
入力: width (turtle-units) | height | ratio | degrees
出力: none
Creates a "skewed" trapezoidal rectangle of the specified width and height, whose top is affected by the provided ratio and who is skewed by the specified number of degrees, a value which can be negative. See rect
skewtraperect 100 100 0.5 45
skewtrapevoxeloid
別名: skvo
入力: width | height | depth | ratio-W | ratio-D | degrees X | degrees Z
出力: none
Creates a skewed trapezoidal voxel, the width and depth of whose "top" or side in front of the turtle is stretched or contracted by the given ratios (depth and width), and who is then skewed by the given degree values in the X and Z axis, which can be negative. See trapevoxeloid
skewtrapevoxeloid 50 50 50 0.5 2 45 45
skewtrapezoid
別名: skt
入力: width (turtle-units) | height | ratio | degrees
出力: none
Creates a skewed trapezoidal quad of the specified width and height, whose top is affected by the provided ratio and who is skewed by the specified number of degrees, a value which can be negative.
skewtrapezoid 100 100 0.5 45
skewvoxeloid
別名: skv
入力: width (turtle-units) | height | depth | degrees X | degrees Z
出力: none
Creates a "skewed" voxeloid of the specified dimensions, distorted on the X and Z axis by the specified number of degrees, which can be negative.
skewvoxeloid 100 100 100 45 45
snapshot
入力: imagename (word)
出力: none
Takes a snapshot of the screen and places it into the internal image library with the given imagename. That image can then be used with 'sample' to provide basic 2D collision detection, or used on a 'billboard'. See listimages, sample, billboard
snapshot "screenshot
speckle
入力: none
出力: none
Enables 'speckling' (generated pixelated texturing) of any following square, quad, voxel and voxeloid shapes. These are configured using setspecklestyle (repeat, random or plot), setspecklecolors, setspecklesize and optionally setspeckleplot. nospeckle disables speckling
speckle
specklecolors
入力: none
出力: list
Returns the currently defined speckle colors. See speckle
show specklecolors
speckleplot
入力: none
出力: word
Returns the plot currently used by speckle in the plot style. See setspecklestyle
show speckleplot
specklesize
入力: none
出力: number
Returns the currently defined speckle size. See setspecklesize, speckle
show specklesize
specklestyle
入力: none
出力: word
Returns the current speckle style. See speckle
show specklestyle
"random
sphere
別名: sph
入力: radius (number) | stacks (number) | sectors (number)
出力: none
Creates a sphere of the specified radius using the specified number of stacks and the specified number of sectors. Small stack and sector values create interesting shapes. As opposed to icosphere
sphere 20 10 10
sphereslice
別名: sphs
入力: radius (number) | stacks (number) | sectorstotal (number) | sectorsused (number)
出力: none
Creates a partial sphere of the overall specified radius, using the specified number of vertical 'stacks', and specified number of horizontal 'sectors', based on the given total number of sectors, and the used (displayed) number of sectors. Like an orange cut vertically. See cutsphere, cutsphereslice
sphereslice 20 10 10 5
spheroid
別名: spd
入力: radius (number) | stacks (number) | sectors (number) | multiplier (number)
出力: none
Creates an spheroid of a specified radius, stacks and sectors, stretched using the provided multiplier.
sphereoid 20 10 10 2
spheroidaxis
入力: none
出力: boolean
Returns the current spheroid axis, the axis along which spheroids are stretched. 0 is equatorial and 1 is polar.
show spheroidaxis
spheroidslice
別名: spds
入力: radius (number) | stacks (number) | sectorstotal (number) | startsector (number) | endsector (number) | multiplier (number)
出力: none
Creates a partial spheroid of the overall specified radius, using the specified number of vertical 'stacks', and specified number of horizontal 'sectors', based on the given total number of sectors, and the startsector and endsector values, and stretched using the provided multiplier. Like a squashed orange cut vertically. See cutspheroid, cutspheroidslice
spheroidslice 20 10 10 5 10 2
spline
入力: resolution | points
出力: none
Converts lines connecting the last given number of points into a spline, adding the number of resolution points given for each base point converted. Turns a series of disjointed lines into a smooth curve. spline requires that the pen have been down when drawing the lines it converts, and will not work if the pen was up.
spline 5 10
splinepos
入力: resolution | [point1 point2…]
出力: list
Returns a list of spline points calculated from the given resolution and list of base points.
show splinepos 5 [[0 0 0] [10 10 10] [20 20 20]]
spot
別名: sp
入力: radius (number) OR [radius end%] OR [radius start% end%]
出力: none
Creates a filled circle of the specified radius. When given a list, creates a partial spot clipped vertically (lengthwise along the turtle's up direction). With two values [radius end%], clips from 0% to end%. With three values [radius start% end%], clips from start% to end%. 0% is the top of the spot, 100% is the bottom.
spot 50
spot [50 50]
spot [50 25 75]
square
別名: sq
入力: size (number)
出力: none
Creates a filled square of the specified size. If the parameter is supplied as a single-item list, then the square is centered on the turtle.
square 20
square [20]
stamp
入力: modelname (word) OR [modelname scale]
出力: none
'Stamps' a copy of the specified model at the current location using the current model scale, or the model scale specified in the list form of the input.
cs pu repeat 20 [setmodelscale repcount / 10 stamp "plane fd 3 * repcount]
stickers
入力: none
出力: list
Returns the currently defined stickers. See newsticker
show stickers
tent
入力: half-width (number) | height (number) | depth (number)
出力: none
Creates an opaque (solid) prism to the left, right and front of the turtle.
tent 10 10 5
tetrahedron
別名: th
入力: size (number)
出力: none
Creates a tetrahedron (4-sided shape) of the specified size.
tetrahedron 5
tetrahedroid
別名: tho
入力: size (number) | ratio (number)
出力: none
Creates a tetrahedroid (4-sided shape) of the specified size and stretched using the specified ratio.
tetrahedroid 5 2
tetrahedroid 10 0.5
toroid
別名: tro
入力: thickness (number) | radius (number) | sides (number) | segments (number) | ratio (number) OR [ratio-z ratio-x]
出力: none
Creates a torusoid, an extruded three-dimensional ring, stretched by a ratio where 1 is a normal torus.
toroid 10 30 4 16 0.5
toroidslice
別名: tros
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | startsides (number) | endsides (number) | ratio
出力: none
Creates a 'slice' of a torus, based on the startsides and endsides value. Note that using a negative thickness value inverts the slice.
toroidslice 5 15 20 20 10 15 2
toroidslice -5 15 20 20 10 15 2
torusslice
別名: trs
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | startsides (number) | endsides (number)
出力: none
Creates a 'slice' of a torus, based on the startsides and endsides value. Note that using a negative thickness value inverts the slice.
torusslice 5 15 20 20 10 15
torusslice -5 15 20 20 10 15
torus
別名: tr
入力: thickness (number) | radius (number) | sides (number) | segments (number)
出力: none
Creates a torus, also known as a rhombus or a donut, a three-dimensional ring. Sides and segments can be as low as 3.
torus 10 30 4 16
traperect
別名: tre
入力: width (turtle-units) | height | ratio
出力: none
Creates a trapezoidal rectangle of the given width, height and with its far end contracted or expanded by the given ratio. See rect
traperect 50 50 2
trapevoxeloid
別名: tvo
入力: width (turtle-units) | height | depth | ratio-W | ratio-D
出力: none
Creates a trapezoidal voxel, whose far 'end' is affected by the given width and depth ratios. If any of the first three parameters is given as a list with a single item, then the shape is centered on that parameter's axis.
trapevoxeloid 50 50 50 0.5 2
trapezoid
別名: tz
入力: width (turtle-units) | height | ratio
出力: none
Creates a quad whose far 'end' is expanded or contracted based on the provided ratio. See quad, skewtrapezoid
trapezoid 100 50 5
triangle
別名: tri
入力: width (number) | height (number)
出力: none
Creates a wireframe (pen-drawn) right-angle triangle to the front and right of the turtle.
triangle 10 20
tube
別名: tb
入力: radius (number) | depth (number) | sides (number)
出力: none
Creates a hollow tube.
tube 10 20 20
tubearc
別名: tba
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number)
出力: none
Creates a tube arc.
tubearc 5 15 20 20 10
tubearcslice
別名: tbas
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number) | startsides (number) | endsides (number)
出力: none
Creates a slice of a partial tube. Note: If you invert the thickness value, you can 'slice' the opposite side.
tubearcslice 5 15 20 20 10 5 15
tubeslice
別名: tbs
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number)
出力: none
Creates a 'slice' of a tube, based on the sidestotal and sidesused values.
tubeslice 20 20 10 4
tuboid
別名: tbo
入力: radius (number) | depth (number) | sides (number) | ratio (number)
出力: none
Creates a tuboid, or stretched tube.
tuboid 10 20 20 0.5
tuboidarc
別名: tboa
入力: thickness (number) | radius (number) | sides (number) | totalsegments (number) | arcsegments (number) | ratio (number)
出力: none
Creates a tube arc extruded by the provided ratio.
tuboidarc 5 15 20 20 10 2
tuboidarcslice
別名: tboas
入力: thickness (number) | radius (number) | totalsides (number) | totalsegments (number) | arcsegments (number) | startsides (number) | endsides | ratio (number)
出力: none
Creates a tube arc sliced by the provided sides values and extruded by the provided ratio.
tuboidarcslice 5 15 20 20 10 10 15 2
tuboidslice
別名: tbos
入力: radius (number) | depth (number) | sidestotal (number) | sidesused (number) | ratio (number)
出力: none
Creates a stretched 'slice' of a tube, based on the sidestotal and sidesused values, and the stretching ratio (normal is 1, half is 0.5, double is 2 etc.)
tuboidslice 10 20 20 10 0.5
tuboidslice 10 20 20 10 2
twosided
別名: tws
入力: none
出力: none
Lights both sides of the surface of a shape. Useful for shapes where both sides of the surface are visible. The default is that they are unlit. Whether to use twosided or not is a purely stylistic choice in most cases. See notwosided, which turns twosided off.
twosided
updatestamps
入力: none
出力: none
Causes stamps to be updated when the turtle model is updated. This is disabled by default. See noupdatestamp, updatestampp
updatestamps
voxel
別名: vx
入力: turtle-steps or [turtle-steps]
出力: none
Creates a filled cube turtle-steps wide, high and deep to the right, forward and down of the turtle, unless the parameter is provided as a list, in which case the voxel is created around the turtle. See voxeloid.
voxel 20
voxel [20]
voxeloid
別名: vxo
入力: turtle-steps-right turtle-steps-forward turtle-steps-deep
出力: none
Creates a filled cuboid to the right, forward and down of the turtle. If any parameter is provided as a list, eg [20], then center the voxel on that axis. See voxel.
voxeloid 10 20 30
voxeloid 10 [20] 30
voxeloid [10] [20] [30]
wedge
入力: turtle-steps-right turtle-steps-forward
出力: none
Creates a filled right-angle triangle turtle-steps-right from the turtle and turtle-steps-forward from the turtle in dimensions.
wedge 20 4
wiggle
入力: distance OR [orbitdegrees] OR [arcdegrees arcsize] | sine OR [sine1 sine2] | amp OR [amp1 amp2]
出力: none
Creates a 'wiggle', which can create AMAZING shapes using sine waves! Try these examples, and play with their values:
wiggle 100 10 5
wiggle [360] 18 4
beginfill wiggle [360 100] [10 5] 2 endfill
beginfill wiggle [360 50] [8 3] [2 1] endfill
icosphereiterations
入力: none
出力: number
Returns the current number of iterations used when creating icospheres.
print icosphereiterations
hinge
入力: "name [commands]
出力: none
Creates a hinge joint in a procedural model, for use inside NEWMODEL or SETMODEL blocks. Hinges allow parts of the model to be rotated independently after the model is created. The name is used to identify the hinge when using SWIVEL or SETHINGEORIENTATION. Commands inside the block create geometry that will be attached to this hinge and move with it. Hinges can be nested to create articulated hierarchies like robot arms.
newmodel "arm [
setpenstyle "tube setpw 3
setpc yellow fd 30
hinge "shoulder [
setpc orange fd 20
hinge "elbow [
setpc red fd 15
]
]
]
hinges
入力: "modelname
出力: list
Returns a list of hinge/joint names available in the specified model. Returns an empty list if the model has no hinges.
show hinges "arm
[shoulder elbow]
hingesp
入力: "modelname
出力: boolean
Returns TRUE if the specified model has hinges/joints, FALSE otherwise.
show hingesp "arm
TRUE
hingep
入力: "hingename
出力: boolean
Returns TRUE if the specified hinge exists in the current turtle's model, FALSE otherwise.
show hingep "shoulder
TRUE
listhinges
入力: none
出力: none
Prints a list of all loaded models that have hinges, along with their hinge names.
listhinges
arm: shoulder elbow
robot: head leftarm rightarm
sethingeorientation
入力: "hingename [pitch heading roll]
出力: none
Sets the orientation of the specified hinge to the given pitch, heading, and roll values in degrees. This is an absolute orientation - it sets the hinge TO these values, replacing any previous orientation. Child hinges in the hierarchy will move along with their parent.
sethingeorientation "shoulder [30 0 0]
sethingeorientation "elbow [0 45 0]
swivel
入力: "hingename heading | [heading pitch]
出力: none
Rotates the specified hinge BY the given amounts in degrees. Pass a single number to change heading only, or a list [heading pitch] to change both. This is a relative rotation - it adds to the current orientation. Useful for animations where you want to incrementally rotate a joint.
swivel "elbow 10
repeat 36 [swivel "elbow 10 wait 1]
swivel "shoulder [15 5]
hingeorientation
入力: "hingename
出力: list
Returns the current orientation of the specified hinge as a list [pitch heading roll] in degrees.
show hingeorientation "shoulder
[30 0 0]
hingeorientationorder
入力: "hingename
出力: word
Returns the current rotation order for the specified hinge. The order determines in which sequence pitch, heading, and roll rotations are applied. Default is "phr" (pitch, heading, roll).
show hingeorientationorder "shoulder
phr
sethingeorientationorder
入力: "hingename "order
出力: none
Sets the rotation order for the specified hinge. The order must be a permutation of p (pitch), h (heading), and r (roll). Valid orders are: phr, prh, hpr, hrp, rph, rhp. Different orders can produce different final orientations when multiple rotations are combined.
sethingeorientationorder "shoulder "hpr
resethinges
入力: none
出力: none
Resets all hinge orientations on the current turtle's model to [0 0 0]. Useful for returning an articulated model to its default pose.
resethinges
plotcopy
入力: "source "destination | [destination]
出力: none
Copies the content of plot "source to "destination. If the list syntax [destination] is used, only defined (non-zero) points are copied, leaving other points in the destination unchanged. If "destination is used (without brackets), the entire contents of source replaces destination completely. If destination does not exist when using "destination syntax, it will be created.
plotcopy "frame1 "frame2
plotcopy "frame1 [frame2]
setpinorigin
入力: [x y z]
出力: none
Sets the origin point used when drawing transformed pins. Drawing commands (pinline, pinfill, pinspline) will offset pins by this amount. Does not modify the original pins. Alias: spino
setpinorigin [100 50 0]
pin setpos [0 0 0] pin setpos [10 0 0] pin
pinline 2
; draws line from [100 50 0] to [110 50 0]
pinorigin
入力: none
出力: list
Returns the current pin origin offset as [x y z]. Alias: pino
setpinorigin [100 50 0]
show pinorigin
[100 50 0]
setpinscale
入力: scale
出力: none
Sets the scale factor used when drawing transformed pins. Drawing commands (pinline, pinfill, pinspline) will scale pins by this amount relative to the origin. Does not modify the original pins. Alias: spins
setpinscale 2
pin setpos [10 0 0] pin setpos [20 0 0] pin
pinline 2
; draws line scaled by 2
pinscale
入力: none
出力: number
Returns the current pin scale factor. Alias: pscl
setpinscale 2
show pinscale
2
setpintransform
入力: [a b c]
出力: none
Sets the rotation angles used when drawing transformed pins. The angles follow orientationorder (default phr = [pitch heading roll]). Drawing commands (pinline, pinfill, pinspline) will rotate pins by these angles. Does not modify the original pins. Alias: spint
setpintransform [0 90 0]
pin setpos [10 0 0] pin setpos [20 0 0] pin
pinline 2
; draws line rotated 90 degrees heading
pintransform
入力: none
出力: list
Returns the current pin transform angles as a list. Alias: pint
setpintransform [45 90 0]
show pintransform
[45 90 0]
xpins
入力: none
出力: list
Returns the pins with all transformations applied (scale, rotate, offset). Useful for inspecting the transformed pins without drawing them.
pin setpos [10 0 0] pin setpos [20 0 0] pin
setpinscale 2
setpinorigin [100 0 0]
show xpins
; shows scaled and offset pins