using SFML.Graphics;
using SFML.Window;
class Program
{
public static void Main()
{
RenderWindow renderWindow = new RenderWindow(new VideoMode(800, 600, 32), "Minimal Example", Styles.Default);
RenderTexture renderTexture = new RenderTexture(800, 600);
Sprite sprite;
RectangleShape rectangle = new RectangleShape(new Vector2f(100, 100));
rectangle.OutlineThickness = 5;
rectangle.OutlineColor = Color.Black;
renderTexture.Clear(Color.White);
rectangle.FillColor = Color.Yellow;
rectangle.Position = new Vector2f(0, 0);
renderTexture.Draw(rectangle);
rectangle.FillColor = Color.Red;
rectangle.Position = new Vector2f(350, 150);
renderTexture.Draw(rectangle);
rectangle.FillColor = Color.Blue;
rectangle.Origin = new Vector2f(100, 100);
rectangle.Position = new Vector2f(799, 599);
renderTexture.Draw(rectangle);
renderTexture.Display();
sprite = new Sprite(renderTexture.Texture);
sprite.Position = new Vector2f(0, 0);
renderWindow.Draw(sprite);
renderWindow.Display();
renderWindow.DispatchEvents();
while (!Keyboard.IsKeyPressed(Keyboard.Key.Return))
;
}
}