70002667 Export new geometry functions for web control

Article 70002667
Type Wish
Product WebJS
Version 1103
Date Added 4/23/2025 12:00:00 AM
Fixed 11.4.2 (4/23/2025 12:00:00 AM)
Submitted by Efstathios Tsoumas

Summary

Export new geometry functions vdgeo.CrossProduct vdgeo.VectorNormalize kai vdgeo.matrixSetFrom

Solution

new functions was exported in version 11.4.2

        vdgeo.CrossProduct( v1, v2)//  Calculates and returns a Vector produced by crossing two other Vectors.

        vdgeo.VectorNormalize(v)  // Convert a Vector to one unit length.
        Returns False is the vdgeo.VectorLength(v) is equal to zero(0.0)

        vdgeo.matrixSetFromorigin, xdir, ydir)// Calculate and returns this Matrix with a given origin and x,y direction.
        example:
        var origin = [0, 0,0 ];
        var xdir = [1, 0, 0];
        var ydir = [0, 0, 1];
        var user2world = vdgeo.matrixSetFrom(origin, xdir, ydir);
        var world2user = vdgeo.matrixGetInversion(user2world);
        var ptworld = vdgeo.matrixtransform(user2world, [1, 1, 0]);

Send comments on this topic.