I am trying to have a background that has a similar colour to this
I notice the the "dots" on the image you linked to are larger than 1 pixel; to achieve that effect, simply scale dedicate a GUI object specifically to render the background and scale it up with LayoutTransform or RenderTransform. Alternatively, adjust the uv values being passed into the shader prior to using them to calculate the index.
CodePudding user response:
If I'm not mistaken you need Gradient
You can use the following code
<Grid>
<Grid.Background>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
<GradientStop Color="Black" Offset="0" />
<GradientStop Color="White" Offset="1" />
</LinearGradientBrush>
</Grid.Background>
</Grid>