Hello, i noticed a very strange error when the sf::RenderTexture destructor is called.
Take a look at this example, the application crashes (on Visual Studio) with:
"Windows has triggered a breakpoint in "ApplicationName". This may be due to a corruption of the heap, which indicates a bug in "ApplicationName" or any of the DLLs it has loaded."
int main()
{
sf::RenderWindow window(sf::VideoMode(200, 200), "SFML works!");
sf::RenderTexture* renderTexture = new sf::RenderTexture();
renderTexture->create(32, 32);
//stuff
delete renderTexture;
while (window.isOpen())
{
window.clear();
window.display();
}
return 0;
}
But if before the destructor call i write for instance: 'window.clear()' or 'window.display()' there isn't any crash.