# `class WMSmoothChain`

Available on all platforms

A smooth chain

## Instance Fields

### `var controls:Array<WMCPoint>`

list of control points

### `var curves:Array<CubicCurve>`

list of curves which consist of this smooth chain

### `var n_interp:Int`

number of points to be inserted between adjacent points

### `function new(ops:Array<Dynamic>, ni:Int):Void`

Constructor.

### `function clear():Void`

clear all curves and control points

### `function genCoil(width:Float, quality:Int, from:Int, to:Int):Tube3D`

Generate coil of using `width` as the radius, `quality` as quality, and control points between `from` to `to`.

### `function genRibbon(width:Float, thickness:Float, from:Int, to:Int, smoothing:Bool):Ribbon3D`

Generate a ribbon. `thickness` is the ribbon thickness and `smoothing` request special smoothened chain for beta-strand. See `genCoil` function for other details.

### `function getCurve(i:Int):CubicCurve`

returns a curve of index `i`

### `function getPositions():Array<Point3D>`

returns array of control point positions

### `function get_controls():Array<WMCPoint>`

getter of `controls`

### `function get_curves():Array<CubicCurve>`

getter of `curves`

### `function get_n_interp():Int`

getter of n_interp

### `function initialize(ops:Array<Dynamic>):Void`

create smooth curve using given list of anonymous array `ops`. An element of ops should have p(position), n(number of points to be inserted), dir(direction of face).

If `ops` is not given, this function does nothing.

### `function set_n_interp(n:Int):Int`

setter of n_interp