nanogui: Cross-compilation of microwindows
Subject:
Re: [nanogui] Cross-compilation of microwindows
From:
"Greg Haerr" ####@####.####
Date:
25 Aug 2005 05:08:55 +0100
Message-Id: <09a001c5a928$ed4671d0$6401a8c0@winXP>
: Then it looks like
: only the code in nxproto.c(I think) has to be hacked up to put the
: data into the order the server wants.
:
: I'd suggest that we create a set of 'ctos' ordering macros for "client
: to server" byteorder that refer to a global that holds the server's
: byteorder, something like:
Hmm.. Overall, I'm definitely not in favor of dirtying up
all the code trying to get the network writes all in the right
byte order, when almost nobody will use the feature.
However, the idea above could work and all be in a single
file (netkluge.c?). There would have to be a switch statement,
based on the packet type, and then swap countless bytes
of info. There would have to be swap code for each of the
120+ network packet types.
The client read side though, isn't all in once place,
and would require considerable restructuring in order to
not have to mess with re-ordering within every api call
that requires data from the server.
Regards,
Greg