David Catuhe %!s(int64=7) %!d(string=hai) anos
pai
achega
68ff30d036

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 2591 - 2586
Playground/babylon.d.txt


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 6576 - 6571
dist/preview release/babylon.d.ts


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 1 - 1
dist/preview release/babylon.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 9 - 2
dist/preview release/babylon.max.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 9 - 2
dist/preview release/babylon.no-module.max.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 1 - 1
dist/preview release/babylon.worker.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 9 - 2
dist/preview release/es6.js


+ 157 - 117
dist/preview release/viewer/babylon.viewer.d.ts

@@ -20,6 +20,46 @@ declare module BabylonViewer {
     const Version: string;
     const Version: string;
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
+    /**
+        * This is the mapper's interface. Implement this function to create your own mapper and register it at the mapper manager
+        */
+    export interface IMapper {
+            map(rawSource: any): ViewerConfiguration;
+    }
+    /**
+        * The MapperManager manages the different implemented mappers.
+        * It allows the user to register new mappers as well and use them to parse their own configuration data
+        */
+    export class MapperManager {
+            /**
+                * The default mapper is the JSON mapper.
+                */
+            static DefaultMapper: string;
+            constructor();
+            /**
+                * Get a specific configuration mapper.
+                *
+                * @param type the name of the mapper to load
+                */
+            getMapper(type: string): IMapper;
+            /**
+                * Use this functio to register your own configuration mapper.
+                * After a mapper is registered, it can be used to parse the specific type fo configuration to the standard ViewerConfiguration.
+                * @param type the name of the mapper. This will be used to define the configuration type and/or to get the mapper
+                * @param mapper The implemented mapper
+                */
+            registerMapper(type: string, mapper: IMapper): void;
+            /**
+                * Dispose the mapper manager and all of its mappers.
+                */
+            dispose(): void;
+    }
+    /**
+        * mapperManager is a singleton of the type MapperManager.
+        * The mapperManager can be disposed directly with calling mapperManager.dispose()
+        * or indirectly with using BabylonViewer.disposeAll()
+        */
+    export let mapperManager: MapperManager;
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
     export class ViewerGlobals {
     export class ViewerGlobals {
@@ -895,6 +935,101 @@ declare module BabylonViewer {
 declare module BabylonViewer {
 declare module BabylonViewer {
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
+    export function getConfigurationKey(key: string, configObject: any): any;
+    export interface ViewerConfiguration {
+            version?: string;
+            extends?: string;
+            pageUrl?: string;
+            configuration?: string | {
+                    url?: string;
+                    payload?: any;
+                    mapper?: string;
+            };
+            observers?: IObserversConfiguration;
+            canvasElement?: string;
+            model?: IModelConfiguration | string;
+            scene?: ISceneConfiguration;
+            optimizer?: ISceneOptimizerConfiguration | boolean;
+            camera?: ICameraConfiguration;
+            skybox?: boolean | ISkyboxConfiguration;
+            ground?: boolean | IGroundConfiguration;
+            lights?: {
+                    [name: string]: number | boolean | ILightConfiguration;
+            };
+            engine?: {
+                    renderInBackground?: boolean;
+                    antialiasing?: boolean;
+                    disableResize?: boolean;
+                    engineOptions?: BABYLON.EngineOptions;
+                    adaptiveQuality?: boolean;
+                    hdEnabled?: boolean;
+            };
+            templates?: {
+                    main: ITemplateConfiguration;
+                    [key: string]: ITemplateConfiguration;
+            };
+            customShaders?: {
+                    shaders?: {
+                            [key: string]: string;
+                    };
+                    includes?: {
+                            [key: string]: string;
+                    };
+            };
+            loaderPlugins?: {
+                    extendedMaterial?: boolean;
+                    msftLod?: boolean;
+                    telemetry?: boolean;
+                    minecraft?: boolean;
+                    [propName: string]: boolean | undefined;
+            };
+            environmentMap?: IEnvironmentMapConfiguration;
+            vr?: IVRConfiguration;
+            lab?: {
+                    flashlight?: boolean | {
+                            exponent?: number;
+                            angle?: number;
+                            intensity?: number;
+                            diffuse?: {
+                                    r: number;
+                                    g: number;
+                                    b: number;
+                            };
+                            specular?: {
+                                    r: number;
+                                    g: number;
+                                    b: number;
+                            };
+                    };
+                    hideLoadingDelay?: number;
+                    /** Deprecated */
+                    assetsRootURL?: string;
+                    environmentMainColor?: {
+                            r: number;
+                            g: number;
+                            b: number;
+                    };
+                    /** Deprecated */
+                    environmentMap?: {
+                            /**
+                                * Environment map texture path in relative to the asset folder.
+                                */
+                            texture: string;
+                            /**
+                                * Default rotation to apply to the environment map.
+                                */
+                            rotationY: number;
+                            /**
+                                * Tint level of the main color on the environment map.
+                                */
+                            tintLevel: number;
+                    };
+                    defaultRenderingPipelines?: boolean | IDefaultRenderingPipelineConfiguration;
+                    globalLightRotation?: number;
+            };
+    }
+}
+declare module BabylonViewer {
     /**
     /**
         * The object sent when an event is triggered
         * The object sent when an event is triggered
         */
         */
@@ -1407,101 +1542,30 @@ declare module BabylonViewer {
     export function addLoaderPlugin(name: string, plugin: ILoaderPlugin): void;
     export function addLoaderPlugin(name: string, plugin: ILoaderPlugin): void;
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
-    export function getConfigurationKey(key: string, configObject: any): any;
-    export interface ViewerConfiguration {
-            version?: string;
-            extends?: string;
-            pageUrl?: string;
-            configuration?: string | {
-                    url?: string;
-                    payload?: any;
-                    mapper?: string;
-            };
-            observers?: IObserversConfiguration;
-            canvasElement?: string;
-            model?: IModelConfiguration | string;
-            scene?: ISceneConfiguration;
-            optimizer?: ISceneOptimizerConfiguration | boolean;
-            camera?: ICameraConfiguration;
-            skybox?: boolean | ISkyboxConfiguration;
-            ground?: boolean | IGroundConfiguration;
-            lights?: {
-                    [name: string]: number | boolean | ILightConfiguration;
-            };
-            engine?: {
-                    renderInBackground?: boolean;
-                    antialiasing?: boolean;
-                    disableResize?: boolean;
-                    engineOptions?: BABYLON.EngineOptions;
-                    adaptiveQuality?: boolean;
-                    hdEnabled?: boolean;
-            };
-            templates?: {
-                    main: ITemplateConfiguration;
-                    [key: string]: ITemplateConfiguration;
-            };
-            customShaders?: {
-                    shaders?: {
-                            [key: string]: string;
-                    };
-                    includes?: {
-                            [key: string]: string;
-                    };
-            };
-            loaderPlugins?: {
-                    extendedMaterial?: boolean;
-                    msftLod?: boolean;
-                    telemetry?: boolean;
-                    minecraft?: boolean;
-                    [propName: string]: boolean | undefined;
-            };
-            environmentMap?: IEnvironmentMapConfiguration;
-            vr?: IVRConfiguration;
-            lab?: {
-                    flashlight?: boolean | {
-                            exponent?: number;
-                            angle?: number;
-                            intensity?: number;
-                            diffuse?: {
-                                    r: number;
-                                    g: number;
-                                    b: number;
-                            };
-                            specular?: {
-                                    r: number;
-                                    g: number;
-                                    b: number;
-                            };
-                    };
-                    hideLoadingDelay?: number;
-                    /** Deprecated */
-                    assetsRootURL?: string;
-                    environmentMainColor?: {
-                            r: number;
-                            g: number;
-                            b: number;
-                    };
-                    /** Deprecated */
-                    environmentMap?: {
-                            /**
-                                * Environment map texture path in relative to the asset folder.
-                                */
-                            texture: string;
-                            /**
-                                * Default rotation to apply to the environment map.
-                                */
-                            rotationY: number;
-                            /**
-                                * Tint level of the main color on the environment map.
-                                */
-                            tintLevel: number;
-                    };
-                    defaultRenderingPipelines?: boolean | IDefaultRenderingPipelineConfiguration;
-                    globalLightRotation?: number;
-            };
-    }
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
+    export interface IEnvironmentMapConfiguration {
+            /**
+                * Environment map texture path in relative to the asset folder.
+                */
+            texture: string;
+            /**
+                * Default rotation to apply to the environment map.
+                */
+            rotationY: number;
+            /**
+                * Tint level of the main color on the environment map.
+                */
+            tintLevel: number;
+            /**
+                * The environment's main color.
+                */
+            mainColor?: {
+                    r?: number;
+                    g?: number;
+                    b?: number;
+            };
+    }
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
     /**
     /**
@@ -1585,30 +1649,6 @@ declare module BabylonViewer {
     }
     }
 }
 }
 declare module BabylonViewer {
 declare module BabylonViewer {
-    export interface IEnvironmentMapConfiguration {
-            /**
-                * Environment map texture path in relative to the asset folder.
-                */
-            texture: string;
-            /**
-                * Default rotation to apply to the environment map.
-                */
-            rotationY: number;
-            /**
-                * Tint level of the main color on the environment map.
-                */
-            tintLevel: number;
-            /**
-                * The environment's main color.
-                */
-            mainColor?: {
-                    r?: number;
-                    g?: number;
-                    b?: number;
-            };
-    }
-}
-declare module BabylonViewer {
     /**
     /**
         * Defines an animation to be applied to a model (translation, scale or rotation).
         * Defines an animation to be applied to a model (translation, scale or rotation).
         */
         */

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 1 - 1
dist/preview release/viewer/babylon.viewer.js


A diferenza do arquivo foi suprimida porque é demasiado grande
+ 1 - 1
dist/preview release/viewer/babylon.viewer.max.js


+ 165 - 125
dist/preview release/viewer/babylon.viewer.module.d.ts

@@ -41,7 +41,47 @@ declare module 'babylonjs-viewer' {
 }
 }
 
 
 declare module 'babylonjs-viewer/configuration/mappers' {
 declare module 'babylonjs-viewer/configuration/mappers' {
-    
+    import { ViewerConfiguration } from 'babylonjs-viewer/configuration/configuration';
+    /**
+        * This is the mapper's interface. Implement this function to create your own mapper and register it at the mapper manager
+        */
+    export interface IMapper {
+            map(rawSource: any): ViewerConfiguration;
+    }
+    /**
+        * The MapperManager manages the different implemented mappers.
+        * It allows the user to register new mappers as well and use them to parse their own configuration data
+        */
+    export class MapperManager {
+            /**
+                * The default mapper is the JSON mapper.
+                */
+            static DefaultMapper: string;
+            constructor();
+            /**
+                * Get a specific configuration mapper.
+                *
+                * @param type the name of the mapper to load
+                */
+            getMapper(type: string): IMapper;
+            /**
+                * Use this functio to register your own configuration mapper.
+                * After a mapper is registered, it can be used to parse the specific type fo configuration to the standard ViewerConfiguration.
+                * @param type the name of the mapper. This will be used to define the configuration type and/or to get the mapper
+                * @param mapper The implemented mapper
+                */
+            registerMapper(type: string, mapper: IMapper): void;
+            /**
+                * Dispose the mapper manager and all of its mappers.
+                */
+            dispose(): void;
+    }
+    /**
+        * mapperManager is a singleton of the type MapperManager.
+        * The mapperManager can be disposed directly with calling mapperManager.dispose()
+        * or indirectly with using BabylonViewer.disposeAll()
+        */
+    export let mapperManager: MapperManager;
 }
 }
 
 
 declare module 'babylonjs-viewer/configuration/globals' {
 declare module 'babylonjs-viewer/configuration/globals' {
@@ -966,6 +1006,105 @@ declare module 'babylonjs-viewer/configuration' {
     export * from 'babylonjs-viewer/configuration/interfaces';
     export * from 'babylonjs-viewer/configuration/interfaces';
 }
 }
 
 
+declare module 'babylonjs-viewer/configuration/configuration' {
+    import { EngineOptions } from 'babylonjs';
+    import { ICameraConfiguration, IDefaultRenderingPipelineConfiguration, IGroundConfiguration, ILightConfiguration, IModelConfiguration, IObserversConfiguration, ISceneConfiguration, ISceneOptimizerConfiguration, ISkyboxConfiguration, ITemplateConfiguration, IVRConfiguration } from 'babylonjs-viewer/configuration/interfaces';
+    import { IEnvironmentMapConfiguration } from 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration';
+    export function getConfigurationKey(key: string, configObject: any): any;
+    export interface ViewerConfiguration {
+            version?: string;
+            extends?: string;
+            pageUrl?: string;
+            configuration?: string | {
+                    url?: string;
+                    payload?: any;
+                    mapper?: string;
+            };
+            observers?: IObserversConfiguration;
+            canvasElement?: string;
+            model?: IModelConfiguration | string;
+            scene?: ISceneConfiguration;
+            optimizer?: ISceneOptimizerConfiguration | boolean;
+            camera?: ICameraConfiguration;
+            skybox?: boolean | ISkyboxConfiguration;
+            ground?: boolean | IGroundConfiguration;
+            lights?: {
+                    [name: string]: number | boolean | ILightConfiguration;
+            };
+            engine?: {
+                    renderInBackground?: boolean;
+                    antialiasing?: boolean;
+                    disableResize?: boolean;
+                    engineOptions?: EngineOptions;
+                    adaptiveQuality?: boolean;
+                    hdEnabled?: boolean;
+            };
+            templates?: {
+                    main: ITemplateConfiguration;
+                    [key: string]: ITemplateConfiguration;
+            };
+            customShaders?: {
+                    shaders?: {
+                            [key: string]: string;
+                    };
+                    includes?: {
+                            [key: string]: string;
+                    };
+            };
+            loaderPlugins?: {
+                    extendedMaterial?: boolean;
+                    msftLod?: boolean;
+                    telemetry?: boolean;
+                    minecraft?: boolean;
+                    [propName: string]: boolean | undefined;
+            };
+            environmentMap?: IEnvironmentMapConfiguration;
+            vr?: IVRConfiguration;
+            lab?: {
+                    flashlight?: boolean | {
+                            exponent?: number;
+                            angle?: number;
+                            intensity?: number;
+                            diffuse?: {
+                                    r: number;
+                                    g: number;
+                                    b: number;
+                            };
+                            specular?: {
+                                    r: number;
+                                    g: number;
+                                    b: number;
+                            };
+                    };
+                    hideLoadingDelay?: number;
+                    /** Deprecated */
+                    assetsRootURL?: string;
+                    environmentMainColor?: {
+                            r: number;
+                            g: number;
+                            b: number;
+                    };
+                    /** Deprecated */
+                    environmentMap?: {
+                            /**
+                                * Environment map texture path in relative to the asset folder.
+                                */
+                            texture: string;
+                            /**
+                                * Default rotation to apply to the environment map.
+                                */
+                            rotationY: number;
+                            /**
+                                * Tint level of the main color on the environment map.
+                                */
+                            tintLevel: number;
+                    };
+                    defaultRenderingPipelines?: boolean | IDefaultRenderingPipelineConfiguration;
+                    globalLightRotation?: number;
+            };
+    }
+}
+
 declare module 'babylonjs-viewer/templating/templateManager' {
 declare module 'babylonjs-viewer/templating/templateManager' {
     import { Observable } from 'babylonjs';
     import { Observable } from 'babylonjs';
     import { EventManager } from 'babylonjs-viewer/templating/eventManager';
     import { EventManager } from 'babylonjs-viewer/templating/eventManager';
@@ -1507,105 +1646,6 @@ declare module 'babylonjs-viewer/loader/plugins' {
     export function addLoaderPlugin(name: string, plugin: ILoaderPlugin): void;
     export function addLoaderPlugin(name: string, plugin: ILoaderPlugin): void;
 }
 }
 
 
-declare module 'babylonjs-viewer/configuration/configuration' {
-    import { EngineOptions } from 'babylonjs';
-    import { ICameraConfiguration, IDefaultRenderingPipelineConfiguration, IGroundConfiguration, ILightConfiguration, IModelConfiguration, IObserversConfiguration, ISceneConfiguration, ISceneOptimizerConfiguration, ISkyboxConfiguration, ITemplateConfiguration, IVRConfiguration } from 'babylonjs-viewer/configuration/interfaces';
-    import { IEnvironmentMapConfiguration } from 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration';
-    export function getConfigurationKey(key: string, configObject: any): any;
-    export interface ViewerConfiguration {
-            version?: string;
-            extends?: string;
-            pageUrl?: string;
-            configuration?: string | {
-                    url?: string;
-                    payload?: any;
-                    mapper?: string;
-            };
-            observers?: IObserversConfiguration;
-            canvasElement?: string;
-            model?: IModelConfiguration | string;
-            scene?: ISceneConfiguration;
-            optimizer?: ISceneOptimizerConfiguration | boolean;
-            camera?: ICameraConfiguration;
-            skybox?: boolean | ISkyboxConfiguration;
-            ground?: boolean | IGroundConfiguration;
-            lights?: {
-                    [name: string]: number | boolean | ILightConfiguration;
-            };
-            engine?: {
-                    renderInBackground?: boolean;
-                    antialiasing?: boolean;
-                    disableResize?: boolean;
-                    engineOptions?: EngineOptions;
-                    adaptiveQuality?: boolean;
-                    hdEnabled?: boolean;
-            };
-            templates?: {
-                    main: ITemplateConfiguration;
-                    [key: string]: ITemplateConfiguration;
-            };
-            customShaders?: {
-                    shaders?: {
-                            [key: string]: string;
-                    };
-                    includes?: {
-                            [key: string]: string;
-                    };
-            };
-            loaderPlugins?: {
-                    extendedMaterial?: boolean;
-                    msftLod?: boolean;
-                    telemetry?: boolean;
-                    minecraft?: boolean;
-                    [propName: string]: boolean | undefined;
-            };
-            environmentMap?: IEnvironmentMapConfiguration;
-            vr?: IVRConfiguration;
-            lab?: {
-                    flashlight?: boolean | {
-                            exponent?: number;
-                            angle?: number;
-                            intensity?: number;
-                            diffuse?: {
-                                    r: number;
-                                    g: number;
-                                    b: number;
-                            };
-                            specular?: {
-                                    r: number;
-                                    g: number;
-                                    b: number;
-                            };
-                    };
-                    hideLoadingDelay?: number;
-                    /** Deprecated */
-                    assetsRootURL?: string;
-                    environmentMainColor?: {
-                            r: number;
-                            g: number;
-                            b: number;
-                    };
-                    /** Deprecated */
-                    environmentMap?: {
-                            /**
-                                * Environment map texture path in relative to the asset folder.
-                                */
-                            texture: string;
-                            /**
-                                * Default rotation to apply to the environment map.
-                                */
-                            rotationY: number;
-                            /**
-                                * Tint level of the main color on the environment map.
-                                */
-                            tintLevel: number;
-                    };
-                    defaultRenderingPipelines?: boolean | IDefaultRenderingPipelineConfiguration;
-                    globalLightRotation?: number;
-            };
-    }
-}
-
 declare module 'babylonjs-viewer/configuration/interfaces' {
 declare module 'babylonjs-viewer/configuration/interfaces' {
     export * from 'babylonjs-viewer/configuration/interfaces/cameraConfiguration';
     export * from 'babylonjs-viewer/configuration/interfaces/cameraConfiguration';
     export * from 'babylonjs-viewer/configuration/interfaces/colorGradingConfiguration';
     export * from 'babylonjs-viewer/configuration/interfaces/colorGradingConfiguration';
@@ -1624,6 +1664,31 @@ declare module 'babylonjs-viewer/configuration/interfaces' {
     export * from 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration';
     export * from 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration';
 }
 }
 
 
+declare module 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration' {
+    export interface IEnvironmentMapConfiguration {
+            /**
+                * Environment map texture path in relative to the asset folder.
+                */
+            texture: string;
+            /**
+                * Default rotation to apply to the environment map.
+                */
+            rotationY: number;
+            /**
+                * Tint level of the main color on the environment map.
+                */
+            tintLevel: number;
+            /**
+                * The environment's main color.
+                */
+            mainColor?: {
+                    r?: number;
+                    g?: number;
+                    b?: number;
+            };
+    }
+}
+
 declare module 'babylonjs-viewer/templating/eventManager' {
 declare module 'babylonjs-viewer/templating/eventManager' {
     import { EventCallback, TemplateManager } from "babylonjs-viewer/templating/templateManager";
     import { EventCallback, TemplateManager } from "babylonjs-viewer/templating/templateManager";
     /**
     /**
@@ -1710,31 +1775,6 @@ declare module 'babylonjs-viewer/labs/viewerLabs' {
     }
     }
 }
 }
 
 
-declare module 'babylonjs-viewer/configuration/interfaces/environmentMapConfiguration' {
-    export interface IEnvironmentMapConfiguration {
-            /**
-                * Environment map texture path in relative to the asset folder.
-                */
-            texture: string;
-            /**
-                * Default rotation to apply to the environment map.
-                */
-            rotationY: number;
-            /**
-                * Tint level of the main color on the environment map.
-                */
-            tintLevel: number;
-            /**
-                * The environment's main color.
-                */
-            mainColor?: {
-                    r?: number;
-                    g?: number;
-                    b?: number;
-            };
-    }
-}
-
 declare module 'babylonjs-viewer/configuration/interfaces/modelAnimationConfiguration' {
 declare module 'babylonjs-viewer/configuration/interfaces/modelAnimationConfiguration' {
     /**
     /**
         * Defines an animation to be applied to a model (translation, scale or rotation).
         * Defines an animation to be applied to a model (translation, scale or rotation).