Constructs a dsdl2.Surface from a vanilla SDL_Surface* from bindbc-sdl
Constructs a blank RGB(A) dsdl2.Surface with a set width, height, and dsdl2.PixelFormat that wraps SDL_CreateRGBSurface
Constructs an RGB(A) dsdl2.Surface from an array of pixels
Constructs a blank indexed palette-using dsdl2.Surface with a set width, height, and index bit depth, which wraps SDL_CreateRGBSurface
Constructs a blank indexed palette-using dsdl2.Surface from an array of pixels
Wraps SDL_GetSurfaceAlphaMod which gets the alpha multiplier of the dsdl2.Surface
Wraps SDL_SetSurfaceAlphaMod which sets the alpha multiplier of the dsdl2.Surface
Wraps SDL_GetSurfaceBlendMode which gets the dsdl2.Surface's dsdl2.BlendMode defining blitting
Wraps SDL_SetSurfaceBlendMode which sets the dsdl2.Surface's dsdl2.BlendMode defining blitting
Wraps SDL_BlitSurface which blits/draws a dsdl2.Surface on top of the dsdl2.Surface at a specific point as the top-left point of the drawn dsdl2.Surface without any scaling done
Wraps SDL_BlitSurface which blits/draws a dsdl2.Surface on top of the dsdl2.Surface at a specific point as the top-left point of the drawn dsdl2.Surface without any scaling done
Wraps SDL_BlitScaled which blits/draws a dsdl2.Surface on top of the dsdl2.Surface at a specific point as the top-left point of the drawn dsdl2.Surface with scaling
Wraps SDL_BlitScaled which blits/draws a dsdl2.Surface on top of the dsdl2.Surface at a specific point as the top-left point of the drawn dsdl2.Surface with scaling
Gets the internal pixel buffer of the dsdl2.Surface
Wraps SDL_GetClipRect which gets the clipping dsdl2.Rect of the dsdl2.Surface
Wraps SDL_SetClipRect which sets the clipping dsdl2.Rect of the dsdl2.Surface
Acts as SDL_SetClipRect(surface, NULL) which removes the clipping dsdl2.Rect of the dsdl2.Surface
Wraps SDL_SetClipRect which sets or removes the clipping dsdl2.Rect of the dsdl2.Surface
Wraps SDL_GetColorKey which gets the color key used by the dsdl2.Surface for transparency
Wraps SDL_SetColorKey which sets the color key used for the dsdl2.Surface making pixels of the same color transparent
Wraps SDL_SetColorKey which sets the color key used for the dsdl2.Surface making pixels of the same color transparent
Acts as SDL_SetColorKey(surface, NULL) which disables color-keying
Wraps SDL_SetColorKey which sets or removes the color key used for the dsdl2.Surface making pixels of the same color transparent
Wraps SDL_GetSurfaceColorMod which gets the color multipliers of the dsdl2.Surface
Wraps SDL_SetSurfaceColorMod which sets the color multipliers of the dsdl2.Surface
Wraps SDL_ConvertPixels which converts the dsdl2.Surface from its RGB(A) dsdl2.PixelFormat to another dsdl2.Surface with a different RGB(A) dsdl2.PixelFormat
Acts as SDL_FillRect(surface, NULL) which fills the entire dsdl2.Surface with a pixel value
Acts as SDL_FillRect(surface, NULL) which fills the entire dsdl2.Surface with a dsdl2.Color value
Wraps SDL_FillRect which draws a filled rectangle in the dsdl2.Surface with specifying a pixel color value
Wraps SDL_FillRect which draws a filled rectangle in the dsdl2.Surface with specifying a dsdl2.Color value
Wraps SDL_FillRects which draws multiple filled rectangles in the dsdl2.Surface with specifying a pixel color value
Wraps SDL_FillRects which draws multiple filled rectangles in the dsdl2.Surface with specifying a dsdl2.Color value
Gets the pixel color in the dsdl2.Surface at the given coordinate
Gets the pixel value in the dsdl2.Surface at the given coordinate
Wraps SDL_HasColorKey (from SDL 2.0.9) which checks whether the dsdl2.Surface has a color key for transparency
Gets the height of the dsdl2.Surface in pixels
Gets the color and alpha multipliers of the dsdl2.Surface that wraps SDL_GetSurfaceColorMod and SDL_GetSurfaceAlphaMod
Sets the color and alpha multipliers of the dsdl2.Surface that wraps SDL_SetSurfaceColorMod and SDL_SetSurfaceAlphaMod
Equality operator overload
Gets the used color palette of the dsdl2.Surface
Sets the color palette of the dsdl2.Surface
Gets the pitch of the dsdl2.Surface in bytes (multiple of bytes for each line/row)
Gets the dsdl2.PixelFormat of the dsdl2.Surface
Sets the pixel color in the dsdl2.Surface at the given coordinate
Sets the pixel value in the dsdl2.Surface at the given coordinate
Gets the size of the dsdl2.Surface in pixels
Gets the hash of the dsdl2.Surface
Formats the dsdl2.Surface into its construction representation: "dsdl2.PixelFormat([<bytes>], [<width>, <height>], <pitch>, <pixelFormat>)"
Gets the width of the dsdl2.Surface in pixels
Internal SDL_Surface pointer
auto surface = new dsdl2.Surface([100, 100], dsdl2.PixelFormat.rgba8888); surface.fill(dsdl2.Color(24, 24, 24)); surface.fillRect(dsdl2.Rect(25, 25, 50, 50), dsdl2.Color(42, 42, 42)); assert(surface.getAt([0, 0]) == dsdl2.Color(24, 24, 24)); assert(surface.getAt([50, 50]) == dsdl2.Color(42, 42, 42));
D class that wraps SDL_Surface storing a 2D image in the RAM
dsdl2.Surface stores a 2D image out of pixels with a width and height, where each pixel stored in the RAM according to its defined dsdl2.PixelFormat.