# Prevent Texture stretching on scaling with rotation

**URL:** <https://forums.unrealengine.com/t/prevent-texture-stretching-on-scaling-with-rotation/380966>\
**Category:** Rendering\
**Tags:** rotating, unreal-engine, scaling, question\
**Created:** [January 5, 2017, 10:04am UTC](https://forums.unrealengine.com/t/prevent-texture-stretching-on-scaling-with-rotation/380966 "2017-01-05T10:04:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Unavi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Unavi](https://forums.unrealengine.com/u/Unavi)\
**Post date:** [January 5, 2017, 10:04am UTC](https://forums.unrealengine.com/t/prevent-texture-stretching-on-scaling-with-rotation/380966/1 "2017-01-05T10:04:53Z")

</div>

I would like to create a Material which increases tilling when I scale it, but still moves in object space and stays as it is when I rotate it. I masked out the xyz axis with **PixelNormalWS** and scaled the UV’s depending on **ObejctScale**. The Problem I am having right now is that **PixelNormalWS** obviously gets me the world rotation of that pixel, which is a problem on rotating the mesh. Is there a way to calculate/get the pixel normal in local space? Or is there a better way all together?

Preview:

![Cubes with texture bug] [1]

Material:

 ![120898-capture2.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/5/1/65122b312b9dd9932a748023bf8ea63da62ac6ed.png)

Download Rar with uassets

[Download Rar][2]
