Download

Automatic Material Scaling

Hi All,

I’m trying to figure out why it is that certain meshes automatically scale a material applied to them to fit the size of the mesh, while others do not. What I’m trying to do is display an image on a television. In the screenshot I’ve attached, I’ve also included a couple picture frame assets from one of Unreal’s demo scenes, scaled to various sizes. I created a simple material using the Pietrangelo cup photo as a texture and applied it to all the objects. As you can see, the material scales to fit the frame in all of the picture frame meshes, but does not on the TV screen mesh. I know I can manually adjust it using a texture coordinate node, but I’m curious as to why this happens in the first place.

Thanks in advance for any help

Hi, it depends on how the meshes are UV unwrapped. Basically textures are 2 dimensional while the mesh is 3 dimensional. Therefore you need to flatten (UV unwrap) the mesh geometry onto a 2d plane.

You can visualize how the mesh is UV unwrapped when you open it up in the editor https://docs.unrealengine.com/en-US/Engine/Content/Types/StaticMeshes/HowTo/UVChannels/index.html under “Visualizing a UV Channel”. If you want to change how the mesh is UV unwrapped, then I do that in an external program (blender).