             for v in faces
                 switch v.length
                     when 3
-                        push_face3(v...)
+                        if has_local_colors
+                            push_face3(v...)
+                        else:
+                            push_face3_with_color(v...)
                     when 4
                         push_face4(v...)
                     when 5


            push_face3 = (a, b, c) =>
                geometry.faces.push(new THREE.Face3(a-1, b-1, c-1))
                #geometry.faces.push(new THREE.Face3(b-1, a-1, c-1))   # both sides of faces, so material is visible from inside -- but makes some things like look really crappy; disable.  Better to just set a property of the material/light, which fixes the same problem.

            # *polyogonal* faces defined by 4 vertices (squares), which for THREE.js we must define using two triangles


                m = myobj.material[mk]

                if has_local_colors
                    material =  new THREE.MeshPhongMaterial
                        shininess   : "1"
                        wireframe   : false
                        transparent : m.opacity < 1
                    material.color.setRGB(m.color[0],    m.color[1],    m.color[2])
                else
                    material =  new THREE.MeshPhongMaterial
                        shininess   : "1"
                        wireframe   : false
                        transparent : m.opacity < 1
                        vertexColors: THREE.FaceColors

                material.specular.setRGB(m.specular[0], m.specular[1], m.specular[2])
                material.opacity = m.opacity

