{
Bitmap *real_dst_bitmap = (dst_bitmap == window ? backbuffer : dst_bitmap);
SDL_Rect src_rect, dst_rect;
{
Bitmap *real_dst_bitmap = (dst_bitmap == window ? backbuffer : dst_bitmap);
SDL_Rect src_rect, dst_rect;
src_bitmap->surface_masked : src_bitmap->surface),
&src_rect, real_dst_bitmap->surface, &dst_rect);
src_bitmap->surface_masked : src_bitmap->surface),
&src_rect, real_dst_bitmap->surface, &dst_rect);
}
inline void SDLFillRectangle(Bitmap *dst_bitmap, int x, int y,
}
inline void SDLFillRectangle(Bitmap *dst_bitmap, int x, int y,
- unsigned int color_r = (color >> 16) && 0xff;
- unsigned int color_g = (color >> 8) && 0xff;
- unsigned int color_b = (color >> 0) && 0xff;
+#if 0
+ unsigned int color_r = (color >> 16) & 0xff;
+ unsigned int color_g = (color >> 8) & 0xff;
+ unsigned int color_b = (color >> 0) & 0xff;
+#endif
SDL_FillRect(real_dst_bitmap->surface, &rect,
SDL_MapRGB(real_dst_bitmap->surface->format,
color_r, color_g, color_b));
SDL_FillRect(real_dst_bitmap->surface, &rect,
SDL_MapRGB(real_dst_bitmap->surface->format,
color_r, color_g, color_b));
if (dst_bitmap == window)
SDL_UpdateRect(backbuffer->surface, x, y, width, height);
}
inline void SDLDrawSimpleLine(Bitmap *dst_bitmap, int from_x, int from_y,
if (dst_bitmap == window)
SDL_UpdateRect(backbuffer->surface, x, y, width, height);
}
inline void SDLDrawSimpleLine(Bitmap *dst_bitmap, int from_x, int from_y,
unsigned int color_r = (color >> 16) & 0xff;
unsigned int color_g = (color >> 8) & 0xff;
unsigned int color_b = (color >> 0) & 0xff;
unsigned int color_r = (color >> 16) & 0xff;
unsigned int color_g = (color >> 8) & 0xff;
unsigned int color_b = (color >> 0) & 0xff;
SDL_FillRect(surface, &rect,
SDL_MapRGB(surface->format, color_r, color_g, color_b));
SDL_FillRect(surface, &rect,
SDL_MapRGB(surface->format, color_r, color_g, color_b));
}
inline void SDLDrawLine(Bitmap *dst_bitmap, int from_x, int from_y,
}
inline void SDLDrawLine(Bitmap *dst_bitmap, int from_x, int from_y,