Welcome,
I want write program to screen capture. Im was trying to this:
sf::Image oknoAplikacji; sf::Image zrzutEkranu = oknoAplikacji.Capture();
zrzutEkranu.SaveToFile( "zrzut-ekranu.png" );
But there's no .capture method.
I tryied to use SFML 2.5.1 and SFML 1.6
I did it but
there is an error: Failed to create texture, invalid size (0x0) and Failed to save image "screen.png"
sf::RenderWindow window;
sf::Image image;
image = window.capture();
image.saveToFile( "screen.png" );