API Docs for: 2.7.3
Show:

ExporterHelper Class

Module: Wanaplan

A helper used by all exporters.

Item Index

Methods

applyScaling

(
  • An
)
static

Applies a scaling factor to a group of meshes or on a single mesh.

Parameters:

  • An Array | Mesh

    array of Mesh or a single Mesh.

computeImageSize

(
  • image
)
static

Computes the size of an image.

Parameters:

exportTextures

(
  • textures
  • zip
  • completeCallback
)
static

Adds the selected textures into a zip file. Textures are stored in the assetPath folder.

Parameters:

  • textures Array

    An array of textures urls.

  • zip JSZip

    An instance of a zip object.

  • completeCallback Function

    Function called when the process is done.

getAssetName

(
  • url
)
String static

Gets the relative path with extension of an asset by its url. GET paramters are removed.

Parameters:

Returns:

String:

Returns the asset's name with its extension.

getAssetPath

(
  • url
)
String static

Gets the asset path of an asset (see assetPath).

Parameters:

Returns:

String:

Returns the asset's path.

initialize

(
  • options
)

Initializes the helper with options.

Parameters:

  • options Object

    An object that contains options: precision (float), assetPath (string), scaleFactor (float).

round

(
  • value
)
Float

Gets a rounded float value determined by the precision property.

Parameters:

  • value Number

    The value to use.

Returns:

Float:

Returns a rounded value.