Module

Functions responsible for creating and controlling the map.

The basic map can be created through Module.initialize.

Other Classes can be created and used through Module.

The worker item added to Function initialize will be supported in the beta version engine from February 1, 2024. It uses 'XDWorldWorker.js' and 'XDWorldWorker.wasm' provided with the engine to distribute and process the load that can occur in the engine.

Module.initialize({
    container: document.querySelector("Container ID"),
    terrain: {
        dem: {
            url: "Terrain DEM data request URL",
            name: "Terrain DEM layer name",
            servername: "Request Server name",
        },
        image: {
            url: "Terrain image data request URL",
            name: "Terrain image layer name",
            servername: "Request Server name",
        },
        worker: {
            use: "Use of web worker",
            path: "Web worker file request URL",
            count: "Set the number of web workers to use",
        },
    },
    defaultKey: "Issued key",
});

Function

initialize(object) -> object

Creates a map.

Activates the web worker feature through the worker item option.

Name
Type
Description

container

HTML Element

Container area containing the map.

terrain

Map creation information.

worker

Web worker creation information.

defaultKey

string

Engine API issued Key

  • Return

    • .result : API success status (1: Success, 0: Failure)

    • .name : Operating API name

    • .return : API return information (object: normal return value, string: failure error code)

createBarGraph(id) → JSBarGraph

Creates and returns a 2D bar graph object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSBarGraph: Object creation success.

    • null: Object creation failure.

createBarGraph3D(id) → JSBarGraph3D

Creates and returns a 3D bar graph object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSBarGraph3D: Object creation success.

    • null: Object creation failure.

createBillboard(id) → JSBillboard

Creates and returns a billboard object.

Name
Type
Description

key

string

Key of the object being created.

  • Return

    • JSBillboard: Object creation success.

    • null: Object creation failure.

createGhostSymbol(id) → JSGhostSymbol

Creates and returns a ghost symbol object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSGhostSymbol: Object creation success.

    • null: Object creation failure.

createLineString(id) → JSLineString

Creates and returns a line object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSLineString: Object creation success.

    • null: Object creation failure.

createMultiPoint(id) → JSMultiPoint

Creates and returns a multipoint object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSMultiPoint: Object creation success.

    • null: Object creation failure.

createPipe(id) → JSPipe

Creates and returns a pipe object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSPipe: Object creation success.

    • null: Object creation failure.

createPoint(id) → JSPoint

Creates and returns a POI object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSPoint: Object creation success.

    • null: Object creation failure.

createPointGraph(id) → JSPointGraph

Creates and returns a 3D point graph object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSPointGraph: Object creation success.

    • null: Object creation failure.

createSurfaceGraph(id) → JSSurfaceGraph

Creates and returns a 3D net-type grid graph object.

Name
Type
Description

id

string

Created object ID name.

  • Return

    • JSSurfaceGraph: Object creation success.

    • null: Object creation failure.

getAnalysis() → JSAnalysis

Returns the JSAnalysis object that executes the analysis API.

  • Return

    • JSAnalysis: Created JSAnalysis type object. - null: Object creation failure.

getGhostSymbolMap() → JSGhostSymbolMap

Creates and returns an API object that manages ghost symbols.

  • Return

    • JSGhostSymbolMap: Object creation success.

    • null: Creation failure.

getNavigation() → JSNavigationControl

Creates and returns an API object for setting map navigation (compass).

  • Return

    • JSNavigationControl: Object creation success.

    • null: Creation failure.

getMap() → JSMap

Returns an object that calls the map functionality JSMap.

  • Return

    • JSMap: Return success.

    • null: Return failure.

getSlope() → JSSlope

Creates and returns an API object for slope and slope direction analysis.

  • Return

    • JSSlope: Object creation success.

    • null: Creation failure.

getSymbol() → JSSymbol

Creates and returns an API object for managing icons (JSIcon).

  • Return

    • JSSymbol: Object creation success.

    • null: Creation failure.

getTerrain() → JSTerrain

Returns an object that calls the terrain setting API JSTerrain

  • Return

    • JSTerrain: Return success.

    • null: Return failure.

Resize(width, height)

Function to change the size of the screen.

If there is no special setting, the viewport is changed to fit the canvas size.

When set to div, the viewport is changed to fit the div size.

Name
Type
Description

width

number

Width to change.

height

number

Height.

SetProxy(proxy)

Sets the bypass proxy URL.

Name
Type
Description

proxy

string

Proxy URL.

SetSimpleMode(type)

Sets the rendering simple mode.

When simple mode is set, objects without textures are rendered.

Name
Type
Description

type

boolean

true to activate simple mode. false to deactivate simple mode.

XDClearInputPoint() → boolean

Initializes the input point list.

  • Return

    • true: Initialization success.

    • false : Engine not initialized.

XDIsMouseOverDiv(block)

Sets whether to block the map click event.

Name
Type
Description

block

boolean

true to activate Block. false to deactivate Block.

XDRenderData()

Refreshes the screen.

Module.XDRenderData();

XDSetMouseState(mode)

Changes the input state of the mouse.

Name
Type
Description

mode

number

Type Definitions

Module.CreateTerrainOptions

Name
Type
Description

Module.CreateWorkerOptions

Name
Type
Description

use

boolean

Use of web worker.

path

string

Web worker request url.

count

number

Number of web workers to use.

Module.CreateTerrainOptions.DEM

Name
Type
Description

url

string

Terrain DEM data request url.

name

string

Terrain DEM layer name.

servername

string

Request Server name.

encoding

boolean

Whether DEM data is encrypted. true if encrypted. false if not encrypted.

Module.CreateTerrainOptions.Image

Name
Type
Description

url

string

Terrain image data request url.

name

string

Terrain image layer name.

servername

string

Request Server name.

Last updated