JSOption

API for setting map environment options.

Created with the Module.getOption API.

var math = Module.getOption();

Properties

Name
Type
Description

object_ahead

number

Setting the visibility of obstacles (terrain, structures) in front of JSPoint and HTMLObject based on the camera's field of view. 0: Basic visualization. 1: Obstacle identification.

Function

callBackAddPoint(event) → string

Registers a mouse click callback during measurement operations.

Integrates with a function that receives the current location point, midpoint between the current and previous points, length, and total length upon mouse click.

Name
Type
Description

event

function

callback function.

  • Return

    • "success" : Successfully registered the callback function for measurement operations.

    • "error map load" : Failed due to uninitialized object.

    • "error { callback } Undefined" : Failed due to undefined event variable.

    • "error { callback } null" : Failed due to null event variable.

    • "error { callback } Type Mismatch" : Failed due to event Type not being a function.

  • Sample

callBackCompletePoint(event) → string

Registers a callback for mouse measurement completion during measurement operations.

Integrates with a function that receives the measurement object key upon mouse double-click.

Name
Type
Description

event

function

The function to be executed upon measurement completion.

  • Return

    • "success" : Successfully registered the callback function for measurement completion.

    • "error map load" : Failed due to uninitialized object.

    • "error { callback } Undefined" : Failed due to undefined event variable.

    • "error { callback } null" : Failed due to null event variable.

    • "error { callback } Type Mismatch" : Failed due to event Type not being a function.

  • Sample

SetAreaMeasurePolygonDepthBuffer(type) → boolean

Sets the Depth Buffer for objects created during area measurement operations.

Without setting the DepthBuffer, z-fighting phenomena may occur when objects overlap.

Name
Type
Description

type

boolean

true to disable WebGL Depth. false to enable WebGL Depth.

SetDistanceMeasureLineDepthBuffer(type) → boolean

Sets the Depth Buffer for objects created during distance measurement operations.

Without setting the DepthBuffer, z-fighting phenomena may occur when objects overlap.

Name
Type
Description

type

boolean

true to disable WebGL Depth. false to enable WebGL Depth.

  • Return

    • true : Setting successful.

    • false : Setting failed.

      • Failure conditions

        • If the map has not been updated.

  • Sample

setSlideScreenCount(value) → boolean

Sets the screen division.

The value must be set to 1 (single screen) or 2 (split screen).

Name
Type
Description

value

number

Number of screens to set.

  • Return

    • true : Setting successful.

    • false : Setting failed.

  • Sample

setTwoSlideScreenDivideRate(value) → boolean

Sets the screen division ratio.

The value must be set between 0 and 1.

Name
Type
Description

value

number

Screen division ratio to set.

  • Return

    • true : Setting successful.

    • false : Setting failed.

  • Sample

setTwoSlideScreenLayerList(leftName, rightName) → number

Sets the screen division ratio.

For leftName, when setting multiple layers, configure as "LayerName1,LayerName2".

For rightName, when setting multiple layers, configure as "LayerName1,LayerName2".

Name
Type
Description

leftName

number

Set visible layers for the left screen.

rightName

number

Set visible layers for the right screen.

  • Return

    • result>0 : Returns the total number of visible layers for both left and right.

    • result==0 : No visible layers.

  • Sample

Last updated