?/TD> |
Microsoft DirectX 9.0 |
A message, as the term is used in this document, is a block of data that needs to be sent to another computer. A network protocol creates a packet by adding some bits to the data block that hold information such as the target's network address. This packet is the basic unit of network data. When the target receives the packet, the target's network protocol removes the extra bits and passes the data block to the receiving application.
Although similar in usage, the terms message and packet are not strictly interchangeable. This document uses the term message to refer to the unit of information that is passed to and received from the Microsoft?DirectPlay® application programming interface (API). Packet refers to the unit of information handled by the network. DirectPlay handles packets internally. With rare exceptions, DirectPlay applications need to deal only with messages.
The primary reason for the distinction between message and packet is that networks generally limit the maximum size of the packets they handle. This size is referred to as a Maximum Transmission Unit (MTU). If a message is small, it is sent in a single packet and the two terms are effectively synonymous. However, large messages might need to be fragmented into two or more packets and then be reassembled by the receiver. The DirectPlay protocol automatically handles fragmentation and reassembly of messages as needed. As far as your application is concerned, you send a message, and the target receives it.