📋
XDWorld_WebGL_Manual
  • 소개
    • XDWorld API
    • 시작하기
    • About EGIS
    • Release Note
      • 2.1x 버전 업데이트
      • 2.x 버전 업데이트
      • 1.6x 버전 업데이트
      • 1.5x 버전 업데이트
      • 1.4x 버전 업데이트
      • 1.3x 버전 업데이트
      • 이전 버전 업데이트
    • Tutorial
      • 카메라 설정
      • POI 생성하기
      • 폴리곤 생성하기
      • 라인 생성하기
      • 모델 추가하기
      • 레이어 설정
      • 배경 지도 설정
      • 거리 측정
      • 면적 측정
      • 높이 측정
      • 반경 측정
  • API
    • Module
    • Core
      • Collection
      • JSAABBox3D
      • JSColor
      • JSLine3D
      • JSSize2D
      • JSSize3D
      • JSVector2D
      • JSVector3D
      • JSVec2Array
      • JSVec3Array
      • JSDateTime
    • Analysis
      • JSAnalysis
      • JSAnalysisGridShadow
      • JSEarthquake
      • JSEditTerrain
      • JSFlood
      • JSGridAnal
      • JSSightAnalysis
      • JSSlope
      • JSTransparency
      • JSSolarManager
    • Camera
      • JSCamera
    • Layer
      • JSLayer
      • JSLayerList
      • JSImageryProvider
    • Map
      • JSMap
      • JSTerrain
      • JSIndexMap
    • Object
      • JSObject
      • JSAntenna
      • JSArrow
      • JSBarGraph
      • JSBarGraph3D
      • JSBillboard
      • JSColorGrid
      • JSColorGrid3D
      • JSColorPolygon
      • JSFigure
      • JSFlow
      • JSFlowPolygon
      • JSGhostSymbol
      • JSGhostSymbolMap
      • JSHTMLObject
      • JSIcon
      • JSInstanceObject
      • JSLineString
      • JSMultiCube
      • JSMultiPoint
      • JSPipe
      • JSPoint
      • JSPointGraph
      • JSPolygon
      • JSPolygonStyle
      • JSPolyLineStyle
      • JSReal3D
      • JSSurfaceGraph
      • JSSymbol
      • JSTimeSeriesObject
      • JSTraceTarget
      • JSTyphoon
      • JSVideoObject
      • JSViewFrustum
    • Option
      • JSControl
      • JSNavigationControl
      • JSOption
    • ETC
      • JSMath
      • JSProj
      • ~~JSProjection~~
      • SOPObject
      • EVENT
      • Type List
      • Tag List
Powered by GitBook
On this page
  • Properties
  • Function
  • getAngle() → number
  • getBoundary() → JSAABBox3D
  • getCenter() → JSVector3D
  • getExtent() → number
  • getFigureType() → number
  • getId() → string
  • getPosition() → JSVector3D
  • getSize() → JSVector3D
  • setAngle(angle) → boolean
  • setDepth(depth) → boolean
  • setHeight(height) → boolean
  • setWidth(width) → boolean
  • setPosition(position) → boolean
  • setSize(width, height, depth) → boolean
  • setledBoard(option) → string
  • createPlane(min, max) → boolean
  • editPlane() → boolean
  • createOverlapRTT(option) → boolean
  • clearTexture() → boolean
  • setInfo(option) → boolean
  • getInfo() → string
  • getRectInfo() → object
  • Getter / Setter
  • getDescription(), setDescription(desc) → string
  • getName(), setName(name) → string
  • getStyle(), setStyle(style) → JSPolygonStyle
  • getVisible(), setVisible(visible) → boolean

Was this helpful?

  1. API
  2. Object

JSFigure

지도 내 3D figure 객체 생성 및 설정하기 위한 API 입니다.

PreviousJSColorPolygonNextJSFlow

Last updated 6 months ago

Was this helpful?

Module.createFigure() API를 생성합니다.

let figure = Module.createFigure("ID");

Properties

Name
Type
Description

isplayer

boolean

비디오 실행 여부.

videoStreaming

boolean

비디오 스트리밍 여부.

axisX

boolean

좌우 반전.

axisY

boolean

상하 반전.

Function

getAngle() → number

