Surface.colorKey

Wraps SDL_SetColorKey which sets or removes the color key used for the dsdl2.Surface making pixels of the same color transparent

  1. Color colorKey()
  2. void colorKey(uint newPixelKey)
  3. void colorKey(Color newColorKey)
  4. void colorKey(typeof(null) _)
  5. void colorKey(Nullable!Color newColorKey)
    class Surface
    @property @trusted
    void
    colorKey
    ()

Parameters

newColorKey Nullable!Color

dsdl2.Color specifying pixels that get transparency; null to remove the color key

Throws

dsdl2.SDLException if color key unable to set or removed

Meta