Updated testeyes.c. It now shows some kind of gibberish Missingno-type picture somewhere on the screen and, possibly, hangs the window system. On the upside, the Missingno is definitely a non-rectangular window.
This commit is contained in:
parent
72dcc2f873
commit
7e104c5469
1 changed files with 2 additions and 2 deletions
|
@ -130,7 +130,7 @@ int main(int argc,char** argv) {
|
||||||
exit(-1);
|
exit(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_Window *window = SDL_CreateShapedWindow("Big Brother is watching you.",eyes_x_hot,eyes_y_hot,eyes_width,eyes_height,SDL_WINDOW_RESIZABLE);
|
SDL_Window *window = SDL_CreateShapedWindow("Big Brother is watching you.",eyes_x_hot,eyes_y_hot,eyes_width,eyes_height,SDL_WINDOW_RESIZABLE | SDL_WINDOW_SHOWN);
|
||||||
if(window == NULL) {
|
if(window == NULL) {
|
||||||
SDL_VideoQuit();
|
SDL_VideoQuit();
|
||||||
printf("Could not create shaped window for eyes.\n");
|
printf("Could not create shaped window for eyes.\n");
|
||||||
|
@ -169,7 +169,7 @@ int main(int argc,char** argv) {
|
||||||
}
|
}
|
||||||
if(SDL_MUSTLOCK(eyes))
|
if(SDL_MUSTLOCK(eyes))
|
||||||
SDL_UnlockSurface(eyes);
|
SDL_UnlockSurface(eyes);
|
||||||
SDL_Texture *eyes_texture = SDL_CreateTextureFromSurface(SDL_PIXELFORMAT_ARGB4444,eyes);
|
SDL_Texture *eyes_texture = SDL_CreateTextureFromSurface(0,eyes);
|
||||||
if(eyes_texture == NULL) {
|
if(eyes_texture == NULL) {
|
||||||
SDL_FreeSurface(eyes);
|
SDL_FreeSurface(eyes);
|
||||||
SDL_DestroyRenderer(window);
|
SDL_DestroyRenderer(window);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue