I am working on a multiplayer internet game and am wondering whether using Winsock functions or DirectX is faster/more reliable? I know the basics of implementation, but I would just like to know which is faster for communication via TCP/IP?
Winsock is low-level and therefore faster, DirectPlay is more high-level and requires less programming, but it may not be as flexible as you would like it to be.
I don''t think that DirectPlay (from DX7) is capable of maintaining mass online games or fast realtime FPS mplayer games, but for strategy games or similar when you don''t require really fast communication, it should be fine.
Both Winsock and DPlay implementations of the same protocol tend to have similar latency, but overall bandwidth is greater with DPlay, especially when creating a connection. Reliablility is pretty much the same as they work on the same network protocols.