liballeg / allegro5

The official Allegro 5 git repository. Pull requests welcome!
https://liballeg.org
Other
1.86k stars 283 forks source link

Feature request: Networking/sockets #554

Open fatcerberus opened 8 years ago

fatcerberus commented 8 years ago

It would be great if Allegro provided basic support for networking. It wouldn't have to be complicated, just a thin wrapper around the platform's native sockets implementation. Winsock and POSIX sockets are different enough that writing platform-independent socket code is pretty tedious.

SiegeLord commented 8 years ago

See #465 and #496. Basically, the idea is to use enet.

fatcerberus commented 8 years ago

Hm, I looked into that enet library, it's a custom protocol apparently. I was more thinking of native sockets, something closer to the metal so to speak. That's always been Allegro's main strength to me--you're ultimately using native functionality, Allegro just abstracts the API so that code changes aren't necessary to compile for different platforms. enet seems a bit more heavyweight than that.

That said, I've been using https://github.com/rxi/dyad, which provides just such an abstraction, in minisphere, and so far it's worked well, so ultimately I would agree that Allegro probably doesn't need to reinvent the wheel here.

beoran commented 8 years ago

I'd say that adding networking to Allegro is biting off more than we can chew at this point. Exactly because there are such networking libraries like the one you mention, it seems better to leave networking out.