<p dir="auto">A project in Blender -</p>
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9849922/17363051/01348db6-5981-11e6-8579-c17390e586d4.png"><img src="https://cloud.githubusercontent.com/assets/9849922/17363051/01348db6-5981-11e6-8579-c17390e586d4.png" alt="_013" style="max-width: 100%;"></a><br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9849922/17363063/08f12550-5981-11e6-9387-b68c74fa8d47.png"><img src="https://cloud.githubusercontent.com/assets/9849922/17363063/08f12550-5981-11e6-9387-b68c74fa8d47.png" alt="_014" style="max-width: 100%;"></a></p>
<p dir="auto">three editor (note the arrows to the active camera) -<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9849922/17363107/46069704-5981-11e6-81b2-ea6621e7ea4f.png"><img src="https://cloud.githubusercontent.com/assets/9849922/17363107/46069704-5981-11e6-81b2-ea6621e7ea4f.png" alt="_015" style="max-width: 100%;"></a></p>
<p dir="auto">the render shows a black screen on that picture is not attached.<br>
Turn around 180 degrees (note the arrows to the active camera) -</p>
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9849922/17363193/9357fcbe-5981-11e6-97da-244440fa8314.png"><img src="https://cloud.githubusercontent.com/assets/9849922/17363193/9357fcbe-5981-11e6-97da-244440fa8314.png" alt="_016" style="max-width: 100%;"></a><br>
The source of light from above, lighting is the side.</p>
<p dir="auto">Is it possible to fix this and how?</p>
<p dir="auto">Geometry's fromBufferGeometry() exports duplicated vertices and colors.</p>
<p dir="auto">Code to reproduce:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="var box = new THREE.BoxGeometry(1,1,1);
var bufferBox = new THREE.BufferGeometry();
bufferBox.fromGeometry(box);

var newBox = new THREE.Geometry();
newBox.fromBufferGeometry(bufferBox);"><pre class="notranslate"><code class="notranslate">var box = new THREE.BoxGeometry(1,1,1);
var bufferBox = new THREE.BufferGeometry();
bufferBox.fromGeometry(box);

var newBox = new THREE.Geometry();
newBox.fromBufferGeometry(bufferBox);
</code></pre></div>
<p dir="auto">Result:<br>
box : {vertices: Array(8), colors: Array(0)}<br>
newBox : {vertices: Array(36), colors: Array(36)}</p>
<p dir="auto">If you see useful, we have written a basic method to remove the vertices and fix the vertex index in the faces:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="function clearDuplicateVertices(geometry) {
        //store the vertex index changes
        var data = [];
        var vertices = [];
        var faces = [];

        //vertices
        for (var v = 0; v &lt; geometry.vertices.length; v++) {
            var vertex = geometry.vertices[v];

            //see if we have that vertex already
            var newIndex = -1;
            for (var i = 0; i &lt; vertices.length; i++) {
                if (vertices[i].equals(vertex))
                {
                    newIndex = i;
                    break;
                }
            }

            if (newIndex &gt; -1)
            {
                data.push({oldIndex: v, newIndex: newIndex});
            } else
            {
                vertices.push(vertex);
                data.push({oldIndex: v, newIndex: vertices.length - 1});
            }
        }

        //faces
        for (var f = 0; f &lt; geometry.faces.length; f++) {
            var currentFace = geometry.faces[f];

            var a = currentFace.a;
            var b = currentFace.b;
            var c = currentFace.c;
            for (var i = 0; i &lt; data.length; i++) {
                var currentData = data[i];

                if (a === currentData.oldIndex) {
                    a = currentData.newIndex;
                }

                if (b === currentData.oldIndex) {
                    b = currentData.newIndex;
                }

                if (c === currentData.oldIndex) {
                    c = currentData.newIndex;
                }
            }
            faces.push(new THREE.Face3(a, b, c));
        }

        //copy
        var geo = new THREE.Geometry();
        geo.vertices = vertices;
        geo.faces = faces;
        geo.computeFaceNormals();
        return geo;
    }"><pre class="notranslate"><code class="notranslate">function clearDuplicateVertices(geometry) {
        //store the vertex index changes
        var data = [];
        var vertices = [];
        var faces = [];

        //vertices
        for (var v = 0; v &lt; geometry.vertices.length; v++) {
            var vertex = geometry.vertices[v];

            //see if we have that vertex already
            var newIndex = -1;
            for (var i = 0; i &lt; vertices.length; i++) {
                if (vertices[i].equals(vertex))
                {
                    newIndex = i;
                    break;
                }
            }

            if (newIndex &gt; -1)
            {
                data.push({oldIndex: v, newIndex: newIndex});
            } else
            {
                vertices.push(vertex);
                data.push({oldIndex: v, newIndex: vertices.length - 1});
            }
        }

        //faces
        for (var f = 0; f &lt; geometry.faces.length; f++) {
            var currentFace = geometry.faces[f];

            var a = currentFace.a;
            var b = currentFace.b;
            var c = currentFace.c;
            for (var i = 0; i &lt; data.length; i++) {
                var currentData = data[i];

                if (a === currentData.oldIndex) {
                    a = currentData.newIndex;
                }

                if (b === currentData.oldIndex) {
                    b = currentData.newIndex;
                }

                if (c === currentData.oldIndex) {
                    c = currentData.newIndex;
                }
            }
            faces.push(new THREE.Face3(a, b, c));
        }

        //copy
        var geo = new THREE.Geometry();
        geo.vertices = vertices;
        geo.faces = faces;
        geo.computeFaceNormals();
        return geo;
    }
</code></pre></div>
<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=""> r96</li>
</ul>