# An Adaptive Buffering Scheme for P2P Live and Time-Shifted Streaming
## 4 Performance Evaluation
### Startup Delay  
Figure 6 shows the startup delays of the adaptive buffering scheme and the fixed buffering scheme when the numbers of participating peers are 1200, 1800, and 2400. When a peer joins or changes its playback position by performing time-shifted functions, if its buffering period is not overlapped with those of any neighbor peers, it waits until at least one neighbor peer can transmit the data required for playback. The startup delays in the simulations include all such waiting times.  
We can see that the startup delays of the adaptive buffering scheme are shorter than those of the fixed buffering scheme for all numbers of peers. That is, the startup delays of the adaptive buffering scheme are shorter by 17.1, 16.6, and 15.5 s when the numbers of peers are 1200, 1800, and 2400, respectively. In particular, when 1200 peers are participating, the startup delay of the adaptive buffering scheme is 47.2 s, while that of the fixed buffering scheme is 64.3 s, which is a 26.6% improvement. This is because the adaptive buffering scheme can considerably increase the degree of data duplication among peers by effectively adjusting the ratio of caching and prefetching areas according to the relative playback positions of each peer in a group. Therefore, the data required for initial playback can be received more quickly. On the contrary, in the fixed buffering scheme, since the ratio of caching and prefetching areas is fixed and the buffering status of other peers is not considered, there is no way to dynamically increase the overlapping degree in buffered data among peers.  
Figure 5: Assignment of peers to playback zones.  
It can be also seen from Figure 6 that as the number of participating peers decreases, the startup delays of both schemes increase. This is because as the number of participating peers decreases, the number of neighbor peers to which each peer can connect also decreases. Thus, it takes longer for each peer to receive a sufficient amount of data to initiate playback.  
Figure 7 shows the startup delays of the two buffering schemes when the buffermap size changes between 256, 512, and 1024 chunks. The startup delays of the adaptive buffering scheme are also shorter than those of the fixed buffering scheme for all buffermap sizes. The adaptive buffering scheme shows startup delays that are 17.7, 17.1, and 14.8 seconds shorter when the number of chunks in a buffermap is 256, 512, and 1024, respectively. Especially, when the buffermap size is 256 chunks, the startup delays of the adaptive buffering scheme and fixed buffering scheme are 48.2 s and 65.9 s, respectively. This performance improvement of 26.9% is also due to the increase in the degree of data duplication among peers.  
Figure 7 also shows that as buffermap size increases, the difference in startup delay between the two schemes decreases slightly. This is because in the fixed buffering scheme, the amount of buffered data also increases with increase in buffer size, thereby increasing the amount of data to be shared among peers.  
Figure 6: Startup delay according to the number of peers (number of chunks per buffermap: 512).  
Figure 7: Startup delay according to the number of chunks per buffermap (number of peers: 1200).