DirectX is Microsofts application programming interface for Windows platforms on desktops and Xbox 360. It not only handles graphics but can also handle, input, sound, and particle effects.
Direct3D is the graphics part of DirectX which renders three dimensional vector graphics. Direct3D is well known to have z-fighting troubles, OpenGL does not because it uses a logarithmic depth buffer.
DirectInput and XInput
DirectInput was the input portion of DirectX before the Xbox 360 came along, today the standard is XInput, which ENIGMA has an extension for to use Xbox 360 controllers.
DirectSound, DirectMusic, and XAudio
Same as with DirectInput, DirectSound was for Windows 95 era computers to interface sound hardware, today the standard is XAudio. DirectMusic was also the layer on top of DirectSound which was used for MIDI playback in the older Game Maker versions.
DirectPlay is the obsolete networking part of DirectX that allowed for multiplayer games.
DirectShow is the name of the video playback COM interface introduced with Windows XP, which still exists and is used as the underlying API for Windows Media Player and introduced hardware accelerated playback as of Windows Vista. DirectShow can also interface with Direct3D allowing video playback on render target surfaces and for them to be used as textures.