当前位置:网站首页>UE4 material UV texture does not stretch with model scale

UE4 material UV texture does not stretch with model scale

2022-06-29 09:30:00 Deveuper

Official document tutorial : link

WorldAlignedTexture

WorldAlignedTexture( Globally consistent texture ) The tiling texture() function is used to tile a texture on an object surface in global space , This tiling is independent of the size or rotation of the object .

This function allows you to specify the direction in which the texture is projected , And by global units ( Not the percentage of texture size ) Make a proportional adjustment .

Because this function tiles the texture in global space , So we need to pay attention , Any animated object that handles textures in this way will have textures " floating ", That is, the texture remains in its original position , The object slides under it .

 

project

explain

 

Input

 

 

Texture objects ( Texture objects )(TextureObject (Texture Object))

Receive the texture to be tiled in global space .

Texture size ( vector 3)(TextureSize (Vector3))

Texture size , With X、Y and Z Global units on the axis .

Global position ( vector 3)(WorldPosition (Vector3))

Provide 3D The start point offset of the texture in global space .

Export floating point 4( Static Boolean )(ExportFloat 4 (StaticBool))

Whether to use the alpha channel of the incoming texture . The default value is  false.

Global space normals ( vector 3)(World Space Normal (Vector3))

Allows you to specify the normal direction of the up axis of global space , So as to rotate the coordinates used by this function . The default value is 0,0,1, namely , Up Z.

Projected transition contrast ( vector 3)(ProjectionTansitionContrast (Vector3))

stay X、Y and Z When projected in the direction , This value controls the blended contrast produced when two projection planes intersect .

 

Output

 

 

XY texture (XY Texture)

In the global X and Y The result of projecting the texture in the direction .

Z texture (Z Texture)

In the global Z The result of projecting the texture in the direction .

XYZ texture (XYZ Texture)

In the global X、Y and Z The result of projecting the texture in the direction .

 

WorldAlignedTexture( Globally consistent texture )

Please note that , Although the ground has rotated , But the texture is still consistent with the global coordinates .

原网站

版权声明
本文为[Deveuper]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/180/202206290831545130.html