diff options
| author | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2024-02-19 20:43:39 -0500 |
|---|---|---|
| committer | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2024-02-19 20:43:39 -0500 |
| commit | 563d44c4a3cabeddc442bfe8377bc2cdfde4a6dd (patch) | |
| tree | 484a7c958dfe782ec7800fa2a3b0b828af46bae2 /screen.c | |
| parent | 9d4fbd735e60c8bfd8360a9cdcfc1c757a6cced1 (diff) | |
Fixed screen flicker and added ball speedup
Diffstat (limited to 'screen.c')
| -rw-r--r-- | screen.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -35,7 +35,7 @@ bool InitScreen ( void ) { } gScreenSurface = SDL_GetWindowSurface( gWindow ); - ClearScreen(); + SDL_FillRect( gScreenSurface, NULL, SDL_MapRGB( gScreenSurface->format, 0x00, 0x00, 0x00 ) ); ballSurface = LoadSurface( "ball.bmp" ); leftPaddleSurface = LoadSurface( "paddle.bmp" ); @@ -65,8 +65,3 @@ void Draw ( const struct moveable_t m, SDL_Surface * const surface ) { printf( "Error with draw! SDL Error: %s\n", SDL_GetError() ); } } - -void ClearScreen( void ) { - SDL_FillRect( gScreenSurface, NULL, SDL_MapRGB( gScreenSurface->format, 0x00, 0x00, 0x00 ) ); - SDL_UpdateWindowSurface( gWindow ); -} |
