|
@@ -2341,63 +2341,6 @@ declare module BABYLON {
|
|
}
|
|
}
|
|
|
|
|
|
declare module BABYLON {
|
|
declare module BABYLON {
|
|
- class DebugLayer {
|
|
|
|
- private _scene;
|
|
|
|
- private _camera;
|
|
|
|
- private _transformationMatrix;
|
|
|
|
- private _enabled;
|
|
|
|
- private _labelsEnabled;
|
|
|
|
- private _displayStatistics;
|
|
|
|
- private _displayTree;
|
|
|
|
- private _displayLogs;
|
|
|
|
- private _globalDiv;
|
|
|
|
- private _statsDiv;
|
|
|
|
- private _statsSubsetDiv;
|
|
|
|
- private _optionsDiv;
|
|
|
|
- private _optionsSubsetDiv;
|
|
|
|
- private _logDiv;
|
|
|
|
- private _logSubsetDiv;
|
|
|
|
- private _treeDiv;
|
|
|
|
- private _treeSubsetDiv;
|
|
|
|
- private _drawingCanvas;
|
|
|
|
- private _drawingContext;
|
|
|
|
- private _rootElement;
|
|
|
|
- _syncPositions: () => void;
|
|
|
|
- private _syncData;
|
|
|
|
- private _syncUI;
|
|
|
|
- private _onCanvasClick;
|
|
|
|
- private _clickPosition;
|
|
|
|
- private _ratio;
|
|
|
|
- private _identityMatrix;
|
|
|
|
- private _showUI;
|
|
|
|
- private _needToRefreshMeshesTree;
|
|
|
|
- shouldDisplayLabel: (node: Node) => boolean;
|
|
|
|
- shouldDisplayAxis: (mesh: Mesh) => boolean;
|
|
|
|
- axisRatio: number;
|
|
|
|
- accentColor: string;
|
|
|
|
- customStatsFunction: () => string;
|
|
|
|
- constructor(scene: Scene);
|
|
|
|
- private _refreshMeshesTreeContent();
|
|
|
|
- private _renderSingleAxis(zero, unit, unitText, label, color);
|
|
|
|
- private _renderAxis(projectedPosition, mesh, globalViewport);
|
|
|
|
- private _renderLabel(text, projectedPosition, labelOffset, onClick, getFillStyle);
|
|
|
|
- private _isClickInsideRect(x, y, width, height);
|
|
|
|
- isVisible(): boolean;
|
|
|
|
- hide(): void;
|
|
|
|
- show(showUI?: boolean, camera?: Camera, rootElement?: HTMLElement): void;
|
|
|
|
- private _clearLabels();
|
|
|
|
- private _generateheader(root, text);
|
|
|
|
- private _generateTexBox(root, title, color);
|
|
|
|
- private _generateAdvancedCheckBox(root, leftTitle, rightTitle, initialState, task, tag?);
|
|
|
|
- private _generateCheckBox(root, title, initialState, task, tag?);
|
|
|
|
- private _generateButton(root, title, task, tag?);
|
|
|
|
- private _generateRadio(root, title, name, initialState, task, tag?);
|
|
|
|
- private _generateDOMelements();
|
|
|
|
- private _displayStats();
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
class BoundingBox {
|
|
class BoundingBox {
|
|
minimum: Vector3;
|
|
minimum: Vector3;
|
|
maximum: Vector3;
|
|
maximum: Vector3;
|
|
@@ -2482,6 +2425,63 @@ declare module BABYLON {
|
|
}
|
|
}
|
|
|
|
|
|
declare module BABYLON {
|
|
declare module BABYLON {
|
|
|
|
+ class DebugLayer {
|
|
|
|
+ private _scene;
|
|
|
|
+ private _camera;
|
|
|
|
+ private _transformationMatrix;
|
|
|
|
+ private _enabled;
|
|
|
|
+ private _labelsEnabled;
|
|
|
|
+ private _displayStatistics;
|
|
|
|
+ private _displayTree;
|
|
|
|
+ private _displayLogs;
|
|
|
|
+ private _globalDiv;
|
|
|
|
+ private _statsDiv;
|
|
|
|
+ private _statsSubsetDiv;
|
|
|
|
+ private _optionsDiv;
|
|
|
|
+ private _optionsSubsetDiv;
|
|
|
|
+ private _logDiv;
|
|
|
|
+ private _logSubsetDiv;
|
|
|
|
+ private _treeDiv;
|
|
|
|
+ private _treeSubsetDiv;
|
|
|
|
+ private _drawingCanvas;
|
|
|
|
+ private _drawingContext;
|
|
|
|
+ private _rootElement;
|
|
|
|
+ _syncPositions: () => void;
|
|
|
|
+ private _syncData;
|
|
|
|
+ private _syncUI;
|
|
|
|
+ private _onCanvasClick;
|
|
|
|
+ private _clickPosition;
|
|
|
|
+ private _ratio;
|
|
|
|
+ private _identityMatrix;
|
|
|
|
+ private _showUI;
|
|
|
|
+ private _needToRefreshMeshesTree;
|
|
|
|
+ shouldDisplayLabel: (node: Node) => boolean;
|
|
|
|
+ shouldDisplayAxis: (mesh: Mesh) => boolean;
|
|
|
|
+ axisRatio: number;
|
|
|
|
+ accentColor: string;
|
|
|
|
+ customStatsFunction: () => string;
|
|
|
|
+ constructor(scene: Scene);
|
|
|
|
+ private _refreshMeshesTreeContent();
|
|
|
|
+ private _renderSingleAxis(zero, unit, unitText, label, color);
|
|
|
|
+ private _renderAxis(projectedPosition, mesh, globalViewport);
|
|
|
|
+ private _renderLabel(text, projectedPosition, labelOffset, onClick, getFillStyle);
|
|
|
|
+ private _isClickInsideRect(x, y, width, height);
|
|
|
|
+ isVisible(): boolean;
|
|
|
|
+ hide(): void;
|
|
|
|
+ show(showUI?: boolean, camera?: Camera, rootElement?: HTMLElement): void;
|
|
|
|
+ private _clearLabels();
|
|
|
|
+ private _generateheader(root, text);
|
|
|
|
+ private _generateTexBox(root, title, color);
|
|
|
|
+ private _generateAdvancedCheckBox(root, leftTitle, rightTitle, initialState, task, tag?);
|
|
|
|
+ private _generateCheckBox(root, title, initialState, task, tag?);
|
|
|
|
+ private _generateButton(root, title, task, tag?);
|
|
|
|
+ private _generateRadio(root, title, name, initialState, task, tag?);
|
|
|
|
+ private _generateDOMelements();
|
|
|
|
+ private _displayStats();
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
class LensFlare {
|
|
class LensFlare {
|
|
size: number;
|
|
size: number;
|
|
position: number;
|
|
position: number;
|
|
@@ -2684,6 +2684,281 @@ declare module BABYLON {
|
|
}
|
|
}
|
|
|
|
|
|
declare module BABYLON {
|
|
declare module BABYLON {
|
|
|
|
+ class EffectFallbacks {
|
|
|
|
+ private _defines;
|
|
|
|
+ private _currentRank;
|
|
|
|
+ private _maxRank;
|
|
|
|
+ private _mesh;
|
|
|
|
+ private _meshRank;
|
|
|
|
+ addFallback(rank: number, define: string): void;
|
|
|
|
+ addCPUSkinningFallback(rank: number, mesh: BABYLON.AbstractMesh): void;
|
|
|
|
+ isMoreFallbacks: boolean;
|
|
|
|
+ reduce(currentDefines: string): string;
|
|
|
|
+ }
|
|
|
|
+ class Effect {
|
|
|
|
+ name: any;
|
|
|
|
+ defines: string;
|
|
|
|
+ onCompiled: (effect: Effect) => void;
|
|
|
|
+ onError: (effect: Effect, errors: string) => void;
|
|
|
|
+ onBind: (effect: Effect) => void;
|
|
|
|
+ private _engine;
|
|
|
|
+ private _uniformsNames;
|
|
|
|
+ private _samplers;
|
|
|
|
+ private _isReady;
|
|
|
|
+ private _compilationError;
|
|
|
|
+ private _attributesNames;
|
|
|
|
+ private _attributes;
|
|
|
|
+ private _uniforms;
|
|
|
|
+ _key: string;
|
|
|
|
+ private _program;
|
|
|
|
+ private _valueCache;
|
|
|
|
+ constructor(baseName: any, attributesNames: string[], uniformsNames: string[], samplers: string[], engine: any, defines?: string, fallbacks?: EffectFallbacks, onCompiled?: (effect: Effect) => void, onError?: (effect: Effect, errors: string) => void);
|
|
|
|
+ isReady(): boolean;
|
|
|
|
+ getProgram(): WebGLProgram;
|
|
|
|
+ getAttributesNames(): string[];
|
|
|
|
+ getAttributeLocation(index: number): number;
|
|
|
|
+ getAttributeLocationByName(name: string): number;
|
|
|
|
+ getAttributesCount(): number;
|
|
|
|
+ getUniformIndex(uniformName: string): number;
|
|
|
|
+ getUniform(uniformName: string): WebGLUniformLocation;
|
|
|
|
+ getSamplers(): string[];
|
|
|
|
+ getCompilationError(): string;
|
|
|
|
+ _loadVertexShader(vertex: any, callback: (data: any) => void): void;
|
|
|
|
+ _loadFragmentShader(fragment: any, callback: (data: any) => void): void;
|
|
|
|
+ private _dumpShadersName();
|
|
|
|
+ private _prepareEffect(vertexSourceCode, fragmentSourceCode, attributesNames, defines, fallbacks?);
|
|
|
|
+ isSupported: boolean;
|
|
|
|
+ _bindTexture(channel: string, texture: WebGLTexture): void;
|
|
|
|
+ setTexture(channel: string, texture: BaseTexture): void;
|
|
|
|
+ setTextureFromPostProcess(channel: string, postProcess: PostProcess): void;
|
|
|
|
+ _cacheMatrix(uniformName: any, matrix: any): void;
|
|
|
|
+ _cacheFloat2(uniformName: string, x: number, y: number): void;
|
|
|
|
+ _cacheFloat3(uniformName: string, x: number, y: number, z: number): void;
|
|
|
|
+ _cacheFloat4(uniformName: string, x: number, y: number, z: number, w: number): void;
|
|
|
|
+ setArray(uniformName: string, array: number[]): Effect;
|
|
|
|
+ setArray2(uniformName: string, array: number[]): Effect;
|
|
|
|
+ setArray3(uniformName: string, array: number[]): Effect;
|
|
|
|
+ setArray4(uniformName: string, array: number[]): Effect;
|
|
|
|
+ setMatrices(uniformName: string, matrices: Float32Array): Effect;
|
|
|
|
+ setMatrix(uniformName: string, matrix: Matrix): Effect;
|
|
|
|
+ setMatrix3x3(uniformName: string, matrix: Float32Array): Effect;
|
|
|
|
+ setMatrix2x2(uniformname: string, matrix: Float32Array): Effect;
|
|
|
|
+ setFloat(uniformName: string, value: number): Effect;
|
|
|
|
+ setBool(uniformName: string, bool: boolean): Effect;
|
|
|
|
+ setVector2(uniformName: string, vector2: Vector2): Effect;
|
|
|
|
+ setFloat2(uniformName: string, x: number, y: number): Effect;
|
|
|
|
+ setVector3(uniformName: string, vector3: Vector3): Effect;
|
|
|
|
+ setFloat3(uniformName: string, x: number, y: number, z: number): Effect;
|
|
|
|
+ setVector4(uniformName: string, vector4: Vector4): Effect;
|
|
|
|
+ setFloat4(uniformName: string, x: number, y: number, z: number, w: number): Effect;
|
|
|
|
+ setColor3(uniformName: string, color3: Color3): Effect;
|
|
|
|
+ setColor4(uniformName: string, color3: Color3, alpha: number): Effect;
|
|
|
|
+ static ShadersStore: {};
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
|
|
+ class MaterialDefines {
|
|
|
|
+ _keys: string[];
|
|
|
|
+ isEqual(other: MaterialDefines): boolean;
|
|
|
|
+ cloneTo(other: MaterialDefines): void;
|
|
|
|
+ reset(): void;
|
|
|
|
+ toString(): string;
|
|
|
|
+ }
|
|
|
|
+ class Material {
|
|
|
|
+ name: string;
|
|
|
|
+ private static _TriangleFillMode;
|
|
|
|
+ private static _WireFrameFillMode;
|
|
|
|
+ private static _PointFillMode;
|
|
|
|
+ static TriangleFillMode: number;
|
|
|
|
+ static WireFrameFillMode: number;
|
|
|
|
+ static PointFillMode: number;
|
|
|
|
+ private static _ClockWiseSideOrientation;
|
|
|
|
+ private static _CounterClockWiseSideOrientation;
|
|
|
|
+ static ClockWiseSideOrientation: number;
|
|
|
|
+ static CounterClockWiseSideOrientation: number;
|
|
|
|
+ id: string;
|
|
|
|
+ checkReadyOnEveryCall: boolean;
|
|
|
|
+ checkReadyOnlyOnce: boolean;
|
|
|
|
+ state: string;
|
|
|
|
+ alpha: number;
|
|
|
|
+ backFaceCulling: boolean;
|
|
|
|
+ sideOrientation: number;
|
|
|
|
+ onCompiled: (effect: Effect) => void;
|
|
|
|
+ onError: (effect: Effect, errors: string) => void;
|
|
|
|
+ onDispose: () => void;
|
|
|
|
+ onBind: (material: Material, mesh: Mesh) => void;
|
|
|
|
+ getRenderTargetTextures: () => SmartArray<RenderTargetTexture>;
|
|
|
|
+ alphaMode: number;
|
|
|
|
+ disableDepthWrite: boolean;
|
|
|
|
+ fogEnabled: boolean;
|
|
|
|
+ _effect: Effect;
|
|
|
|
+ _wasPreviouslyReady: boolean;
|
|
|
|
+ private _scene;
|
|
|
|
+ private _fillMode;
|
|
|
|
+ private _cachedDepthWriteState;
|
|
|
|
+ pointSize: number;
|
|
|
|
+ zOffset: number;
|
|
|
|
+ wireframe: boolean;
|
|
|
|
+ pointsCloud: boolean;
|
|
|
|
+ fillMode: number;
|
|
|
|
+ constructor(name: string, scene: Scene, doNotAdd?: boolean);
|
|
|
|
+ isFrozen: boolean;
|
|
|
|
+ freeze(): void;
|
|
|
|
+ unfreeze(): void;
|
|
|
|
+ isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
+ getEffect(): Effect;
|
|
|
|
+ getScene(): Scene;
|
|
|
|
+ needAlphaBlending(): boolean;
|
|
|
|
+ needAlphaTesting(): boolean;
|
|
|
|
+ getAlphaTestTexture(): BaseTexture;
|
|
|
|
+ trackCreation(onCompiled: (effect: Effect) => void, onError: (effect: Effect, errors: string) => void): void;
|
|
|
|
+ markDirty(): void;
|
|
|
|
+ _preBind(): void;
|
|
|
|
+ bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
+ bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
+ unbind(): void;
|
|
|
|
+ clone(name: string): Material;
|
|
|
|
+ getBindedMeshes(): AbstractMesh[];
|
|
|
|
+ dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
+ copyTo(other: Material): void;
|
|
|
|
+ serialize(): any;
|
|
|
|
+ static ParseMultiMaterial(parsedMultiMaterial: any, scene: Scene): MultiMaterial;
|
|
|
|
+ static Parse(parsedMaterial: any, scene: Scene, rootUrl: string): any;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
|
|
+ class MultiMaterial extends Material {
|
|
|
|
+ subMaterials: Material[];
|
|
|
|
+ constructor(name: string, scene: Scene);
|
|
|
|
+ getSubMaterial(index: any): Material;
|
|
|
|
+ isReady(mesh?: AbstractMesh): boolean;
|
|
|
|
+ clone(name: string, cloneChildren?: boolean): MultiMaterial;
|
|
|
|
+ serialize(): any;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
|
|
+ class ShaderMaterial extends Material {
|
|
|
|
+ private _shaderPath;
|
|
|
|
+ private _options;
|
|
|
|
+ private _textures;
|
|
|
|
+ private _floats;
|
|
|
|
+ private _floatsArrays;
|
|
|
|
+ private _colors3;
|
|
|
|
+ private _colors4;
|
|
|
|
+ private _vectors2;
|
|
|
|
+ private _vectors3;
|
|
|
|
+ private _vectors4;
|
|
|
|
+ private _matrices;
|
|
|
|
+ private _matrices3x3;
|
|
|
|
+ private _matrices2x2;
|
|
|
|
+ private _cachedWorldViewMatrix;
|
|
|
|
+ private _renderId;
|
|
|
|
+ constructor(name: string, scene: Scene, shaderPath: any, options: any);
|
|
|
|
+ needAlphaBlending(): boolean;
|
|
|
|
+ needAlphaTesting(): boolean;
|
|
|
|
+ private _checkUniform(uniformName);
|
|
|
|
+ setTexture(name: string, texture: Texture): ShaderMaterial;
|
|
|
|
+ setFloat(name: string, value: number): ShaderMaterial;
|
|
|
|
+ setFloats(name: string, value: number[]): ShaderMaterial;
|
|
|
|
+ setColor3(name: string, value: Color3): ShaderMaterial;
|
|
|
|
+ setColor4(name: string, value: Color4): ShaderMaterial;
|
|
|
|
+ setVector2(name: string, value: Vector2): ShaderMaterial;
|
|
|
|
+ setVector3(name: string, value: Vector3): ShaderMaterial;
|
|
|
|
+ setVector4(name: string, value: Vector4): ShaderMaterial;
|
|
|
|
+ setMatrix(name: string, value: Matrix): ShaderMaterial;
|
|
|
|
+ setMatrix3x3(name: string, value: Float32Array): ShaderMaterial;
|
|
|
|
+ setMatrix2x2(name: string, value: Float32Array): ShaderMaterial;
|
|
|
|
+ isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
+ bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
+ bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
+ clone(name: string): ShaderMaterial;
|
|
|
|
+ dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
+ serialize(): any;
|
|
|
|
+ static Parse(source: any, scene: Scene, rootUrl: string): ShaderMaterial;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
|
|
+ class FresnelParameters {
|
|
|
|
+ isEnabled: boolean;
|
|
|
|
+ leftColor: Color3;
|
|
|
|
+ rightColor: Color3;
|
|
|
|
+ bias: number;
|
|
|
|
+ power: number;
|
|
|
|
+ clone(): FresnelParameters;
|
|
|
|
+ serialize(): any;
|
|
|
|
+ static Parse(parsedFresnelParameters: any): FresnelParameters;
|
|
|
|
+ }
|
|
|
|
+ class StandardMaterial extends Material {
|
|
|
|
+ diffuseTexture: BaseTexture;
|
|
|
|
+ ambientTexture: BaseTexture;
|
|
|
|
+ opacityTexture: BaseTexture;
|
|
|
|
+ reflectionTexture: BaseTexture;
|
|
|
|
+ emissiveTexture: BaseTexture;
|
|
|
|
+ specularTexture: BaseTexture;
|
|
|
|
+ bumpTexture: BaseTexture;
|
|
|
|
+ lightmapTexture: BaseTexture;
|
|
|
|
+ ambientColor: Color3;
|
|
|
|
+ diffuseColor: Color3;
|
|
|
|
+ specularColor: Color3;
|
|
|
|
+ specularPower: number;
|
|
|
|
+ emissiveColor: Color3;
|
|
|
|
+ useAlphaFromDiffuseTexture: boolean;
|
|
|
|
+ useEmissiveAsIllumination: boolean;
|
|
|
|
+ linkEmissiveWithDiffuse: boolean;
|
|
|
|
+ useReflectionFresnelFromSpecular: boolean;
|
|
|
|
+ useSpecularOverAlpha: boolean;
|
|
|
|
+ disableLighting: boolean;
|
|
|
|
+ roughness: number;
|
|
|
|
+ useLightmapAsShadowmap: boolean;
|
|
|
|
+ diffuseFresnelParameters: FresnelParameters;
|
|
|
|
+ opacityFresnelParameters: FresnelParameters;
|
|
|
|
+ reflectionFresnelParameters: FresnelParameters;
|
|
|
|
+ emissiveFresnelParameters: FresnelParameters;
|
|
|
|
+ useGlossinessFromSpecularMapAlpha: boolean;
|
|
|
|
+ private _renderTargets;
|
|
|
|
+ private _worldViewProjectionMatrix;
|
|
|
|
+ private _globalAmbientColor;
|
|
|
|
+ private _renderId;
|
|
|
|
+ private _defines;
|
|
|
|
+ private _cachedDefines;
|
|
|
|
+ private _useLogarithmicDepth;
|
|
|
|
+ constructor(name: string, scene: Scene);
|
|
|
|
+ useLogarithmicDepth: boolean;
|
|
|
|
+ needAlphaBlending(): boolean;
|
|
|
|
+ needAlphaTesting(): boolean;
|
|
|
|
+ private _shouldUseAlphaFromDiffuseTexture();
|
|
|
|
+ getAlphaTestTexture(): BaseTexture;
|
|
|
|
+ private _checkCache(scene, mesh?, useInstances?);
|
|
|
|
+ static PrepareDefinesForLights(scene: Scene, mesh: AbstractMesh, defines: MaterialDefines): boolean;
|
|
|
|
+ private static _scaledDiffuse;
|
|
|
|
+ private static _scaledSpecular;
|
|
|
|
+ static BindLights(scene: Scene, mesh: AbstractMesh, effect: Effect, defines: MaterialDefines): void;
|
|
|
|
+ isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
+ unbind(): void;
|
|
|
|
+ bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
+ bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
+ getAnimatables(): IAnimatable[];
|
|
|
|
+ dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
+ clone(name: string): StandardMaterial;
|
|
|
|
+ serialize(): any;
|
|
|
|
+ static DiffuseTextureEnabled: boolean;
|
|
|
|
+ static AmbientTextureEnabled: boolean;
|
|
|
|
+ static OpacityTextureEnabled: boolean;
|
|
|
|
+ static ReflectionTextureEnabled: boolean;
|
|
|
|
+ static EmissiveTextureEnabled: boolean;
|
|
|
|
+ static SpecularTextureEnabled: boolean;
|
|
|
|
+ static BumpTextureEnabled: boolean;
|
|
|
|
+ static FresnelEnabled: boolean;
|
|
|
|
+ static LightmapEnabled: boolean;
|
|
|
|
+ static Parse(source: any, scene: Scene, rootUrl: string): StandardMaterial;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
class SIMDVector3 {
|
|
class SIMDVector3 {
|
|
static TransformCoordinatesToRefSIMD(vector: Vector3, transformation: Matrix, result: Vector3): void;
|
|
static TransformCoordinatesToRefSIMD(vector: Vector3, transformation: Matrix, result: Vector3): void;
|
|
static TransformCoordinatesFromFloatsToRefSIMD(x: number, y: number, z: number, transformation: Matrix, result: Vector3): void;
|
|
static TransformCoordinatesFromFloatsToRefSIMD(x: number, y: number, z: number, transformation: Matrix, result: Vector3): void;
|
|
@@ -3129,373 +3404,98 @@ declare module BABYLON {
|
|
startPoint: Vector2;
|
|
startPoint: Vector2;
|
|
midPoint: Vector2;
|
|
midPoint: Vector2;
|
|
endPoint: Vector2;
|
|
endPoint: Vector2;
|
|
- centerPoint: Vector2;
|
|
|
|
- radius: number;
|
|
|
|
- angle: Angle;
|
|
|
|
- startAngle: Angle;
|
|
|
|
- orientation: Orientation;
|
|
|
|
- constructor(startPoint: Vector2, midPoint: Vector2, endPoint: Vector2);
|
|
|
|
- }
|
|
|
|
- class PathCursor {
|
|
|
|
- private path;
|
|
|
|
- private _onchange;
|
|
|
|
- value: number;
|
|
|
|
- animations: Animation[];
|
|
|
|
- constructor(path: Path2);
|
|
|
|
- getPoint(): Vector3;
|
|
|
|
- moveAhead(step?: number): PathCursor;
|
|
|
|
- moveBack(step?: number): PathCursor;
|
|
|
|
- move(step: number): PathCursor;
|
|
|
|
- private ensureLimits();
|
|
|
|
- private markAsDirty(propertyName);
|
|
|
|
- private raiseOnChange();
|
|
|
|
- onchange(f: (cursor: PathCursor) => void): PathCursor;
|
|
|
|
- }
|
|
|
|
- class Path2 {
|
|
|
|
- private _points;
|
|
|
|
- private _length;
|
|
|
|
- closed: boolean;
|
|
|
|
- constructor(x: number, y: number);
|
|
|
|
- addLineTo(x: number, y: number): Path2;
|
|
|
|
- addArcTo(midX: number, midY: number, endX: number, endY: number, numberOfSegments?: number): Path2;
|
|
|
|
- close(): Path2;
|
|
|
|
- length(): number;
|
|
|
|
- getPoints(): Vector2[];
|
|
|
|
- getPointAtLengthPosition(normalizedLengthPosition: number): Vector2;
|
|
|
|
- static StartingAt(x: number, y: number): Path2;
|
|
|
|
- }
|
|
|
|
- class Path3D {
|
|
|
|
- path: Vector3[];
|
|
|
|
- private _curve;
|
|
|
|
- private _distances;
|
|
|
|
- private _tangents;
|
|
|
|
- private _normals;
|
|
|
|
- private _binormals;
|
|
|
|
- private _raw;
|
|
|
|
- /**
|
|
|
|
- * new Path3D(path, normal, raw)
|
|
|
|
- * path : an array of Vector3, the curve axis of the Path3D
|
|
|
|
- * normal (optional) : Vector3, the first wanted normal to the curve. Ex (0, 1, 0) for a vertical normal.
|
|
|
|
- * raw (optional, default false) : boolean, if true the returned Path3D isn't normalized. Useful to depict path acceleration or speed.
|
|
|
|
- */
|
|
|
|
- constructor(path: Vector3[], firstNormal?: Vector3, raw?: boolean);
|
|
|
|
- getCurve(): Vector3[];
|
|
|
|
- getTangents(): Vector3[];
|
|
|
|
- getNormals(): Vector3[];
|
|
|
|
- getBinormals(): Vector3[];
|
|
|
|
- getDistances(): number[];
|
|
|
|
- update(path: Vector3[], firstNormal?: Vector3): Path3D;
|
|
|
|
- private _compute(firstNormal);
|
|
|
|
- private _getFirstNonNullVector(index);
|
|
|
|
- private _getLastNonNullVector(index);
|
|
|
|
- private _normalVector(v0, vt, va);
|
|
|
|
- }
|
|
|
|
- class Curve3 {
|
|
|
|
- private _points;
|
|
|
|
- private _length;
|
|
|
|
- static CreateQuadraticBezier(v0: Vector3, v1: Vector3, v2: Vector3, nbPoints: number): Curve3;
|
|
|
|
- static CreateCubicBezier(v0: Vector3, v1: Vector3, v2: Vector3, v3: Vector3, nbPoints: number): Curve3;
|
|
|
|
- static CreateHermiteSpline(p1: Vector3, t1: Vector3, p2: Vector3, t2: Vector3, nbPoints: number): Curve3;
|
|
|
|
- constructor(points: Vector3[]);
|
|
|
|
- getPoints(): Vector3[];
|
|
|
|
- length(): number;
|
|
|
|
- continue(curve: Curve3): Curve3;
|
|
|
|
- private _computeLength(path);
|
|
|
|
- }
|
|
|
|
- class PositionNormalVertex {
|
|
|
|
- position: Vector3;
|
|
|
|
- normal: Vector3;
|
|
|
|
- constructor(position?: Vector3, normal?: Vector3);
|
|
|
|
- clone(): PositionNormalVertex;
|
|
|
|
- }
|
|
|
|
- class PositionNormalTextureVertex {
|
|
|
|
- position: Vector3;
|
|
|
|
- normal: Vector3;
|
|
|
|
- uv: Vector2;
|
|
|
|
- constructor(position?: Vector3, normal?: Vector3, uv?: Vector2);
|
|
|
|
- clone(): PositionNormalTextureVertex;
|
|
|
|
- }
|
|
|
|
- class Tmp {
|
|
|
|
- static Vector2: Vector2[];
|
|
|
|
- static Vector3: Vector3[];
|
|
|
|
- static Vector4: Vector4[];
|
|
|
|
- static Quaternion: Quaternion[];
|
|
|
|
- static Matrix: Matrix[];
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
- class EffectFallbacks {
|
|
|
|
- private _defines;
|
|
|
|
- private _currentRank;
|
|
|
|
- private _maxRank;
|
|
|
|
- private _mesh;
|
|
|
|
- private _meshRank;
|
|
|
|
- addFallback(rank: number, define: string): void;
|
|
|
|
- addCPUSkinningFallback(rank: number, mesh: BABYLON.AbstractMesh): void;
|
|
|
|
- isMoreFallbacks: boolean;
|
|
|
|
- reduce(currentDefines: string): string;
|
|
|
|
- }
|
|
|
|
- class Effect {
|
|
|
|
- name: any;
|
|
|
|
- defines: string;
|
|
|
|
- onCompiled: (effect: Effect) => void;
|
|
|
|
- onError: (effect: Effect, errors: string) => void;
|
|
|
|
- onBind: (effect: Effect) => void;
|
|
|
|
- private _engine;
|
|
|
|
- private _uniformsNames;
|
|
|
|
- private _samplers;
|
|
|
|
- private _isReady;
|
|
|
|
- private _compilationError;
|
|
|
|
- private _attributesNames;
|
|
|
|
- private _attributes;
|
|
|
|
- private _uniforms;
|
|
|
|
- _key: string;
|
|
|
|
- private _program;
|
|
|
|
- private _valueCache;
|
|
|
|
- constructor(baseName: any, attributesNames: string[], uniformsNames: string[], samplers: string[], engine: any, defines?: string, fallbacks?: EffectFallbacks, onCompiled?: (effect: Effect) => void, onError?: (effect: Effect, errors: string) => void);
|
|
|
|
- isReady(): boolean;
|
|
|
|
- getProgram(): WebGLProgram;
|
|
|
|
- getAttributesNames(): string[];
|
|
|
|
- getAttributeLocation(index: number): number;
|
|
|
|
- getAttributeLocationByName(name: string): number;
|
|
|
|
- getAttributesCount(): number;
|
|
|
|
- getUniformIndex(uniformName: string): number;
|
|
|
|
- getUniform(uniformName: string): WebGLUniformLocation;
|
|
|
|
- getSamplers(): string[];
|
|
|
|
- getCompilationError(): string;
|
|
|
|
- _loadVertexShader(vertex: any, callback: (data: any) => void): void;
|
|
|
|
- _loadFragmentShader(fragment: any, callback: (data: any) => void): void;
|
|
|
|
- private _dumpShadersName();
|
|
|
|
- private _prepareEffect(vertexSourceCode, fragmentSourceCode, attributesNames, defines, fallbacks?);
|
|
|
|
- isSupported: boolean;
|
|
|
|
- _bindTexture(channel: string, texture: WebGLTexture): void;
|
|
|
|
- setTexture(channel: string, texture: BaseTexture): void;
|
|
|
|
- setTextureFromPostProcess(channel: string, postProcess: PostProcess): void;
|
|
|
|
- _cacheMatrix(uniformName: any, matrix: any): void;
|
|
|
|
- _cacheFloat2(uniformName: string, x: number, y: number): void;
|
|
|
|
- _cacheFloat3(uniformName: string, x: number, y: number, z: number): void;
|
|
|
|
- _cacheFloat4(uniformName: string, x: number, y: number, z: number, w: number): void;
|
|
|
|
- setArray(uniformName: string, array: number[]): Effect;
|
|
|
|
- setArray2(uniformName: string, array: number[]): Effect;
|
|
|
|
- setArray3(uniformName: string, array: number[]): Effect;
|
|
|
|
- setArray4(uniformName: string, array: number[]): Effect;
|
|
|
|
- setMatrices(uniformName: string, matrices: Float32Array): Effect;
|
|
|
|
- setMatrix(uniformName: string, matrix: Matrix): Effect;
|
|
|
|
- setMatrix3x3(uniformName: string, matrix: Float32Array): Effect;
|
|
|
|
- setMatrix2x2(uniformname: string, matrix: Float32Array): Effect;
|
|
|
|
- setFloat(uniformName: string, value: number): Effect;
|
|
|
|
- setBool(uniformName: string, bool: boolean): Effect;
|
|
|
|
- setVector2(uniformName: string, vector2: Vector2): Effect;
|
|
|
|
- setFloat2(uniformName: string, x: number, y: number): Effect;
|
|
|
|
- setVector3(uniformName: string, vector3: Vector3): Effect;
|
|
|
|
- setFloat3(uniformName: string, x: number, y: number, z: number): Effect;
|
|
|
|
- setVector4(uniformName: string, vector4: Vector4): Effect;
|
|
|
|
- setFloat4(uniformName: string, x: number, y: number, z: number, w: number): Effect;
|
|
|
|
- setColor3(uniformName: string, color3: Color3): Effect;
|
|
|
|
- setColor4(uniformName: string, color3: Color3, alpha: number): Effect;
|
|
|
|
- static ShadersStore: {};
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
- class MaterialDefines {
|
|
|
|
- _keys: string[];
|
|
|
|
- isEqual(other: MaterialDefines): boolean;
|
|
|
|
- cloneTo(other: MaterialDefines): void;
|
|
|
|
- reset(): void;
|
|
|
|
- toString(): string;
|
|
|
|
- }
|
|
|
|
- class Material {
|
|
|
|
- name: string;
|
|
|
|
- private static _TriangleFillMode;
|
|
|
|
- private static _WireFrameFillMode;
|
|
|
|
- private static _PointFillMode;
|
|
|
|
- static TriangleFillMode: number;
|
|
|
|
- static WireFrameFillMode: number;
|
|
|
|
- static PointFillMode: number;
|
|
|
|
- private static _ClockWiseSideOrientation;
|
|
|
|
- private static _CounterClockWiseSideOrientation;
|
|
|
|
- static ClockWiseSideOrientation: number;
|
|
|
|
- static CounterClockWiseSideOrientation: number;
|
|
|
|
- id: string;
|
|
|
|
- checkReadyOnEveryCall: boolean;
|
|
|
|
- checkReadyOnlyOnce: boolean;
|
|
|
|
- state: string;
|
|
|
|
- alpha: number;
|
|
|
|
- backFaceCulling: boolean;
|
|
|
|
- sideOrientation: number;
|
|
|
|
- onCompiled: (effect: Effect) => void;
|
|
|
|
- onError: (effect: Effect, errors: string) => void;
|
|
|
|
- onDispose: () => void;
|
|
|
|
- onBind: (material: Material, mesh: Mesh) => void;
|
|
|
|
- getRenderTargetTextures: () => SmartArray<RenderTargetTexture>;
|
|
|
|
- alphaMode: number;
|
|
|
|
- disableDepthWrite: boolean;
|
|
|
|
- fogEnabled: boolean;
|
|
|
|
- _effect: Effect;
|
|
|
|
- _wasPreviouslyReady: boolean;
|
|
|
|
- private _scene;
|
|
|
|
- private _fillMode;
|
|
|
|
- private _cachedDepthWriteState;
|
|
|
|
- pointSize: number;
|
|
|
|
- zOffset: number;
|
|
|
|
- wireframe: boolean;
|
|
|
|
- pointsCloud: boolean;
|
|
|
|
- fillMode: number;
|
|
|
|
- constructor(name: string, scene: Scene, doNotAdd?: boolean);
|
|
|
|
- isFrozen: boolean;
|
|
|
|
- freeze(): void;
|
|
|
|
- unfreeze(): void;
|
|
|
|
- isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
- getEffect(): Effect;
|
|
|
|
- getScene(): Scene;
|
|
|
|
- needAlphaBlending(): boolean;
|
|
|
|
- needAlphaTesting(): boolean;
|
|
|
|
- getAlphaTestTexture(): BaseTexture;
|
|
|
|
- trackCreation(onCompiled: (effect: Effect) => void, onError: (effect: Effect, errors: string) => void): void;
|
|
|
|
- markDirty(): void;
|
|
|
|
- _preBind(): void;
|
|
|
|
- bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
- bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
- unbind(): void;
|
|
|
|
- clone(name: string): Material;
|
|
|
|
- getBindedMeshes(): AbstractMesh[];
|
|
|
|
- dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
- copyTo(other: Material): void;
|
|
|
|
- serialize(): any;
|
|
|
|
- static ParseMultiMaterial(parsedMultiMaterial: any, scene: Scene): MultiMaterial;
|
|
|
|
- static Parse(parsedMaterial: any, scene: Scene, rootUrl: string): any;
|
|
|
|
|
|
+ centerPoint: Vector2;
|
|
|
|
+ radius: number;
|
|
|
|
+ angle: Angle;
|
|
|
|
+ startAngle: Angle;
|
|
|
|
+ orientation: Orientation;
|
|
|
|
+ constructor(startPoint: Vector2, midPoint: Vector2, endPoint: Vector2);
|
|
}
|
|
}
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
- class MultiMaterial extends Material {
|
|
|
|
- subMaterials: Material[];
|
|
|
|
- constructor(name: string, scene: Scene);
|
|
|
|
- getSubMaterial(index: any): Material;
|
|
|
|
- isReady(mesh?: AbstractMesh): boolean;
|
|
|
|
- clone(name: string, cloneChildren?: boolean): MultiMaterial;
|
|
|
|
- serialize(): any;
|
|
|
|
|
|
+ class PathCursor {
|
|
|
|
+ private path;
|
|
|
|
+ private _onchange;
|
|
|
|
+ value: number;
|
|
|
|
+ animations: Animation[];
|
|
|
|
+ constructor(path: Path2);
|
|
|
|
+ getPoint(): Vector3;
|
|
|
|
+ moveAhead(step?: number): PathCursor;
|
|
|
|
+ moveBack(step?: number): PathCursor;
|
|
|
|
+ move(step: number): PathCursor;
|
|
|
|
+ private ensureLimits();
|
|
|
|
+ private markAsDirty(propertyName);
|
|
|
|
+ private raiseOnChange();
|
|
|
|
+ onchange(f: (cursor: PathCursor) => void): PathCursor;
|
|
}
|
|
}
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
- class ShaderMaterial extends Material {
|
|
|
|
- private _shaderPath;
|
|
|
|
- private _options;
|
|
|
|
- private _textures;
|
|
|
|
- private _floats;
|
|
|
|
- private _floatsArrays;
|
|
|
|
- private _colors3;
|
|
|
|
- private _colors4;
|
|
|
|
- private _vectors2;
|
|
|
|
- private _vectors3;
|
|
|
|
- private _vectors4;
|
|
|
|
- private _matrices;
|
|
|
|
- private _matrices3x3;
|
|
|
|
- private _matrices2x2;
|
|
|
|
- private _cachedWorldViewMatrix;
|
|
|
|
- private _renderId;
|
|
|
|
- constructor(name: string, scene: Scene, shaderPath: any, options: any);
|
|
|
|
- needAlphaBlending(): boolean;
|
|
|
|
- needAlphaTesting(): boolean;
|
|
|
|
- private _checkUniform(uniformName);
|
|
|
|
- setTexture(name: string, texture: Texture): ShaderMaterial;
|
|
|
|
- setFloat(name: string, value: number): ShaderMaterial;
|
|
|
|
- setFloats(name: string, value: number[]): ShaderMaterial;
|
|
|
|
- setColor3(name: string, value: Color3): ShaderMaterial;
|
|
|
|
- setColor4(name: string, value: Color4): ShaderMaterial;
|
|
|
|
- setVector2(name: string, value: Vector2): ShaderMaterial;
|
|
|
|
- setVector3(name: string, value: Vector3): ShaderMaterial;
|
|
|
|
- setVector4(name: string, value: Vector4): ShaderMaterial;
|
|
|
|
- setMatrix(name: string, value: Matrix): ShaderMaterial;
|
|
|
|
- setMatrix3x3(name: string, value: Float32Array): ShaderMaterial;
|
|
|
|
- setMatrix2x2(name: string, value: Float32Array): ShaderMaterial;
|
|
|
|
- isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
- bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
- bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
- clone(name: string): ShaderMaterial;
|
|
|
|
- dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
- serialize(): any;
|
|
|
|
- static Parse(source: any, scene: Scene, rootUrl: string): ShaderMaterial;
|
|
|
|
|
|
+ class Path2 {
|
|
|
|
+ private _points;
|
|
|
|
+ private _length;
|
|
|
|
+ closed: boolean;
|
|
|
|
+ constructor(x: number, y: number);
|
|
|
|
+ addLineTo(x: number, y: number): Path2;
|
|
|
|
+ addArcTo(midX: number, midY: number, endX: number, endY: number, numberOfSegments?: number): Path2;
|
|
|
|
+ close(): Path2;
|
|
|
|
+ length(): number;
|
|
|
|
+ getPoints(): Vector2[];
|
|
|
|
+ getPointAtLengthPosition(normalizedLengthPosition: number): Vector2;
|
|
|
|
+ static StartingAt(x: number, y: number): Path2;
|
|
}
|
|
}
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
- class FresnelParameters {
|
|
|
|
- isEnabled: boolean;
|
|
|
|
- leftColor: Color3;
|
|
|
|
- rightColor: Color3;
|
|
|
|
- bias: number;
|
|
|
|
- power: number;
|
|
|
|
- clone(): FresnelParameters;
|
|
|
|
- serialize(): any;
|
|
|
|
- static Parse(parsedFresnelParameters: any): FresnelParameters;
|
|
|
|
|
|
+ class Path3D {
|
|
|
|
+ path: Vector3[];
|
|
|
|
+ private _curve;
|
|
|
|
+ private _distances;
|
|
|
|
+ private _tangents;
|
|
|
|
+ private _normals;
|
|
|
|
+ private _binormals;
|
|
|
|
+ private _raw;
|
|
|
|
+ /**
|
|
|
|
+ * new Path3D(path, normal, raw)
|
|
|
|
+ * path : an array of Vector3, the curve axis of the Path3D
|
|
|
|
+ * normal (optional) : Vector3, the first wanted normal to the curve. Ex (0, 1, 0) for a vertical normal.
|
|
|
|
+ * raw (optional, default false) : boolean, if true the returned Path3D isn't normalized. Useful to depict path acceleration or speed.
|
|
|
|
+ */
|
|
|
|
+ constructor(path: Vector3[], firstNormal?: Vector3, raw?: boolean);
|
|
|
|
+ getCurve(): Vector3[];
|
|
|
|
+ getTangents(): Vector3[];
|
|
|
|
+ getNormals(): Vector3[];
|
|
|
|
+ getBinormals(): Vector3[];
|
|
|
|
+ getDistances(): number[];
|
|
|
|
+ update(path: Vector3[], firstNormal?: Vector3): Path3D;
|
|
|
|
+ private _compute(firstNormal);
|
|
|
|
+ private _getFirstNonNullVector(index);
|
|
|
|
+ private _getLastNonNullVector(index);
|
|
|
|
+ private _normalVector(v0, vt, va);
|
|
}
|
|
}
|
|
- class StandardMaterial extends Material {
|
|
|
|
- diffuseTexture: BaseTexture;
|
|
|
|
- ambientTexture: BaseTexture;
|
|
|
|
- opacityTexture: BaseTexture;
|
|
|
|
- reflectionTexture: BaseTexture;
|
|
|
|
- emissiveTexture: BaseTexture;
|
|
|
|
- specularTexture: BaseTexture;
|
|
|
|
- bumpTexture: BaseTexture;
|
|
|
|
- lightmapTexture: BaseTexture;
|
|
|
|
- ambientColor: Color3;
|
|
|
|
- diffuseColor: Color3;
|
|
|
|
- specularColor: Color3;
|
|
|
|
- specularPower: number;
|
|
|
|
- emissiveColor: Color3;
|
|
|
|
- useAlphaFromDiffuseTexture: boolean;
|
|
|
|
- useEmissiveAsIllumination: boolean;
|
|
|
|
- linkEmissiveWithDiffuse: boolean;
|
|
|
|
- useReflectionFresnelFromSpecular: boolean;
|
|
|
|
- useSpecularOverAlpha: boolean;
|
|
|
|
- disableLighting: boolean;
|
|
|
|
- roughness: number;
|
|
|
|
- useLightmapAsShadowmap: boolean;
|
|
|
|
- diffuseFresnelParameters: FresnelParameters;
|
|
|
|
- opacityFresnelParameters: FresnelParameters;
|
|
|
|
- reflectionFresnelParameters: FresnelParameters;
|
|
|
|
- emissiveFresnelParameters: FresnelParameters;
|
|
|
|
- useGlossinessFromSpecularMapAlpha: boolean;
|
|
|
|
- private _renderTargets;
|
|
|
|
- private _worldViewProjectionMatrix;
|
|
|
|
- private _globalAmbientColor;
|
|
|
|
- private _renderId;
|
|
|
|
- private _defines;
|
|
|
|
- private _cachedDefines;
|
|
|
|
- private _useLogarithmicDepth;
|
|
|
|
- constructor(name: string, scene: Scene);
|
|
|
|
- useLogarithmicDepth: boolean;
|
|
|
|
- needAlphaBlending(): boolean;
|
|
|
|
- needAlphaTesting(): boolean;
|
|
|
|
- private _shouldUseAlphaFromDiffuseTexture();
|
|
|
|
- getAlphaTestTexture(): BaseTexture;
|
|
|
|
- private _checkCache(scene, mesh?, useInstances?);
|
|
|
|
- static PrepareDefinesForLights(scene: Scene, mesh: AbstractMesh, defines: MaterialDefines): boolean;
|
|
|
|
- private static _scaledDiffuse;
|
|
|
|
- private static _scaledSpecular;
|
|
|
|
- static BindLights(scene: Scene, mesh: AbstractMesh, effect: Effect, defines: MaterialDefines): void;
|
|
|
|
- isReady(mesh?: AbstractMesh, useInstances?: boolean): boolean;
|
|
|
|
- unbind(): void;
|
|
|
|
- bindOnlyWorldMatrix(world: Matrix): void;
|
|
|
|
- bind(world: Matrix, mesh?: Mesh): void;
|
|
|
|
- getAnimatables(): IAnimatable[];
|
|
|
|
- dispose(forceDisposeEffect?: boolean): void;
|
|
|
|
- clone(name: string): StandardMaterial;
|
|
|
|
- serialize(): any;
|
|
|
|
- static DiffuseTextureEnabled: boolean;
|
|
|
|
- static AmbientTextureEnabled: boolean;
|
|
|
|
- static OpacityTextureEnabled: boolean;
|
|
|
|
- static ReflectionTextureEnabled: boolean;
|
|
|
|
- static EmissiveTextureEnabled: boolean;
|
|
|
|
- static SpecularTextureEnabled: boolean;
|
|
|
|
- static BumpTextureEnabled: boolean;
|
|
|
|
- static FresnelEnabled: boolean;
|
|
|
|
- static LightmapEnabled: boolean;
|
|
|
|
- static Parse(source: any, scene: Scene, rootUrl: string): StandardMaterial;
|
|
|
|
|
|
+ class Curve3 {
|
|
|
|
+ private _points;
|
|
|
|
+ private _length;
|
|
|
|
+ static CreateQuadraticBezier(v0: Vector3, v1: Vector3, v2: Vector3, nbPoints: number): Curve3;
|
|
|
|
+ static CreateCubicBezier(v0: Vector3, v1: Vector3, v2: Vector3, v3: Vector3, nbPoints: number): Curve3;
|
|
|
|
+ static CreateHermiteSpline(p1: Vector3, t1: Vector3, p2: Vector3, t2: Vector3, nbPoints: number): Curve3;
|
|
|
|
+ constructor(points: Vector3[]);
|
|
|
|
+ getPoints(): Vector3[];
|
|
|
|
+ length(): number;
|
|
|
|
+ continue(curve: Curve3): Curve3;
|
|
|
|
+ private _computeLength(path);
|
|
|
|
+ }
|
|
|
|
+ class PositionNormalVertex {
|
|
|
|
+ position: Vector3;
|
|
|
|
+ normal: Vector3;
|
|
|
|
+ constructor(position?: Vector3, normal?: Vector3);
|
|
|
|
+ clone(): PositionNormalVertex;
|
|
|
|
+ }
|
|
|
|
+ class PositionNormalTextureVertex {
|
|
|
|
+ position: Vector3;
|
|
|
|
+ normal: Vector3;
|
|
|
|
+ uv: Vector2;
|
|
|
|
+ constructor(position?: Vector3, normal?: Vector3, uv?: Vector2);
|
|
|
|
+ clone(): PositionNormalTextureVertex;
|
|
|
|
+ }
|
|
|
|
+ class Tmp {
|
|
|
|
+ static Vector2: Vector2[];
|
|
|
|
+ static Vector3: Vector3[];
|
|
|
|
+ static Vector4: Vector4[];
|
|
|
|
+ static Quaternion: Quaternion[];
|
|
|
|
+ static Matrix: Matrix[];
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -4512,8 +4512,8 @@ declare module BABYLON {
|
|
static ExtrudeShapeCustom(name: string, options: {
|
|
static ExtrudeShapeCustom(name: string, options: {
|
|
shape: Vector3[];
|
|
shape: Vector3[];
|
|
path: Vector3[];
|
|
path: Vector3[];
|
|
- scaleFunction?;
|
|
|
|
- rotationFunction?;
|
|
|
|
|
|
+ scaleFunction?: any;
|
|
|
|
+ rotationFunction?: any;
|
|
ribbonCloseArray?: boolean;
|
|
ribbonCloseArray?: boolean;
|
|
ribbonClosePath?: boolean;
|
|
ribbonClosePath?: boolean;
|
|
cap?: number;
|
|
cap?: number;
|
|
@@ -5247,6 +5247,27 @@ declare module BABYLON {
|
|
}
|
|
}
|
|
|
|
|
|
declare module BABYLON {
|
|
declare module BABYLON {
|
|
|
|
+ class ReflectionProbe {
|
|
|
|
+ name: string;
|
|
|
|
+ private _scene;
|
|
|
|
+ private _renderTargetTexture;
|
|
|
|
+ private _projectionMatrix;
|
|
|
|
+ private _viewMatrix;
|
|
|
|
+ private _target;
|
|
|
|
+ private _add;
|
|
|
|
+ private _attachedMesh;
|
|
|
|
+ position: Vector3;
|
|
|
|
+ constructor(name: string, size: number, scene: Scene, generateMipMaps?: boolean);
|
|
|
|
+ refreshRate: number;
|
|
|
|
+ getScene(): Scene;
|
|
|
|
+ cubeTexture: RenderTargetTexture;
|
|
|
|
+ renderList: AbstractMesh[];
|
|
|
|
+ attachToMesh(mesh: AbstractMesh): void;
|
|
|
|
+ dispose(): void;
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+declare module BABYLON {
|
|
class AnaglyphPostProcess extends PostProcess {
|
|
class AnaglyphPostProcess extends PostProcess {
|
|
constructor(name: string, ratio: number, camera: Camera, samplingMode?: number, engine?: Engine, reusable?: boolean);
|
|
constructor(name: string, ratio: number, camera: Camera, samplingMode?: number, engine?: Engine, reusable?: boolean);
|
|
}
|
|
}
|
|
@@ -5816,27 +5837,6 @@ declare module BABYLON {
|
|
}
|
|
}
|
|
|
|
|
|
declare module BABYLON {
|
|
declare module BABYLON {
|
|
- class ReflectionProbe {
|
|
|
|
- name: string;
|
|
|
|
- private _scene;
|
|
|
|
- private _renderTargetTexture;
|
|
|
|
- private _projectionMatrix;
|
|
|
|
- private _viewMatrix;
|
|
|
|
- private _target;
|
|
|
|
- private _add;
|
|
|
|
- private _attachedMesh;
|
|
|
|
- position: Vector3;
|
|
|
|
- constructor(name: string, size: number, scene: Scene, generateMipMaps?: boolean);
|
|
|
|
- refreshRate: number;
|
|
|
|
- getScene(): Scene;
|
|
|
|
- cubeTexture: RenderTargetTexture;
|
|
|
|
- renderList: AbstractMesh[];
|
|
|
|
- attachToMesh(mesh: AbstractMesh): void;
|
|
|
|
- dispose(): void;
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-declare module BABYLON {
|
|
|
|
class BoundingBoxRenderer {
|
|
class BoundingBoxRenderer {
|
|
frontColor: Color3;
|
|
frontColor: Color3;
|
|
backColor: Color3;
|
|
backColor: Color3;
|