Gary Hsu пре 5 година
родитељ
комит
5217e24cca
1 измењених фајлова са 8 додато и 0 уклоњено
  1. 8 0
      loaders/src/glTF/glTFValidation.ts

+ 8 - 0
loaders/src/glTF/glTFValidation.ts

@@ -81,6 +81,14 @@ export class GLTFValidation {
 
     private static _LoadScriptPromise: Promise<void>;
 
+    /**
+     * Validate a glTF asset using the glTF-Validator.
+     * @param data The JSON of a glTF or the array buffer of a binary glTF
+     * @param rootUrl The root url for the glTF
+     * @param fileName The file name for the glTF
+     * @param getExternalResource The callback to get external resources for the glTF validator
+     * @returns A promise that resolves with the glTF validation results once complete
+     */
     public static ValidateAsync(data: string | ArrayBuffer, rootUrl: string, fileName: string, getExternalResource: (uri: string) => Promise<ArrayBuffer>): Promise<GLTF2.IGLTFValidationResults>
     {
         if (typeof Worker === "function") {