객체의 Y축 중심 회전 각도(degree 단위)를 반환합니다.

  • Return

    • number: 반환 성공.

    • -999.0: 반환 실패.

var dAngle = figure.getAngle();

getBoundary() →

객체의 공간 영역 좌표(경도, 위도, 고도)를 반환합니다.

  • Return

    • null: 반환 실패.

var boundary = figure.getBoundary();
var boundary_min = boundary.min;
var boundary_max = boundary.max;

객체의 중심 좌표(경도, 위도, 고도)를 반환합니다.

  • Return

    • null: 반환 실패.

var vCenter = figure.getCenter();
var dCenterLon = vCenter.Longitude;
var dCenterLat = vCenter.Latitude;
var dCenterAlt = vCenter.Altitude;

getExtent() → number

객체의 공간 영역의 장축 거리를 반환합니다.

  • Return

    • number: 거리 반환 성공.

var bExtends = figure.getExtent();

getFigureType() → number

객체의 figure 타입을 반환합니다.

  • Return

    • number: 반환 성공.

    • -1: 반환 실패.

var figureType = figure.getFigureType();

getId() → string

객체의 고유 명칭을 반환 합니다.

  • Return

    • string: 객체 설명 문자열이 성공적으로 반환.

    • null: 객체가 null인 경우.

var strKey = object.getId();

객체의 바닥면 중심 좌표(경도, 위도, 고도)를 반환합니다.

  • Return

    • null: 반환 실패.

let position = figure.getPosition();
let longitude = position.x;
let latitude = position.y;
let altitude = position.z;

객체의 해당되는 3차원 축의 크기(meter 단위)를 반환합니다.

  • Return

    • null: 반환 실패.

let size = figure.getSize();
let width = size.x;
let height = size.y;
let depth = size.z;

setAngle(angle) → boolean

객체의 Y축 중심 회전 각도를 설정합니다.

Name
Type
Description

angle

number

회전 각도 (degree 단위).

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

    • 실패 조건

      • 입력 변수값(angle)이 0 ~ 360 범위를 벗어난 값이 입력된 경우.

figure.setAngle(50.0);

setDepth(depth) → boolean

객체의 Z축 깊이를 설정합니다.

Name
Type
Description

depth

number

깊이 값.

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

figure.setDepth(200.0);

setHeight(height) → boolean

객체의 Y축 높이를 설정합니다.

Name
Type
Description

height

number

높이(meter 단위).

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

figure.setHeight(100.0);

setWidth(width) → boolean

객체의 X축 너비를 설정합니다.

Name
Type
Description

width

number

너비(meter 단위).

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

figure.setWidth(130.0);

setPosition(position) → boolean

객체의 바닥면 중심 좌표(경도, 위도, 고도)를 설정합니다.

Name
Type
Description

position

바닥면 중심 위치(경도, 위도, 고도).

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

var vPos = new Module.JSVector3D("127.0273188", "37.4977981", "30.0");
figure.setPosition(vPos);

setSize(width, height, depth) → boolean

객체의 해당되는 3차원 축의 크기(meter 단위)를 설정합니다.

Name
Type
Description

width

number

너비(meter 단위).

height

number

높이(meter 단위).

depth

number

깊이(meter 단위).

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

figure.setSize(50.0, 100.0, 150.0);

setledBoard(option) → string

전광판 객체를 생성합니다.

Name
Type
Description

url

string

미디어 URL 경로.

streaming

boolean

비디오 스트리밍 설정.

xaxis

boolean

좌우 반전 설정.

yaxis

boolean

상하 반전 설정.

  • Return

    • success : 텍스쳐 생성 성공.

    • 실패 조건

      • null : 생성된 객체가 없을 경우.

      • url tag isn't exist : url 태그가 없을 경우.

      • streaming tag isn't exist. : streaming 태그가 없을 경우.

  • Sample

    • function createBoard 참조.

createPlane(min, max) → boolean

평면 객체를 생성합니다.

Name
Type
Description

min

입력된 영역의 좌상단 좌표.

max

입력된 영역의 우하단 좌표.

  • Return

    • true : 객체 생성 성공.

    • false : 생성된 객체가 없을 경우.

  • Sample

    • function createPlane 참조.

editPlane() → boolean

