So, this is obviously not my real app, but i managed to isolate it to this piece of code.
#include <SFML/Graphics.hpp>
#include <SFML/Window.hpp>
#include <SFML/System.hpp>
#include <cstdio>
int main()
{
long int W;
scanf("%d", &W);
const long int H = W;
sf::Texture texture;
sf::Sprite sprite;
if(!texture.create(W, H)) throw "ERR";
sf::Uint8 pixels[W*H*4];
texture.update(pixels);
sprite.setTexture(texture);
return 0;
}
In the actual program, I'm manipulating an array of pixels pixel-by-pixel.
I've tested for W=716 and lower values, and it presented the standard "Status 0" stuff at the end.
But for W=717 and larger values, a box pops up, where you can read:
"ProblemProject.exe stopped working
Windows is searching for a solution to the problem..."
and then another one saying:
"ProblemProject.exe stopped working
Windows is collecting information about the problem. This process might take several minutes..."
and finally one saying:
"ProblemProject.exe stopped working
A problem led to the program to stop working correctly. Windows will close the program and warn you if there is a possible solution."
I click a "Close program" button, and the Console presents the message:
"Process returned 255 (0xFF) execution time : 9.685 s
Press any key to continue."
I've tested the code for a full-window (red-coloured xd) rectangle shape and it worked fine for every value of W.
I'm using static (and static debug as well) versions of all the SFML 2.3.2 libraries (both with -s and -s-d i get the same thing), and using
CodeBlocks Release 13.12 rev 9501 (2013/12/25 19:25:45) gcc 4.7.1 Windows/unicode - 32 bit
I'm working on Windows10, and my GPU is NVIDIA GEFORCE GTX 950M.
Please help me, I'm almost certain it must be a begginer's issue, but I still couldn't find any related post.