ed0caeeaef
The sdl2 package is forked from upstream Alpine and: 1) adds directfb video support 2) adds a patch to work around a compile issue when directfb is enabled
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
diff --git a/src/video/directfb/SDL_DirectFB_shape.c b/src/video/directfb/SDL_DirectFB_shape.c
|
|
index 3239e30..e3d4dcd 100644
|
|
--- a/src/video/directfb/SDL_DirectFB_shape.c
|
|
+++ b/src/video/directfb/SDL_DirectFB_shape.c
|
|
@@ -37,18 +37,20 @@ DirectFB_CreateShapedWindow(const char *title,unsigned int x,unsigned int y,unsi
|
|
SDL_WindowShaper*
|
|
DirectFB_CreateShaper(SDL_Window* window) {
|
|
SDL_WindowShaper* result = NULL;
|
|
-
|
|
+ SDL_ShapeData* data = NULL;
|
|
+ int resized_properly = 0;
|
|
+
|
|
result = malloc(sizeof(SDL_WindowShaper));
|
|
result->window = window;
|
|
result->mode.mode = ShapeModeDefault;
|
|
result->mode.parameters.binarizationCutoff = 1;
|
|
result->userx = result->usery = 0;
|
|
- SDL_ShapeData* data = SDL_malloc(sizeof(SDL_ShapeData));
|
|
result->driverdata = data;
|
|
data->surface = NULL;
|
|
window->shaper = result;
|
|
- int resized_properly = DirectFB_ResizeWindowShape(window);
|
|
SDL_assert(resized_properly == 0);
|
|
+ data = SDL_malloc(sizeof(SDL_ShapeData));
|
|
+ resized_properly = DirectFB_ResizeWindowShape(window);
|
|
|
|
return result;
|
|
}
|