#define PY_SSIZE_T_CLEAN #include #include "wintype.h" #include "gfxtype.h" PyObject *Epython_rgb(PyObject *self, PyObject *args) { UINT32 r, g, b; if (!PyArg_ParseTuple(args, "kkk", &r, &g, &b)) return NULL; return PyLong_FromUnsignedLong(RGB(r, g, b)); }