It appears to be impossible with UFFI to pass a structure by value. It can only
pass pointers to structures. Therefore all SDL bindings which reference SDL_Color
parameters, are expected to be passed by value (C embeds the struct members on the stack),
but CL passes the pointer instead. I have worked around this for the function I needed
(TTF_RenderGlyph_Blended) by changing the parameter from a SDL_Color to a uint32
and manually building the appropriate parameter as an integer of the form #x00BBRRGG.
But I'm sure this is only valid for little-endian systems, and the same issue applies to
other functions using structs passed by value.
Since UFFI appears insufficient to express the bindings needed by SDL_ttf,
maybe it's time to investigate whether CFFI can.
non-optimal workaround for TTF_RenderGlyph_Blended as an example