4 Commits

Author SHA1 Message Date
Fletcher Dunn b794235422 STEAMNETWORKINGSOCKETS_NOSTEAM is now a thing.
(Not really relevant to the opensource code.)

P4:7193707,7193716,7193719,7193724
2022-04-07 17:58:23 -07:00
Fletcher Dunn 9efdab59ce Multiple lane support working!
Visible changes:
- Uncomment ConfigureConnectionLanes
- Rename GetQuickConnectionStatus to GetConnectionRealTimeStatus, and change
  the prototype to return information about multiple lanes.
- Adding a test case to send data on more than one lane and make sure we get
  the priorities we expect.
- Also refactored the test-connection so that you specify what test(s) to
  run on the command line, instead of using the LIGHT_TESTS compile-time
  option.
- Bump interface version numbers.

Internal changes/bugfixes:
- Fix bug with my implementation of fair queuing.  I was always calculating
  the finish time for a lane based on the current virtual time.  But really
  it must be calculated from the time when the previous message in the same
  lane finishes.  Otherwise you don't share the bandwidth properly when it
  alternates lanes.  To keep the implementation simple, I just tag each
  message with the virual finish time.  I believe that this can actually
  cause the virtual time to go in reverse if you queue a message on an idle
  lane and we swap the active lane while sending is in progress.  But I
  think it's OK right now, and we will actually do the right thing and get
  back on track after a message or two.  To make room for this variable,
  I shuffled around how we had shoved in reliable bookkeeping in
  CSteamNetworkingMessage.
- Fix bug selecting the next message to send.  We were ignoring the priority
  classes and just using virtual time!
- Fix some bad hex math encoding and decoding the lane select frame.
- Fix some bugs that were confused about which set of links were used to
  track the list of messages in a particular lane
- Fix bug when serializing segments from multiple lanes, only one of the
  lanes will get to take advantage of the special segment encoding where
  the segment length is implied by the packet size.
- Reorder the fields in SSNPSenderState::Lane to pack them a bit better

Fixes issue #95.

P4:6865294
2021-10-29 16:46:11 -07:00
Fletcher Dunn 2aed27b01b Clarify comment based on discussion with a dev
P4:6722463
2021-08-12 13:58:47 -07:00
Fletcher Dunn ae52d2d0ce Refactor custom signaling
Removed the word "custom" from the namesofinterfacesthatwerealreadyverylong.

Added k_ESteamNetworkingConfig_Callback_CreateConnectionSignaling, which is
a mechanism for connections that require signaling to be iniated locally.
This is used by ISteamnetwrokingSockets::ConnectP2P and connections created
using the ISteamNetworkingMessages interface....which has been added.

These changes address issue #137 and bring the opensource code more in
line with Steamworks version.

Delete the define STEAMNETWORKINGSOCKETS_HAS_DEFAULT_P2P_SIGNALING.  "Default
signaling" is a thing that can exist on any platform, and can only be determined
at runtime.  Most places that were using this actually should have been
checking STEAMNETWORKINGSOCKETS_ENABLE_STEAMNETWORKINGMESSAGES anyway, and
those two defines were equivalent in practice.
STEAMNETWORKINGSOCKETS_ENABLE_STEAMNETWORKINGMESSAGES will be defined by default.
I could add a mechanism to disable it if anybody is relaly concerned about
code size.

(Also started some refactoring of the P2P listen sockets, to merge them
with hosted dedicated server listen sockets.  The goal is to enable a
way to connected to hosted dedicated servers without tickets.  That is a work
in progress, and also not relevant to the opensource code.)
2020-10-16 15:08:16 -07:00