<h5 dir="auto">Description of the problem</h5>
<p dir="auto">Duplicate request handling in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="266674390" data-permission-text="Title is private" data-url="https://github.com/mrdoob/three.js/issues/12434" data-hovercard-type="pull_request" data-hovercard-url="/mrdoob/three.js/pull/12434/hovercard" href="https://github.com/mrdoob/three.js/pull/12434">#12434</a></p>
<p dir="auto">In case of an error on the request, we should notify the rest of the duplicate <code class="notranslate">.load()</code> callbacks (<code class="notranslate">onError</code>). Similarly, we can call <code class="notranslate">onProgress</code> to every duplicate <code class="notranslate">.load()</code> call callback.</p>
<h5 dir="auto">Three.js version</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Dev</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> r87</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> ...</li>
</ul>
<h5 dir="auto">Browser</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> All of them</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Chrome</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Firefox</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Internet Explorer</li>
</ul>
<h5 dir="auto">OS</h5>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> All of them</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Windows</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> macOS</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Linux</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Android</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> iOS</li>
</ul>
<h5 dir="auto">Hardware Requirements (graphics card, VR Device, ...)</h5>
<p dir="auto"><strong>Describe the bug</strong></p>
<p dir="auto">This glb file <a href="https://github.com/mrdoob/three.js/files/6301192/sofa.zip">sofa.zip</a> which made and exported from Blender, has diffuseMap and aoMap.</p>
<p dir="auto">When loaded to threejs scene using GLTFLoader, the aoMap display incorret.<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496195-ffa1a600-9c51-11eb-91fc-e6340ecfcc63.png"><img src="https://user-images.githubusercontent.com/10785634/114496195-ffa1a600-9c51-11eb-91fc-e6340ecfcc63.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">I guess they has different uvs and tried to add this line <code class="notranslate">sofa.geometry.attributes.uv2.copy(sofa.geometry.attributes.uv)</code> then display correct.<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496293-37a8e900-9c52-11eb-92b1-4b3490088877.png"><img src="https://user-images.githubusercontent.com/10785634/114496293-37a8e900-9c52-11eb-92b1-4b3490088877.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">I also tried <a href="https://threejs.org/editor/" rel="nofollow">https://threejs.org/editor/</a> and <a href="https://modelviewer.dev/editor/" rel="nofollow">https://modelviewer.dev/editor/</a> ( which I heard also based on threejs ), all has the same problem.<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496645-febd4400-9c52-11eb-8109-f771fb6f410c.png"><img src="https://user-images.githubusercontent.com/10785634/114496645-febd4400-9c52-11eb-8109-f771fb6f410c.png" alt="image" style="max-width: 100%;"></a><br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496653-05e45200-9c53-11eb-9075-c6b8eef8a3aa.png"><img src="https://user-images.githubusercontent.com/10785634/114496653-05e45200-9c53-11eb-9075-c6b8eef8a3aa.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">But with <a href="https://sandbox.babylonjs.com/" rel="nofollow">https://sandbox.babylonjs.com/</a> , <a href="https://playcanvas.com/viewer" rel="nofollow">https://playcanvas.com/viewer</a> and Win10 3D Viewer, display all ok.<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496775-40e68580-9c53-11eb-9411-8d081b3e655a.png"><img src="https://user-images.githubusercontent.com/10785634/114496775-40e68580-9c53-11eb-9411-8d081b3e655a.png" alt="image" style="max-width: 100%;"></a><br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496785-45ab3980-9c53-11eb-936b-1853bdd8f1eb.png"><img src="https://user-images.githubusercontent.com/10785634/114496785-45ab3980-9c53-11eb-936b-1853bdd8f1eb.png" alt="image" style="max-width: 100%;"></a><br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/10785634/114496795-4ba11a80-9c53-11eb-9674-843ec1605fe9.png"><img src="https://user-images.githubusercontent.com/10785634/114496795-4ba11a80-9c53-11eb-9674-843ec1605fe9.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">Is the problem of threejs's GLTFLoader?</p>
<p dir="auto"><strong>To Reproduce</strong></p>
<p dir="auto">Steps to reproduce the behavior:</p>
<ol dir="auto">
<li>Go to <a href="https://threejs.org/editor/" rel="nofollow">https://threejs.org/editor/</a></li>
<li>Click on File -&gt; Import, chose the glb file, and add a AmbientLight</li>
<li>See error</li>
</ol>
<p dir="auto"><em><strong>Code</strong></em></p>
<div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="let loader=new GLTFLoader()
loader.load('./sofa.glb',gltf=&gt;{
  scene.add(gltf.scene)
  let sofa=gltf.scene.children[0]
  // sofa.geometry.attributes.uv2.copy(sofa.geometry.attributes.uv)
})"><pre class="notranslate"><span class="pl-k">let</span> <span class="pl-s1">loader</span><span class="pl-c1">=</span><span class="pl-k">new</span> <span class="pl-v">GLTFLoader</span><span class="pl-kos">(</span><span class="pl-kos">)</span>
<span class="pl-s1">loader</span><span class="pl-kos">.</span><span class="pl-en">load</span><span class="pl-kos">(</span><span class="pl-s">'./sofa.glb'</span><span class="pl-kos">,</span><span class="pl-s1">gltf</span><span class="pl-c1">=&gt;</span><span class="pl-kos">{</span>
  <span class="pl-s1">scene</span><span class="pl-kos">.</span><span class="pl-en">add</span><span class="pl-kos">(</span><span class="pl-s1">gltf</span><span class="pl-kos">.</span><span class="pl-c1">scene</span><span class="pl-kos">)</span>
  <span class="pl-k">let</span> <span class="pl-s1">sofa</span><span class="pl-c1">=</span><span class="pl-s1">gltf</span><span class="pl-kos">.</span><span class="pl-c1">scene</span><span class="pl-kos">.</span><span class="pl-c1">children</span><span class="pl-kos">[</span><span class="pl-c1">0</span><span class="pl-kos">]</span>
  <span class="pl-c">// sofa.geometry.attributes.uv2.copy(sofa.geometry.attributes.uv)</span>
<span class="pl-kos">}</span><span class="pl-kos">)</span></pre></div>
<p dir="auto"><em><strong>Live example</strong></em></p>
<p dir="auto">See above metioned gltf viewer and load the glb model.</p>
<p dir="auto"><strong>Expected behavior</strong></p>
<p dir="auto">Display correct aoMap with this glb model like in <a href="https://sandbox.babylonjs.com/" rel="nofollow">https://sandbox.babylonjs.com/</a> , <a href="https://playcanvas.com/viewer" rel="nofollow">https://playcanvas.com/viewer</a> and Win10 3D Viewer.</p>
<p dir="auto"><strong>Screenshots</strong></p>
<p dir="auto">See above.</p>
<p dir="auto"><strong>Platform:</strong></p>
<ul dir="auto">
<li>Device: [Desktop]</li>
<li>OS: [Windows]</li>
<li>Browser: [Chrome]</li>
<li>Three.js version: [r127]</li>
</ul>