瀏覽代碼

Fix glTF API documentation

Gary Hsu 7 年之前
父節點
當前提交
0f23901712

+ 0 - 1
loaders/src/glTF/2.0/Extensions/KHR_materials_pbrSpecularGlossiness.ts

@@ -17,7 +17,6 @@ module BABYLON.GLTF2.Extensions {
     export class KHR_materials_pbrSpecularGlossiness extends GLTFLoaderExtension {
         public readonly name = NAME;
 
-        /** @hidden */
         protected _loadMaterialAsync(context: string, material: _ILoaderMaterial, mesh: _ILoaderMesh, babylonMesh: Mesh, babylonDrawMode: number, assign: (babylonMaterial: Material) => void): Nullable<Promise<void>> {
             return this._loadExtensionAsync<IKHRMaterialsPbrSpecularGlossiness>(context, material, (extensionContext, extension) => {
                 material._babylonData = material._babylonData || {};

+ 20 - 20
loaders/src/glTF/2.0/babylon.glTFLoaderExtension.ts

@@ -40,8 +40,8 @@ module BABYLON.GLTF2 {
          */
         protected _loadSceneAsync(context: string, node: _ILoaderScene): Nullable<Promise<void>> { return null; }
 
-        /** 
-         * Override this method to modify the default behavior for loading nodes. 
+        /**
+         * Override this method to modify the default behavior for loading nodes.
          * @hidden
          */
         protected _loadNodeAsync(context: string, node: _ILoaderNode): Nullable<Promise<void>> { return null; }
@@ -58,22 +58,22 @@ module BABYLON.GLTF2 {
          */
         protected _loadMaterialAsync(context: string, material: _ILoaderMaterial, mesh: _ILoaderMesh, babylonMesh: Mesh, babylonDrawMode: number, assign: (babylonMaterial: Material) => void): Nullable<Promise<void>> { return null; }
 
-        /** 
-         * Override this method to modify the default behavior for loading textures. 
+        /**
+         * Override this method to modify the default behavior for loading textures.
          * @hidden
          */
         protected _loadTextureAsync(context: string, textureInfo: ITextureInfo, assign: (texture: Texture) => void): Nullable<Promise<void>> { return null; }
 
-        /** 
-         * Override this method to modify the default behavior for loading uris. 
+        /**
+         * Override this method to modify the default behavior for loading uris.
          * @hidden
          */
         protected _loadUriAsync(context: string, uri: string): Nullable<Promise<ArrayBufferView>> { return null; }
 
         // #endregion
 
-        /** 
-         * Helper method called by a loader extension to load an glTF extension. 
+        /**
+         * Helper method called by a loader extension to load an glTF extension.
          * @hidden
          */
         protected _loadExtensionAsync<TProperty, TResult = void>(context: string, property: IProperty, actionAsync: (extensionContext: string, extension: TProperty) => Nullable<Promise<TResult>>): Nullable<Promise<TResult>> {
@@ -128,48 +128,48 @@ module BABYLON.GLTF2 {
             }
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading scenes. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading scenes.
          * @hidden
          */
         public static _LoadSceneAsync(loader: GLTFLoader, context: string, scene: _ILoaderScene): Nullable<Promise<void>> {
             return loader._applyExtensions(extension => extension._loadSceneAsync(context, scene));
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading nodes. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading nodes.
          * @hidden
          */
         public static _LoadNodeAsync(loader: GLTFLoader, context: string, node: _ILoaderNode): Nullable<Promise<void>> {
             return loader._applyExtensions(extension => extension._loadNodeAsync(context, node));
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading mesh primitive vertex data. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading mesh primitive vertex data.
          * @hidden
          */
         public static _LoadVertexDataAsync(loader: GLTFLoader, context: string, primitive: _ILoaderMeshPrimitive, babylonMesh: Mesh): Nullable<Promise<Geometry>> {
             return loader._applyExtensions(extension => extension._loadVertexDataAsync(context, primitive, babylonMesh));
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading materials. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading materials.
          * @hidden
          */
         public static _LoadMaterialAsync(loader: GLTFLoader, context: string, material: _ILoaderMaterial, mesh: _ILoaderMesh, babylonMesh: Mesh, babylonDrawMode: number, assign: (babylonMaterial: Material) => void): Nullable<Promise<void>> {
             return loader._applyExtensions(extension => extension._loadMaterialAsync(context, material, mesh, babylonMesh, babylonDrawMode, assign));
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading textures. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading textures.
          * @hidden
          */
         public static _LoadTextureAsync(loader: GLTFLoader, context: string, textureInfo: ITextureInfo, assign: (texture: Texture) => void): Nullable<Promise<void>> {
             return loader._applyExtensions(extension => extension._loadTextureAsync(context, textureInfo, assign));
         }
 
-        /** 
-         * Helper method called by the loader to allow extensions to override loading uris. 
+        /**
+         * Helper method called by the loader to allow extensions to override loading uris.
          * @hidden
          */
         public static _LoadUriAsync(loader: GLTFLoader, context: string, uri: string): Nullable<Promise<ArrayBufferView>> {

+ 4 - 8
loaders/src/glTF/babylon.glTFFileLoader.ts

@@ -188,16 +188,10 @@ module BABYLON {
      * File loader for loading glTF files into a scene.
      */
     export class GLTFFileLoader implements IDisposable, ISceneLoaderPluginAsync, ISceneLoaderPluginFactory {
-        /**
-         * Factory function that creates a glTF 1.0 loader
-         * @hidden
-         */
+        /** @hidden */
         public static _CreateGLTFLoaderV1: () => IGLTFLoader;
 
-        /**
-         * Factory function that creates a glTF 2.0 loader
-         * @hidden
-         */
+        /** @hidden */
         public static _CreateGLTFLoaderV2: () => IGLTFLoader;
 
         // #region Common options
@@ -227,12 +221,14 @@ module BABYLON {
          * Set this property to false to disable incremental loading which delays the loader from calling the success callback until after loading the meshes and shaders.
          * Textures always loads asynchronously. For example, the success callback can compute the bounding information of the loaded meshes when incremental loading is disabled.
          * Defaults to true.
+         * @hidden
          */
         public static IncrementalLoading = true;
 
         /**
          * Set this property to true in order to work with homogeneous coordinates, available with some converters and exporters.
          * Defaults to false. See https://en.wikipedia.org/wiki/Homogeneous_coordinates.
+         * @hidden
          */
         public static HomogeneousCoordinates = false;
 

+ 0 - 4
serializers/src/glTF/2.0/babylon.glTFExporter.ts

@@ -1,9 +1,5 @@
 /// <reference path="../../../../dist/preview release/gltf2Interface/babylon.glTF2Interface.d.ts"/>
 
-/**
- * Module for the Babylon glTF 2.0 exporter.  Should ONLY be used internally
- * @hidden 
- */
 module BABYLON.GLTF2 {
     /** 
      * Utility interface for storing vertex attribute data