问题
Is it possible to apply texture to mesh without specifying UV's in geometry in three.js ?
回答1:
There are classes such as THREE.CubeGeometry, THREE.SphereGeometry, etc. that automatically generate the UV coordinates for you. However, if you are creating your own geometry from scratch (i.e., specifying vertex locations, creating faces, etc.) then the answer is no. Either you need to set the UV coordinates manually when creating the geometry, or you need to write a custom shader which determines the UV coordinates for any given point. Think about it this way: if you don't specify UV coordinates, the points on your geometry have no idea which point on your texture they should display.
来源:https://stackoverflow.com/questions/18972672/how-to-apply-texture-to-mesh-without-specifying-uvs-in-geometry-using-three-js