Table of Contents

Class vdgeo

Namespace
vdWebLibrary
Assembly
JsPropertiesExtractor.dll

Contains functions concerning mathematical and trigonometrical calculations.

Access this object directly with his name vdgeo from anywhere in your page without the need to create an instance of it, because it is a global object of the library.

public class vdgeo
Inheritance
vdgeo
Inherited Members

Properties

CURVERESOLUTION

Gets and set the resolution value that is used when drawing curved entities (circles, ellipses etc). For more information check curveresolution in the VDF.chm help file.

DefaultAngularEquality

Get default equality used to compare angle properties.

DefaultLinearEquality

Get default equality used to compare linear length properties.

DefaultPointEquality

Get default equality used to compare Point properties.

DefaultScaleEquality

Get default equality used to compare scale properties.

DefaultVectorEquality

Get default equality used to compare Vector properties.

EPSILON

Returns the EPSILON used in various mathematical calculations , equal to 4.94066e-324.

HALF_PI

Returns the 1/2*PI value equal to 1.5707963267948.

INCH_MM

Returns the Inches To Millimeters calculation double equal to 25.4.

PI

Returns the PI value equal to 3.1415926535898;.

VD_270PI

Returns the 3/4*PI value equal to 4.7123889803844.

VD_TWOPI

Returns the 2*PI value equal to 6.2831853071796.

Methods

Arc2Bulge(double, double)

Returns the bulge of a given arc.

ArcFrom3Points(object, object, object)

Calculates the arc that passes between three points.

AreEqual(double, double, double)

Checks if the difference between the two numerical values is smaller or larger than the equality passed as the third parameter.

CrossProduct(object, object)

Calculates and returns a Vector produced by crossing two other Vectors.

DegreesToRadians(double)

Converts the passed value in degress to radians.

Distance2D(object, object)

Calculates and returns the distance between the two passed points.

Distance3D(object, object)

Calculates and returns the distance between the two passed points in three dimensions.

FixAngle(double, double)

Makes sure that the angle passed as parameter is restrained between 0 and 2PI radians. Also checks if the angle is equal to one of the main angles of the circle and depending on the equality parameter, returns the fixed value whithout any digits.

GetAngle(object, object)

Calculates and returns the angle two points form. This is done by comparing the two vectors formed with starting point the 0,0,0 and ending points the two passed parameters.

GetPlineSegmentIndexFromPoint(object, object[], bool, object)

Finds the closed segment of the polyline a passed point

IntersectionLL2D(object, object, object, object, double, object)

Calculates the intersection point between two lines that belong to the same plane(z values of the lines are equal).

MidPoint(object, object)

Calculates and returns a point that lies in the middle of the two passed points.

PointInRegion(double, double, object)

Returns true if the given point is inside the region defined by the given points.

RadiansToDegrees(double)

Converts the passed value in radians to degrees.

VectorDirection(object, object)

Gets the direction set by two points.

VectorLength(object)

Returns the length of the passed vector(x,y,z)

VectorNormalize(object)

Convert a Vector to one unit length.

distPointFromLine(object, object, object)

Calculates the perpendicular distance of a point from a line.

linenearest(object, object, object, bool)

returns the nearest of a pick point to a line segment

matrixApplyECS2WCS(object, object)

Modify the passed matrix in order to be perpendicular to the passed vector.

matrixApplyECS2WCS_2(object, object, object)

Modify the passed matrix in order to be perpendicular to the passed zAxis vector and the x direction of the matrix is equal to the passed xAxis vector.

matrixApplyWCS2ECS(object, object)

Multiplies the passed Matrix with the invertion of the ApplyECS2WCS Matrix.

matrixCopyFrom(object, object)

Copy the contents of passed from to the passed matrix

matrixGetInversion(object)

Gets the invertersion of the passed parameter.

matrixInit(object)

Initialize the passed matrix

matrixInvert(object)

Invert the passed Matrix.

matrixIsUnitMatrix(object)

Check if the passed matrix is initialized

matrixRotateAboutAxis(object, object, double)

Applies a rotation in radians around passed axis direction to the passed matrix.

matrixRotateXMatrix(object, double)

Applies a rotation in radians around X direction to the passed matrix.

matrixRotateYMatrix(object, double)

Applies a rotation in radians around Y direction to the passed matrix.

matrixRotateZMatrix(object, double)

Applies a rotation in radians around Z direction to the passed matrix.

matrixScales(object)

Returns the scales as new [x,y,z] of the passed matrix

matrixSetFrom(object, object, object)

Calculate and returns this Matrix with a given origin and x,y direction.

matrixShear(object, double, double)

Applies the passed Shear x and Shear y values to passed matrix.

matrixclone(object)

Returns a new clone of the passed matrix

matrixmult(object, object)

Multiplies matrix1 x matrix2 and return a new matrix result

matrixmult1(object, object)

Multiply passed matrix x withmatrix and set the result to the passed matrix

matrixoffset(object)

Returns the offset as new [x,y,z] of the passed matrix

matrixscale(object, double, double, double)

Applies x,y,z scales to the passed matrix.

matrixtransform(object, object)

Transforms the passed point with a matrix.

matrixtransformBOX(object, object)

Transform the passed box (xmin,ymin,zmin,xmax,ymax,zmax) with passed matrix

matrixtransformEntity(object, object, vdrawObj)

Transforms the passed entity with a matrix.

matrixtransformPts(object, object)

Transforms all points objects of the passed collection with passed matrix.

matrixtransformVector(object, double, double, double, bool)

Transforms the vector using the passed matrix.

matrixtransformVertex(object, object)

Tranforms the passed vertex with the passed matrix.

matrixtransformVertexes(object, object)

Transforms all items of the passed collection with passed matrix.

matrixtranslate(object, double, double, double)

Applies an offset to the passed matrix.

matrixxdir(object)

Returns the x direction as new [x,y,z] of the passed matrix

matrixydir(object)

Returns the y direction as new [x,y,z] of the passed matrix

matrixzdir(object)

Returns the z direction as new [x,y,z] of the passed matrix

newmatrix()

Returns a new initialized matrix

newpoint(double, double, double)

Creates and returns a new 3 sized Array object. The first element of the Array represents the x value of the point, the second element the y value and the third the z value.

newvertex(double, double, double, double)

Creates and returns a new 4 sized Array object. The first element of the Array represents the x value of the vertex, the second element the y vertex, the third the z vertex and the fourth the bulge of the vertex.

pointPolar(object, double, double)

Calculates and returns a vdgeo.newpoint at a given distance and angle from the passed point.

pointonline(object, object, object)

Checks if the passed point is on a line using the DefaultLinearEquality.

projectionPointOnLine(object, object, object)

Returns the projection of the point 'P' to the line 'P0 - P1'

projectionTomatrix(object, double, object)

projects the passed point to a plane defined by the passed matrix.

The passed point is updated with new coordinates relative to te passed plane after the method returns