rolmodl
C++ API for the Simple Directmedia Library 2 (SDL2)
Namespaces | Classes | Typedefs | Enumerations | Functions
rolmodl Namespace Reference

Main namespace. More...

Namespaces

 blendMode
 rolmodl::BlendMode methods.
 
 detail
 Implementation details.
 
 geom
 Geometry structures.
 
 pixelfmt
 Pixel format management members.
 
 ren
 rolmodl::Ren -related members.
 
 sys
 System information functions and enums.
 
 win
 rolmodl::Win -related members.
 

Classes

struct  BorderSizes
 Window decoration (border) sizes snapshot. More...
 
struct  DstRectWH
 Rectangle specifying the destination rectangle for a rendering operation by its top left corner coordinates, width, and height. More...
 
struct  DstRectXY
 Rectangle specifying the destination rectangle for a rendering operation by its top left and bottom right corner coordinates. More...
 
struct  Flip
 Rendering flip configuration container. More...
 
struct  HatState
 
struct  Keysym
 
class  LockTex
 
class  Ren
 Renderer class that does not support rendering to texture. Use rolmodl::TexRen for rendering to texture support. More...
 
struct  RenScale
 Rendering scaling factors. More...
 
class  RenTex
 
struct  RGB
 RGB color type. No alpha component. More...
 
struct  RGBA
 RGBA color type. Has an alpha component. More...
 
struct  sdlexception
 Exception type containing an error code and the last SDL error at the moment of creation. More...
 
class  SDLString
 Container for SDL-owned strings that must be freed with SDL_free. More...
 
struct  SrcRectWH
 Rectangle specifying the source rectangle for a rendering operation by its top left corner coordinates, width, and height. More...
 
struct  SrcRectXY
 Rectangle specifying the source rectangle for a rendering operation by its top left and bottom right corner coordinates. More...
 
class  StaticTex
 
class  SWTex
 
class  SWTex_Base
 
class  SWTex_RLE
 
class  SWTex_RLELock
 
class  Tex
 
class  TexLock
 
class  TexRen
 Renderer class that supports rendering to texture. Use rolmodl::Ren if you do not need support for rendering to texture. More...
 
struct  TextureInfo
 
class  Win
 Window class for use with accelerated rendering (rolmodl::Ren). More...
 
class  Win_Base
 Common window class. Use rolmodl::Win for use with accelerated rendering (rolmodl::Ren) and rolmodl::Win_SW for use with software rendering (rolmodl::SWTex). More...
 
class  Win_SW
 

Typedefs

using Event = std::variant< event::Quit, event::User, event::Edit, event::Text, event::touch::Motion, event::touch::Up, event::touch::Down, event::key::Up, event::key::Down, event::mouse::button::Up, event::mouse::button::Down, event::mouse::Motion, event::mouse::Wheel, event::joystick::Axis, event::joystick::Ball, event::joystick::Hat, event::joystick::button::Up, event::joystick::button::Down, event::joystick::device::Added, event::joystick::device::Removed, event::controller::Axis, event::controller::button::Up, event::controller::button::Down, event::controller::device::Added, event::controller::device::Removed, event::controller::device::Remapped, event::gesture::Builtin, event::gesture::custom::Recorded, event::gesture::custom::Detected, event::window::Close, event::window::HitTest, event::window::Shown, event::window::Hidden, event::window::Exposed, event::window::Moved, event::window::Resized, event::window::SizeChanged, event::window::Minimized, event::window::Maximized, event::window::Restored, event::window::mouse::Entered, event::window::mouse::Left, event::window::focus::Gained, event::window::focus::Lost, event::window::focus::Offered, event::SystemWindow, event::drag_n_drop::File, event::drag_n_drop::Text, event::drag_n_drop::Begin, event::drag_n_drop::Complete, event::audio_device::Added, event::audio_device::Removed >
 

Enumerations

enum  ButtonState { Up, Down }
 
enum  BlendMode { BlendMode::none, BlendMode::blend, BlendMode::add, BlendMode::mod }
 Describes how colors are combined when rendering twice to the same place. More...
 
enum  TextureType { Static, Lock, Ren }
 

Functions

void swap (SDLString &a, SDLString &b) noexcept
 
void swap (Ren &a, Ren &b) noexcept
 
void swap (SWTex_Base &a, SWTex_Base &b) noexcept
 
void swap (SWTex_RLELock &a, SWTex_RLELock &b) noexcept
 
void swap (Tex &a, Tex &b) noexcept
 
void swap (TexLock &a, TexLock &b) noexcept
 
void swap (Win_Base &a, Win_Base &b) noexcept
 

Detailed Description

Main namespace.

Enumeration Type Documentation

◆ BlendMode

enum rolmodl::BlendMode
strong

Describes how colors are combined when rendering twice to the same place.

See also
https://wiki.libsdl.org/SDL_BlendMode
Enumerator
none 

Do not blend. Equivalent SDL enum is SDL_BLENDMODE_NONE.

`output RGBA = source RGBA` 
blend 

Alpha-blending. Treats the alpha value as transparency. Equivalent SDL enum is SDL_BLENDMODE_BLEND.

`output RGB = source RGB * source A + output RGB * (1 - source A)`
`output A = source A + output A * (1 - source A)` 
add 

Additive blending. Equivalent SDL enum is SDL_BLENDMODE_ADD.

`output RGB = source RGB * source A + output RGB`
`output A = output A` 
mod 

Color modulation blending. Equivalent SDL enum is SDL_BLENDMODE_MOD.

`output RGB = source RGB * output RGB`
`output A = output A` 

Definition at line 21 of file Ren.hpp.