build/browser/index.js
/**
     * This function computes the reference meridian of an object.
     * @hidden
     */
This function computes the reference meridian of an object.
@hidden
This function computes the reference meridian of an object . @hidden
function referenceMeridian(options, fallback) {
        if (options.tilt) {
            var meridian = Geometric3.fromVector(canonicalMeridian$1).rotate(options.tilt);
            return vec(meridian.x, meridian.y, meridian.z);
        }
        else if (options.meridian) {
            var meridian = options.meridian;
            return vec(meridian.x, meridian.y, meridian.z).direction();
        }
        else if (options.cutLine) {
            console.warn("cutLine is deprecated. Please use meridian instead.");
            var meridian = options.cutLine;
            return vec(meridian.x, meridian.y, meridian.z).direction();
        }
        else if (options.axis) {
            var B = Geometric3.dualOfVector(canonicalMeridian$1);
            var tilt = Geometric3.rotorFromVectorToVector(canonicalAxis$4, options.axis, B);
            var meridian = Geometric3.fromVector(canonicalMeridian$1).rotate(tilt);
            return vec(meridian.x, meridian.y, meridian.z).direction();
        }
        else if (typeof options.height === 'object') {
            console.warn("height is deprecated. Please use axis instead.");
            var axis = options.height;
            var B = Geometric3.dualOfVector(canonicalMeridian$1);
            var tilt = Geometric3.rotorFromVectorToVector(canonicalAxis$4, axis, B);
            var meridian = Geometric3.fromVector(canonicalMeridian$1).rotate(tilt);
            return vec(meridian.x, meridian.y, meridian.z).direction();
        }
        else {
            return vec(fallback.x, fallback.y, fallback.z);
        }
    }
function referenceMeridian ( options , fallback ) { if ( options . tilt ) { var meridian = Geometric3 . fromVector ( canonicalMeridian$1 ) . rotate ( options . tilt ) ; return vec ( meridian . x , meridian . y , meridian . z ) ; } else if ( options . meridian ) { var meridian = options . meridian ; return vec ( meridian . x , meridian . y , meridian . z ) . direction ( ) ; } else if ( options . cutLine ) { console . warn ( "cutLine is deprecated. Please use meridian instead." ) ; var meridian = options . cutLine ; return vec ( meridian . x , meridian . y , meridian . z ) . direction ( ) ; } else if ( options . axis ) { var B = Geometric3 . dualOfVector ( canonicalMeridian$1 ) ; var tilt = Geometric3 . rotorFromVectorToVector ( canonicalAxis$4 , options . axis , B ) ; var meridian = Geometric3 . fromVector ( canonicalMeridian$1 ) . rotate ( tilt ) ; return vec ( meridian . x , meridian . y , meridian . z ) . direction ( ) ; } else if ( typeof options . height === 'object' ) { console . warn ( "height is deprecated. Please use axis instead." ) ; var axis = options . height ; var B = Geometric3 . dualOfVector ( canonicalMeridian$1 ) ; var tilt = Geometric3 . rotorFromVectorToVector ( canonicalAxis$4 , axis , B ) ; var meridian = Geometric3 . fromVector ( canonicalMeridian$1 ) . rotate ( tilt ) ; return vec ( meridian . x , meridian . y , meridian . z ) . direction ( ) ; } else { return vec ( fallback . x , fallback . y , fallback . z ) ; } }
This function computes the reference meridian of an object.
This function computes the reference meridian of an object .