평면 객체를 편집상태로 전환합니다.

  • Return

    • true : 텍스쳐 생성 성공.

    • false : 생성된 객체가 없을 경우.

  • Sample

    • function editplane 참조.

createOverlapRTT(option) → boolean

이미지 오버랩을 생성합니다.

Name
Type
Description

option

boolean

지형 성절토 여부.

  • Return

    • true : 이미지 오버랩 생성 성공.

    • false :

      • 생성된 객체가 없을 경우.

      • 입력된 좌표가 4개가 아닐 경우

  • Sample

    • function insertOverlapRTT 참조.

clearTexture() → boolean

객체에 입력된 텍스쳐를 삭제합니다.

  • Return

    • true : 텍스쳐 삭제 성공.

    • false : 생성된 객체가 없을 경우.

  • Sample

    • function clearObject 참조.

setInfo(option) → boolean

현재 객체 정보를 입력합니다.

Name
Type
Description

position

객체 위치 좌표.

size

객체 크기.

angle

객체 회전 각도.

color

객체 색상.

imagesize

이미지 길이.

imagedata

string

이미지 데이터.

  • Return

    • true : 객체 정보 입력 성공.

    • false :

      • 생성된 객체가 없을 경우.

      • 이미지 데이터가 없을 경우.

  • Sample

    • function importData 참조.

getInfo() → string

객체 정보를 반환합니다.

  • Return

    • position : 객체 위치.

    • size : 객체 크기.

    • angle : 객체 회전 각도.

    • color : 객체 색상.

  • Sample

    • function exportData 참조.

getRectInfo() → object

객체의 좌표정보를 반환합니다.

  • Return

    • leftTop : 좌상단 좌표.

    • rightTop : 우상단 좌표.

    • leftBottom : 좌하단 좌표.

    • rightBottom : 우하단 좌표.

  • Sample

    • function exportData 참조.

Getter / Setter

getDescription(), setDescription(desc) → string

객체에 대한 설명을 설정합니다.

Name
Type
Description

desc

string

설명 문자열.

  • Return

    • string: 객체 설명 문자열이 성공적으로 반환.

    • null: 객체가 null인 경우.

var strDesc = object.getDescription();
// ... or ...
object.setDescription("First Object.");

getName(), setName(name) → string

객체 이름을 설정합니다.

Name
Type
Description

name

string

객체 이름.

  • Return

    • string: 객체 이름을 성공적을 반환

    • null: 객체가 null인 경우.

var objName = object.getName();
// ... or ...
object.setName("MyObject");
Name
Type
Description

style

객체 스타일.

  • Return

    • null: 설정 실패.

var figure = new Module.JSFigure();
var figureStyle = figure.getStyle();
// ... or ...
var figure = new Module.JSFigure();
var figureStyle = new Module.JSFigureStyle();
//...
figure.setStyle(figureStyle);

getVisible(), setVisible(visible) → boolean

객체의 가시화 유무를 설정합니다.

Name
Type
Description

visible

boolean

true: 객체 가시화. false: 객체 비가시화.

  • Return

    • true: 객체 가시화 상태.

    • false: 객체 비가시화 상태.

var objName = object.getName();
// ... or ...
object.setVisible(true);

: 반환 성공.

getCenter() →

: 반환 성공.

getPosition() →

: 반환 성공.

getSize() →

: 반환 성공.

getStyle(), setStyle(style) →

에 적용된 객체의 스타일을 설정합니다.

적용 가능한 스타일(업데이트 될 수 있음 )

(): 설정 성공.

JSAABBox3D
JSVector3D
JSVector3D
JSVector3D
JSVector3D
JSVector3D
JSVector3D
Sandbox_LED Display
Sandbox_Image_overlap
Sandbox_Image_overlap
Sandbox_Image_overlap
Sandbox_Image_overlap
Sandbox_Image_overlap
Sandbox_Image_overlap
Sandbox_Get_Figure_Coordinate
JSPolygonStyle
JSPolygonStyle
JSPolygonStyle
JSPolygonStyle
JSVector3D
JSVector3D
JSVector3D
JSVector3D
JSVector3D
JSVector3D
JSColor
JSPolygonStyle
JSAABBox3D
Size2D
JSFigure Type Constants
JSFigure Type Constants