Mercurial > sdl-ios-xcode
comparison src/video/fbcon/SDL_fbvideo.h @ 1668:4da1ee79c9af SDL-1.3
more tweaking indent options
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 29 May 2006 04:04:35 +0000 |
parents | 782fd950bd46 |
children |
comparison
equal
deleted
inserted
replaced
1667:1fddae038bc8 | 1668:4da1ee79c9af |
---|---|
141 #ifndef FB_ACCEL_3DFX_BANSHEE | 141 #ifndef FB_ACCEL_3DFX_BANSHEE |
142 #define FB_ACCEL_3DFX_BANSHEE 31 /* 3Dfx Banshee */ | 142 #define FB_ACCEL_3DFX_BANSHEE 31 /* 3Dfx Banshee */ |
143 #endif | 143 #endif |
144 | 144 |
145 /* These functions are defined in SDL_fbvideo.c */ | 145 /* These functions are defined in SDL_fbvideo.c */ |
146 extern void FB_SavePaletteTo (_THIS, int palette_len, __u16 * area); | 146 extern void FB_SavePaletteTo(_THIS, int palette_len, __u16 * area); |
147 extern void FB_RestorePaletteFrom (_THIS, int palette_len, __u16 * area); | 147 extern void FB_RestorePaletteFrom(_THIS, int palette_len, __u16 * area); |
148 | 148 |
149 /* These are utility functions for working with video surfaces */ | 149 /* These are utility functions for working with video surfaces */ |
150 | 150 |
151 static __inline__ void | 151 static __inline__ void |
152 FB_AddBusySurface (SDL_Surface * surface) | 152 FB_AddBusySurface(SDL_Surface * surface) |
153 { | 153 { |
154 ((vidmem_bucket *) surface->hwdata)->dirty = 1; | 154 ((vidmem_bucket *) surface->hwdata)->dirty = 1; |
155 } | 155 } |
156 | 156 |
157 static __inline__ int | 157 static __inline__ int |
158 FB_IsSurfaceBusy (SDL_Surface * surface) | 158 FB_IsSurfaceBusy(SDL_Surface * surface) |
159 { | 159 { |
160 return ((vidmem_bucket *) surface->hwdata)->dirty; | 160 return ((vidmem_bucket *) surface->hwdata)->dirty; |
161 } | 161 } |
162 | 162 |
163 static __inline__ void | 163 static __inline__ void |
164 FB_WaitBusySurfaces (_THIS) | 164 FB_WaitBusySurfaces(_THIS) |
165 { | 165 { |
166 vidmem_bucket *bucket; | 166 vidmem_bucket *bucket; |
167 | 167 |
168 /* Wait for graphic operations to complete */ | 168 /* Wait for graphic operations to complete */ |
169 wait_idle (this); | 169 wait_idle(this); |
170 | 170 |
171 /* Clear all surface dirty bits */ | 171 /* Clear all surface dirty bits */ |
172 for (bucket = &surfaces; bucket; bucket = bucket->next) { | 172 for (bucket = &surfaces; bucket; bucket = bucket->next) { |
173 bucket->dirty = 0; | 173 bucket->dirty = 0; |
174 } | 174 } |
175 } | 175 } |
176 | 176 |
177 static __inline__ void | 177 static __inline__ void |
178 FB_dst_to_xy (_THIS, SDL_Surface * dst, int *x, int *y) | 178 FB_dst_to_xy(_THIS, SDL_Surface * dst, int *x, int *y) |
179 { | 179 { |
180 *x = (long) ((char *) dst->pixels - mapped_mem) % this->screen->pitch; | 180 *x = (long) ((char *) dst->pixels - mapped_mem) % this->screen->pitch; |
181 *y = (long) ((char *) dst->pixels - mapped_mem) / this->screen->pitch; | 181 *y = (long) ((char *) dst->pixels - mapped_mem) / this->screen->pitch; |
182 if (dst == this->screen) { | 182 if (dst == this->screen) { |
183 *x += this->offset_x; | 183 *x += this->offset_x; |