コンテンツにスキップ

Hook

Photorealistic 3D Tiles プロバイダフックの実装

Implements

Constructors

new Hook()

new Hook(resource, attributions?): Hook

Parameters

Parameter Type Description
resource ResourceInfo API キーを含むリソース情報
attributions? readonly (string | Json)[] このデータセットの出典 (GooglePhotorealisticTiles3DProvider.Option.attributions)

Returns

Hook

Methods

init()

init(options?): Promise<null | RootInfo>

タイルプロバイダを初期化しルートタイルをリクエストする。

  • 初期化、リクエストに失敗した場合は null を返す。

Parameters

Parameter Type Description
options? RequestOption リクエストのオプション (中断信号など)

Returns

Promise<null | RootInfo>

ルートタイルの情報 (失敗した場合は null)

Implementation of

Hook.init


requestContent()

requestContent(content_uri, type, options?): Promise<null | ArrayBuffer | TileJson>

3D Tiles コンテンツをリクエストする。

  • リクエストに失敗した場合は null を返す。

Parameters

Parameter Type Description
content_uri string タイルが持つ content uri
type ContentType リクエストするファイルのタイプ
options? RequestOption リクエストのオプション (中断信号など)

Returns

Promise<null | ArrayBuffer | TileJson>

type が "JSON" なら tileset JSON、"ARRAYBUFFER" なら ArrayBuffer (失敗した場合は null)

Implementation of

Hook.requestContent