Members summary
Name | Description |
---|---|
floorContentLOD | The content object reference the floor content |
lods | Available LODs for this floor. For the moment we only load the highest LOD for each floor. |
node | The node attribute is a reference to the floor node in the scenegraph |
pickables | The pickable objects for this lod |
POIFactory | contains some default POI options values |
POIFactory | removes a public POI from the list of known pois of mapviewer. |
POIFactory | adds a public POI from the list of known pois of mapviewer. |
POIFactory | adds a public POI from the list of known pois of mapviewer. |
POIFactory | tries to create a POI using batch implementation. |
POIFactory | initiate a texture animation based on a string definition that was passed in POI's options |
POIFactory | takes the results of loading a model in a modelSlot and attaches it to a rotationObject. Can handle models in formatVersion 3.2, and transient mapeditor format 3.1, which the only client that uses it, still has old map. |
POIFactory | We need removeMaterial to remove textures, usually from text that can leak when doing lots of setPlaceName(); traverses the node and its children, and checks the reference count of the materials, and if appropriate it removes it from the _mapviewer cache, and calls dispose() on it, which deallocates the WebGL ressource associated with it. |
Methods summary
Name | Description |
---|---|
decodeDracoFile | |
dot | computes the dot product between 2 2D vectors |
getAppID | Get appID |
getURL | Get url |
isInside2D | Determines if a point {x:,y:} is inside a polygon (Array of points), ignore z attribute. |
logStat | Log statistics into database |
POIFactory | This method allow to add a POI Object in the scene. The POI is visible by default after creation. |
projectPointToPolygon | Computes the projection of input point onto a polygon. Returns the same point if inside, else a projected point on the polygon's boundary. |
PublicInterface | Simple module to host the static creation method |
setAppID | Set appID |
setDrawMode | |
setMapParameters | Set map parameters |
setSkipDequantization | |
setURL | Set url |
setVerbosity | |
squareDistanceToSegment | computes the distance (squared to avoid making square root operations) between a point and a segment and returns it along with the closest point on the segment |
updateCameraObjects | updates different objects that depend on camera position and orientation - pois_with_selector - floor.floorContentLOD.cameraUpdatableObjects - lod.cameraUpdatableObjects - floor.floorContentLOD.rampObjects - lod.rampObjects - _mapviewer.globalCameraUpdatebleLinks |
Members detail
floorContentLOD
The content object reference the floor content
lods
Available LODs for this floor. For the moment we only load the highest LOD for each floor.
node
The node attribute is a reference to the floor node in the scenegraph
pickables
The pickable objects for this lod
POIFactory
contains some default POI options values
- Since:
- 1.7.22
POIFactory
removes a public POI from the list of known pois of mapviewer.
- Since:
- 1.7.22
POIFactory
adds a public POI from the list of known pois of mapviewer.
- Since:
- 1.7.22
POIFactory
adds a public POI from the list of known pois of mapviewer.
- Since:
- 1.7.22
POIFactory
tries to create a POI using batch implementation.
- Since:
- 1.7.22
- See:
POIFactory
initiate a texture animation based on a string definition that was passed in POI's options
- Since:
- 1.8.3
POIFactory
takes the results of loading a model in a modelSlot and attaches it to a rotationObject.
Can handle models in formatVersion 3.2, and transient mapeditor format 3.1, which the only client that uses it, still has old map.
POIFactory
We need removeMaterial to remove textures, usually from text that can leak when doing lots of setPlaceName();
traverses the node and its children, and checks the reference count of the materials, and if appropriate
it removes it from the _mapviewer cache, and calls dispose() on it, which deallocates the WebGL ressource associated with it.
Methods detail
decodeDracoFile()
- Deprecated:
- Kept for backward-compatibility with previous DRACOLoader versions.
dot(v1, v2) → {number}
computes the dot product between 2 2D vectors
Parameters:
Name | Type | Description |
---|---|---|
v1 |
Object | {x, y} |
v2 |
Object | {x, y} |
- Since:
- 1.8.9
Returns:
- Type
- number
getAppID() → {string}
Get appID
Returns:
Application's ID
- Type
- string
getURL() → {string}
Get url
Returns:
the statistics URL
- Type
- string
isInside2D(point, polygon) → {boolean}
Determines if a point {x:,y:} is inside a polygon (Array of points), ignore z attribute.
Parameters:
Name | Type | Description |
---|---|---|
point |
Object | |
polygon |
Array | array of points |
- Since:
- 1.8.9
Returns:
true if point is inside polygon
- Type
- boolean
logStat(type, data)
Log statistics into database
Parameters:
Name | Type | Description |
---|---|---|
type |
string | of statistic |
data |
object |
POIFactory(addPoiVariables, _options, originalPublicPOI) → {visioweb.POI}
This method allow to add a POI Object in the scene.
The POI is visible by default after creation.
Parameters:
Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
addPoiVariables |
Object | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
_options |
Object |
Properties
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
originalPublicPOI |
PublicPOI |
- Since:
- 1.8.1 introduced zoomScaleFactor, multiline options, deprecated icon_scale.
Returns:
- Type
- visioweb.POI
Examples
// For text that zooms in and out
// which you could also control the visibility (with ramp functions)
// use 'text' and 'url' fields
// use onObjectMouseUp to get a callback on click
selected_poi = mapviewer.addPOI({
url: "test.png",
text: 'The object "'+element.vg.id+'" has been clicked',
position: {x: element.vg.position.x, y: element.vg.position.y, z: 10},
id: 'mypoi',
onObjectMouseUp: function() {alert('click');},
scale: 6
});
// For constant size text with full css/html control
// use 'selector' which overlays a <div> over the map.
<div style="display: none;">
<div id="test" style="font-weigth: bold; font-size: 24px; color: #fff; background: none;"\>
</div>
</div>
...
selected_poi = mapviewer.addPOI({
selector: '#test',
position: {x: element.vg.position.x, y: element.vg.position.y, z: 10},
});
projectPointToPolygon(point, polygon) → {Object}
Computes the projection of input point onto a polygon.
Returns the same point if inside, else a projected point on the polygon's boundary.
Parameters:
Name | Type | Description |
---|---|---|
point |
Object | {x, y} |
polygon |
Array | array of points |
- Since:
- 1.8.9
Returns:
{x, y}
- Type
- Object
PublicInterface()
Simple module to host the static creation method
setAppID(appID)
Set appID
Parameters:
Name | Type | Description |
---|---|---|
appID |
string |
setDrawMode()
- Deprecated:
- Yes
setMapParameters(p)
Set map parameters
Parameters:
Name | Type | Description |
---|---|---|
p |
object |
setSkipDequantization()
- Deprecated:
- Yes
setURL(url)
Set url
Parameters:
Name | Type | Description |
---|---|---|
url |
string |
setVerbosity()
- Deprecated:
- Yes
squareDistanceToSegment(point, segment) → {Object}
computes the distance (squared to avoid making square root operations) between a point and a segment
and returns it along with the closest point on the segment
Parameters:
Name | Type | Description |
---|---|---|
point |
Object | {x, y} |
segment |
Object | of 2D points {start: {x, y}, end: {x, y}} |
- Since:
- 1.8.9
Returns:
{squareDistance, closestPoint}
- Type
- Object
updateCameraObjects()
updates different objects that depend on camera position and orientation
- pois_with_selector
- floor.floorContentLOD.cameraUpdatableObjects
- lod.cameraUpdatableObjects
- floor.floorContentLOD.rampObjects
- lod.rampObjects
- _mapviewer.globalCameraUpdatebleLinks
Type Definitions
mouseEventCallback()
Parameters:
Type | Description |
---|---|
event | |
Place | POI |