Share on Facebook Share on Twitter Email
Answers.com

DirectPlay

 

A set of Windows interfaces from Microsoft for programming graphics and sound. Windows developers program to the DirectX APIs, and the manufacturers of sound cards and display adapters write DirectX drivers to be included with their hardware. DirectX provides a high-level interface for accessing low-level functions "directly." It accesses the hardware abstraction layer in Windows (see HAL).

The first DirectX API was introduced in late 1995 to encourage game developers to move their software to Windows. Before DirectX, games for the PC were written in DOS in order to redraw the screen fast enough for real-time animation. To obtain the speed, gaming companies had to write drivers for a variety of display adapters, which was a development headache.

A Single Graphics Interface for Windows

DirectX provides the interface to access the frame buffer and advanced features of the display adapter, which are not provided in the standard Windows GDI graphics interface. When DirectX was introduced, display adapter vendors were quick to develop DirectX drivers that would expose low-level functions of their hardware to the application.

Emulate Graphics Functions in Software

Through the Hardware Emulation Layer (HEL), DirectX is capable of emulating graphics functions in software that are not built into the display adapter (video card). See graphics pipeline.

Which DirectX Version Is Running?

To determine which version of DirectX is installed in your PC, select Run from the Start menu, type in dxdiag and click OK. Look under System Information for the DirectX Version number. See DirectX 10, GDI, video accelerator and DirectSound.

 DirectX
 Interface      Purpose

 DirectDraw     2D graphics
 Direct3D       3D graphics
 DirectSound    audio
 DirectSound3D  3D audio (gaming)
 DirectPlay     multi-player control (gaming)
 DirectInput    input device control (gaming)
 DirectVoice    players talk to each other (gaming)
 DirectShow     audio, video, streaming media
 DirectVideo    video (earlier API)

Download Computer Desktop Encyclopedia to your iPhone/iTouch

Search unanswered questions...
Enter a question here...
Search: All sources Community Q&A Reference topics
Wikipedia: DirectPlay
Top

DirectPlay is part of Microsoft's DirectX API. DirectPlay is a network communication library intended for computer game development, although its general nature certainly allows it to be used for other purposes.

DirectPlay is a high-level software interface between applications and communication services that makes it easy to connect games over the Internet, a modem link, or a network. DirectPlay features a set of tools that allow players to find game sessions and sites to manage the flow of information between hosts and players. It provides a way for applications to communicate with each other, regardless of the underlying online service or protocol. DirectPlay also resolves many connectivity issues, such as NAT.

DirectPlay, as the rest of DirectX, runs in COM and it is accessed through COM (Component Object Model) interfaces. By default, DirectPlay uses multi-threaded programming techniques and requires careful thought to avoid the usual threading issues. Since DirectX version 9, this issue can be alleviated at the expense of efficiency.

Contents

Networking model

Under the hood, DirectPlay is built on the User Datagram Protocol (UDP) to allow it speedy communication with other DirectPlay applications.

DirectPlay sits on layer 4 and 5 of the OSI model.

  • On layer 4, DirectPlay can handle the following tasks if requested by the application:
    • Message ordering, which ensures that data arrives in the same order it was sent.
    • Message reliability, which ensures that data is guaranteed to arrive.
    • Message flow control, which ensures that data is only sent at the rate the receiver can receive it.
  • On layer 5, DirectPlay always handles the following tasks:
    • Connection initiation and termination.

Interfaces

  • The primary interfaces (methods of access) for DirectPlay are:
    • IDirectPlay8Server, which allows access to server functionality
    • IDirectPlay8Client, which allows access to client functionality
    • IDirectPlay8Peer, which allows access to peer-to-peer functionality
  • Secondary interfaces are:
    • Various lobby interfaces that allows players to find and prepare a game before it actually commences.
    • Thread management interfaces that allows the programmer to fine-tune resource usage. This also allows for a general disabling of worker threads so that tricky multi-threaded issues are avoided at the cost of decreased responsiveness.
    • Various network address translation (NAT) interfaces that make it easier for players behind routers to host games. Most players on broadband internet connections face this problem.
    • Various voice communication interfaces known as DirectPlay Voice that make it easier to support audio communication and voice input in games.
    • Various queue monitoring interfaces that allow the application to get feedback on how much data has been sent and received as requested. This allows an application to decrease/increase the amount of data sent in accordance with the capabilities of the receiver.

DirectPlay Voice

DirectPlay Voice was introduced in Windows Me as part of DirectX 7.1 for multiplayer games. [1] It is a voice communications, recording and playback API that allows gamers to use voice chat in games written to take advantage of the API, through a DirectPlay network transport session itself.

Current status

DirectPlay was traditionally one of the components of DirectX that received less attention, but for DirectX version 8 it received a major overhaul and became a relatively lightweight networking library. However, as part of Microsoft's unveiling of XNA in 2004, Microsoft revealed that DirectPlay would be deprecated in favor of Games for Windows - Live technology already available on Xbox and being ported for use on Windows PCs. DirectPlay will be supported in DirectX DLLs for the lifetime of Microsoft Windows XP, but from the autumn of 2007 [2] the headers and libraries — vital components if developers wanted to develop new programs that utilize the technology — were absent from DirectX SDK.

In Windows Vista, DirectPlay has been deprecated and DirectPlay Voice and DirectPlay's NAT Helper have been removed. [3]

See also

References

External links


 
 
Learn More
Remote Application Programming Interface
Sentinel Returns
DirectDraw

Post a question - any question - to the WikiAnswers community:

 

Copyrights:

Computer Desktop Encyclopedia. THIS COPYRIGHTED DEFINITION IS FOR PERSONAL USE ONLY.
All other reproduction is strictly prohibited without permission from the publisher.
© 1981-2009 Computer Language Company Inc.  All rights reserved.  Read more
Wikipedia. This article is licensed under the Creative Commons Attribution/Share-Alike License. It uses material from the Wikipedia article "DirectPlay" Read more