Skip to content

Commit

Permalink
iOS: Fixed compiling template on C89 compilers.
Browse files Browse the repository at this point in the history
  • Loading branch information
philippwiesemann committed Mar 19, 2017
1 parent 34a2a46 commit 6bd8763
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Xcode-iOS/Template/SDL iOS Application/main.c
Expand Up @@ -5,6 +5,8 @@
*/

#include "SDL.h"
#include <stdio.h>
#include <stdlib.h>
#include <time.h>

#define SCREEN_WIDTH 320
Expand All @@ -20,14 +22,14 @@ void
render(SDL_Renderer *renderer)
{

SDL_Rect rect;
Uint8 r, g, b;

/* Clear the screen */
SDL_SetRenderDrawColor(renderer, 0, 0, 0, 255);
SDL_RenderClear(renderer);

/* Come up with a random rectangle */
SDL_Rect rect;
rect.w = randomInt(64, 128);
rect.h = randomInt(64, 128);
rect.x = randomInt(0, SCREEN_WIDTH);
Expand Down

0 comments on commit 6bd8763

Please sign in to comment.