Change a bunch of reference function arguments to pointers.

Per the coding style and sanity.

Edit: Diff now features the following amazing expression with a red background:

    (&m_state.cursor.x)[!!(i & 2)]

(where `cursor` is `struct { float x, y; }`)