Multicasting Functions

[This is preliminary documentation and subject to change.]

When you start a multicast session in WSend, it calls the OnStartMulticast function. This function starts a thread that multicasts data using the MulticastWorkerThread function.

The MulticastWorkerThread function runs until you stop the session. The OnStopMulticast function handles stopping the session by setting an abort event, waiting for the event to be handled by the thread, then shutting down the thread.

The MulticastWorkerThread function handles sending the multicast packets. It calls the BandwidthThrottleSend function repeatedly to send the data. The BandwidthThrottleSend function computes the speed for sending data based on the amount of data to send and the bandwidth of the virtual interface. The result of the speed computation is the number of milliseconds to wait between send operations. While waiting, BandwidthThrottleSend checks for abort events, to know when to stop sending.