comparison test/testvidinfo.c @ 482:6417071ba2e5

*** empty log message ***
author Sam Lantinga <slouken@libsdl.org>
date Sun, 01 Sep 2002 00:38:49 +0000
parents 92596bfe8446
children 32190cba6c40
comparison
equal deleted inserted replaced
481:c96e2137f9eb 482:6417071ba2e5
117 } 117 }
118 118
119 bmp = SDL_LoadBMP("sample.bmp"); 119 bmp = SDL_LoadBMP("sample.bmp");
120 if ( ! bmp ) { 120 if ( ! bmp ) {
121 printf("Couldn't load sample.bmp: %s\n", SDL_GetError()); 121 printf("Couldn't load sample.bmp: %s\n", SDL_GetError());
122 return; 122 return 0;
123 } 123 }
124 printf("Running freshly loaded blit test: %dx%d at %d bpp, flags: ", 124 printf("Running freshly loaded blit test: %dx%d at %d bpp, flags: ",
125 bmp->w, bmp->h, bmp->format->BitsPerPixel); 125 bmp->w, bmp->h, bmp->format->BitsPerPixel);
126 PrintFlags(bmp->flags); 126 PrintFlags(bmp->flags);
127 printf("\n"); 127 printf("\n");
138 tmp = bmp; 138 tmp = bmp;
139 bmp = SDL_DisplayFormat(bmp); 139 bmp = SDL_DisplayFormat(bmp);
140 SDL_FreeSurface(tmp); 140 SDL_FreeSurface(tmp);
141 if ( ! bmp ) { 141 if ( ! bmp ) {
142 printf("Couldn't convert sample.bmp: %s\n", SDL_GetError()); 142 printf("Couldn't convert sample.bmp: %s\n", SDL_GetError());
143 return; 143 return 0;
144 } 144 }
145 printf("Running display format blit test: %dx%d at %d bpp, flags: ", 145 printf("Running display format blit test: %dx%d at %d bpp, flags: ",
146 bmp->w, bmp->h, bmp->format->BitsPerPixel); 146 bmp->w, bmp->h, bmp->format->BitsPerPixel);
147 PrintFlags(bmp->flags); 147 PrintFlags(bmp->flags);
148 printf("\n"); 148 printf("\n");