This is new wiki software and old wiki content. It's a work in progress!
Here's the explanation.
Be gentle, report bugs, leave feedback on pages, or just edit them yourself! Thanks!

SDL Wiki


typedef enum { /'''' \brief The default mode, a binarized alpha cutoff of 1.


int SDL_SetWindowShape(SDL_Window *window,SDL_Surface *shape,SDL_WindowShapeMode *shape_mode);

Function Parameters


The shaped window whose parameters should be set.


A surface encoding the desired shape for the window.


The parameters to set for the shaped window.

Return Value

Return 0 on success, SDL_INVALID_SHAPE_ARGUMENT on an invalid shape argument, or SDL_NONSHAPEABLE_WINDOW if the SDL_Window given does not reference a valid shaped window.


/ ShapeModeDefault, /' \brief A binarized alpha cutoff with a given integer value. / ShapeModeBinarizeAlpha, /' \brief A binarized alpha cutoff with a given integer value, but with the opposite comparison. / ShapeModeReverseBinarizeAlpha, /' \brief A color key is applied. ''/ ShapeModeColorKey } WindowShapeMode;

  1. define SDL_SHAPEMODEALPHA(mode) (mode == ShapeModeDefault || mode ==

ShapeModeBinarizeAlpha || mode == ShapeModeReverseBinarizeAlpha)

/' \brief A union containing parameters for shaped windows./ typedef union { /' \brief A cutoff alpha value for binarization of the window shape's alpha channel./ Uint8 binarizationCutoff; SDL_Color colorKey; } SDL_WindowShapeParams;

/' \brief A struct that tags the SDL_WindowShapeParams union with an enum describing the type of its contents./ typedef struct SDL_WindowShapeMode { /' \brief The mode of these window-shape parameters./ WindowShapeMode mode; /' \brief Window-shape parameters./ SDL_WindowShapeParams parameters; } SDL_WindowShapeMode;



[ edit | delete | history | feedback | raw ]

[ front page | index | search | recent changes | git repo | offline html ]

All wiki content is licensed under Creative Commons Attribution 4.0 International (CC BY 4.0).
Wiki powered by ghwikipp.