Class: DiamondPlugin
Plugins.DiamondPlugin
Hierarchy
BaseIJewel3DKeyPlugin
<""
>↳
DiamondPlugin
Properties
PluginType
▪ Static
Readonly
PluginType: "Diamond"
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:26
DIAMOND_GLTF_EXTENSION
▪ Static
Readonly
DIAMOND_GLTF_EXTENSION: "WEBGI_materials_diamond"
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:108
offsetCache
• offsetCache: Record
<string
, IDiamondGeometryOffsets
> = {}
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:27
enabled
• enabled: boolean
= true
Overrides
BaseIJewel3DKeyPlugin.enabled
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:30
envMap
• envMap: null
| ITexture
<any
> = null
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:34
envMap2
• envMap2: null
| ITexture
<any
> = null
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:38
envMap3
• envMap3: null
| ITexture
<any
> = null
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:42
forceSceneEnvMap
• forceSceneEnvMap: boolean
= false
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:46
uiConfig
• uiConfig: UiObjectConfig
<any
, string
>
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:398
_dirty
• Protected
_dirty: boolean
= false
Inherited from
BaseIJewel3DKeyPlugin._dirty
Defined in
webgi/src/core/AViewerPlugin.ts:23
_viewer
• Protected
Optional
_viewer: ViewerApp
Inherited from
BaseIJewel3DKeyPlugin._viewer
Defined in
webgi/src/core/AViewerPlugin.ts:27
Accessors
dirty
• get
dirty(): boolean
Returns
boolean
Inherited from
BaseIJewel3DKeyPlugin.dirty
Defined in
webgi/src/core/AViewerPlugin.ts:16
• set
dirty(value
): void
Parameters
Name | Type |
---|---|
value | boolean |
Returns
void
Inherited from
BaseIJewel3DKeyPlugin.dirty
Defined in
webgi/src/core/AViewerPlugin.ts:20
viewer
• get
viewer(): undefined
| TViewer
Returns
undefined
| TViewer
Inherited from
BaseIJewel3DKeyPlugin.viewer
Defined in
webgi/src/core/AViewerPlugin.ts:29
envMapRotation
• get
envMapRotation(): number
Returns
number
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:48
• set
envMapRotation(value
): void
Parameters
Name | Type |
---|---|
value | number |
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:51
Methods
onDispose
▸ onDispose(viewer
): Promise
<void
>
Parameters
Name | Type |
---|---|
viewer | ViewerApp |
Returns
Promise
<void
>
Inherited from
BaseIJewel3DKeyPlugin.onDispose
Defined in
webgi/src/core/AViewerPlugin.ts:40
toJSON
▸ toJSON(meta?
): any
Parameters
Name | Type |
---|---|
meta? | any |
Returns
any
Inherited from
BaseIJewel3DKeyPlugin.toJSON
Defined in
webgi/src/core/AViewerPlugin.ts:49
fromJSON
▸ fromJSON(data
, meta?
): null
| DiamondPlugin
| Promise
<null
| DiamondPlugin
>
Parameters
Name | Type |
---|---|
data | any |
meta? | any |
Returns
null
| DiamondPlugin
| Promise
<null
| DiamondPlugin
>
Inherited from
BaseIJewel3DKeyPlugin.fromJSON
Defined in
webgi/src/core/AViewerPlugin.ts:56
exportState
▸ exportState(): any
Returns
any
Inherited from
BaseIJewel3DKeyPlugin.exportState
Defined in
webgi/src/core/AViewerPlugin.ts:68
importState
▸ importState(state
): Promise
<void
>
Parameters
Name | Type |
---|---|
state | any |
Returns
Promise
<void
>
Inherited from
BaseIJewel3DKeyPlugin.importState
Defined in
webgi/src/core/AViewerPlugin.ts:71
storeState
▸ storeState(prefix?
, storage?
, data?
): void
Parameters
Name | Type |
---|---|
prefix? | string |
storage? | Storage |
data? | any |
Returns
void
Inherited from
BaseIJewel3DKeyPlugin.storeState
Defined in
webgi/src/core/AViewerPlugin.ts:78
loadState
▸ loadState(prefix?
, storage?
): Promise
<void
>
Parameters
Name | Type |
---|---|
prefix? | string |
storage? | Storage |
Returns
Promise
<void
>
Inherited from
BaseIJewel3DKeyPlugin.loadState
Defined in
webgi/src/core/AViewerPlugin.ts:88
getEnvMaps
▸ getEnvMaps(): (null
| ITexture
<any
>)[] | (null
| Texture
)[]
Returns
(null
| ITexture
<any
>)[] | (null
| Texture
)[]
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:64
refreshEnvMaps
▸ refreshEnvMaps(): void
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:72
refreshUi
▸ refreshUi(): void
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:152
onAdded
▸ onAdded(v
): Promise
<void
>
Parameters
Name | Type |
---|---|
v | ViewerApp |
Returns
Promise
<void
>
Overrides
BaseIJewel3DKeyPlugin.onAdded
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:157
onRemove
▸ onRemove(v
): Promise
<void
>
Parameters
Name | Type |
---|---|
v | ViewerApp |
Returns
Promise
<void
>
Overrides
BaseIJewel3DKeyPlugin.onRemove
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:225
prepareDiamondMesh
▸ prepareDiamondMesh(mesh
, __namedParameters
): void
Parameters
Name | Type |
---|---|
mesh | Mesh <BufferGeometry <NormalBufferAttributes , Event , string >, Material <Event , string > | Material <Event , string >[]> |
__namedParameters | DiamondGeometryParameters |
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:237
makeDiamond
▸ makeDiamond(material
, geometryParams
, materialParams
): void
Creates a new diamond material, prepare all the mesh assigned to the material, and set the new material on all the meshes.
Parameters
Name | Type |
---|---|
material | undefined | IMaterial <any > |
geometryParams | DiamondGeometryParameters |
materialParams | DiamondMaterialParameters & { isDiamond? : true } |
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:282
makeDiamondMesh
▸ makeDiamondMesh(mesh
, geometryParams
, materialParams
): void
Assigns a new material to the mesh
Parameters
Name | Type |
---|---|
mesh | IModel <Mesh <BufferGeometry <NormalBufferAttributes , Event , string >, Material <Event , string > | Material <Event , string >[]>> |
geometryParams | DiamondGeometryParameters |
materialParams | DiamondMaterialParameters & { isDiamond? : true } |
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:301
disposeCacheMap
▸ disposeCacheMap(cacheKey
): void
Parameters
Name | Type |
---|---|
cacheKey | string |
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:389
disposeAllCacheMaps
▸ disposeAllCacheMaps(): void
Returns
void
Defined in
webgi/src/extras/ijewel/diamondPlugin.ts:393
setKey
▸ setKey(key
): void
Parameters
Name | Type |
---|---|
key | string |
Returns
void
Inherited from
BaseIJewel3DKeyPlugin.setKey
Defined in
webgi/src/extras/license/plugin.ts:16
unuse
▸ unuse(): void
Returns
void
Inherited from
BaseIJewel3DKeyPlugin.unuse
Defined in
webgi/src/extras/license/plugin.ts:114
_storeKey
▸ Protected
_storeKey(prefix?
): string
Parameters
Name | Type |
---|---|
prefix? | string |
Returns
string
Inherited from
BaseIJewel3DKeyPlugin._storeKey
Defined in
webgi/src/core/AViewerPlugin.ts:64
use
▸ Protected
use(): void
Returns
void
Inherited from
BaseIJewel3DKeyPlugin.use
Defined in
webgi/src/extras/license/plugin.ts:102
Constructors
constructor
• new DiamondPlugin()
Overrides
BaseIJewel3DKeyPlugin<''\>.constructor