Beispiel #1
0
func (surface *Surface) SetColorMod(r, g, b uint8) int {
	_surface := (*C.SDL_Surface)(unsafe.Pointer(surface))
	_r := (C.Uint8)(r)
	_g := (C.Uint8)(g)
	_b := (C.Uint8)(b)
	return (int)(C.SDL_SetSurfaceColorMod(_surface, _r, _g, _b))
}
Beispiel #2
0
func (s *Surface) SetColorMod(r, g, b uint8) error {
	if C.SDL_SetSurfaceColorMod(s.c(), C.Uint8(r), C.Uint8(g), C.Uint8(b)) != 0 {
		return getError()
	}

	return nil
}
Beispiel #3
0
func (surface *Surface) SetColorMod(r, g, b uint8) int {
	return int(C.SDL_SetSurfaceColorMod(surface.cptr(), C.Uint8(r), C.Uint8(g), C.Uint8(b)))
}