UNPKG

@bitbybit-dev/core

Version:

Bit By Bit Developers Core CAD API to Program Geometry

62 lines (61 loc) 1.92 kB
import { ContextBase } from "../../context"; import * as Inputs from "../../inputs/inputs"; import { MathBitByBit } from "@bitbybit-dev/base"; /** * Contains various methods for nurbs circle. * These methods wrap around Verbnurbs library that you can find here http://verbnurbs.com/. * Thanks Peter Boyer for his work. */ export declare class VerbCurveCircle { private readonly context; private readonly math; constructor(context: ContextBase, math: MathBitByBit); /** * Creates the circle Nurbs curve * @param inputs Circle parameters * @returns Circle Nurbs curve */ createCircle(inputs: Inputs.Verb.CircleParametersDto): any; /** * Creates the arc Nurbs curve * @param inputs Arc parameters * @returns Arc Nurbs curve */ createArc(inputs: Inputs.Verb.ArcParametersDto): any; /** * Gets the center point of the circle or an arc * @param inputs An arc or a circle Nurbs curve * @returns Point */ center(inputs: Inputs.Verb.CircleDto): number[]; /** * Gets the radius of the circle or an arc * @param inputs An arc or a circle Nurbs curve * @returns Radius */ radius(inputs: Inputs.Verb.CircleDto): number; /** * Gets the max angle of the arc in degrees * @param inputs Arc * @returns Max angle in degrees */ maxAngle(inputs: Inputs.Verb.CircleDto): number; /** * Gets the min angle of the arc in degrees * @param inputs Arc * @returns Min angle in degrees */ minAngle(inputs: Inputs.Verb.CircleDto): number; /** * Gets the x angle of the arc * @param inputs Circle * @returns X axis vector */ xAxis(inputs: Inputs.Verb.CircleDto): number[]; /** * Gets the y angle of the arc * @param inputs Circle * @returns Y axis vector */ yAxis(inputs: Inputs.Verb.CircleDto): number[]; }