Creates a three-dimensional solid cylinder.

syntaxSyntax:
DlxRevolve.Cylinder(diameter, length, frontRounding=0.1, backRounding=-1)

Parameters

Parameter Description
diameter Cylinder diameter.
length Cylinder length.
frontRounding Front edge rounding factor. Enter a value between 0 and 1.
backRounding Back edge rounding factor. Enter a value between 0 and 1. If you indicate -1 it takes the same value as that at the front.

Return Value

If the operation ends correctly it returns true otherwise it returns false.

Example

  Copy codeCopy code
function OnBuild3DModel()
{
  var ctx = FWiz.Get3DModelCtx();
  var style = FWiz.Get3DStyle(0);
  style.SetStyle("gold");
  var obj = new DlxRevolve(style);
  obj.Cylinder(5, 10, 1, 0.2);
  ctx.Add(obj);
}

See also