Image stretch out in Unity
Posted: 29 May 2020, 14:25
Hi,
My problem is that a picture I have put in a Path as an ImageBrush stretch out in Unity instead of following the value UniformToFill. I tested on blend, it works perfectly but once I test on unity, the picture stretch out (but not the same way it would have stretch with the Fill value)
On blend:

On unity:

Any idea?
My problem is that a picture I have put in a Path as an ImageBrush stretch out in Unity instead of following the value UniformToFill. I tested on blend, it works perfectly but once I test on unity, the picture stretch out (but not the same way it would have stretch with the Fill value)
Code: Select all
<Grid Grid.Row="0" Grid.RowSpan="3">
<Path Margin="0 0 0 0" Data="M-0.5,-0.5 L-0.5,449.5 399.5,449.5 304.5,-0.5 z">
<Path.Fill>
<ImageBrush ImageSource="./../Images/example.jpg" Stretch="UniformToFill"/>
</Path.Fill>
</Path>
</Grid>

On unity:

Any idea?