func MapRGB(pixelFormat PixelFormat, r, g, b uint8) uint32 { c_format := (*C.SDL_PixelFormat)(pixelFormat.Ptr) c_r := C.Uint8(r) c_g := C.Uint8(g) c_b := C.Uint8(b) ret := C.SDL_MapRGB(c_format, c_r, c_g, c_b) return uint32(ret) }
// MapRGB maps an RGB triple to an opaque pixel value for a given pixel format. // MapRGB (https://wiki.libsdl.org/SDL_MapRGB) func MapRGB(format *PixelFormat, r, g, b uint8) uint32 { return uint32(C.SDL_MapRGB((*C.SDL_PixelFormat)(unsafe.Pointer(format)), C.Uint8(r), C.Uint8(g), C.Uint8(b))) }
func (p *PixelFormat) MapRGB(r, g, b uint8) uint32 { return uint32(C.SDL_MapRGB(p.c(), C.Uint8(r), C.Uint8(g), C.Uint8(b))) }
// Map a RGB color value to a pixel format. func MapRGB(format *PixelFormat, r, g, b uint8) uint32 { return (uint32)(C.SDL_MapRGB((*C.SDL_PixelFormat)(cast(format)), (C.Uint8)(r), (C.Uint8)(g), (C.Uint8)(b))) }
// Maps an RGB triple to an opaque pixel value for a given pixel format func mapRGB(format *C.SDL_PixelFormat, r, g, b uint8) uint32 { return uint32(C.SDL_MapRGB(format, C.Uint8(r), C.Uint8(g), C.Uint8(b))) }