Most graphics libraries are simply wrapper libraries around a output display. For 2D graphics this is usually X, for 3D, its usually OpenGL.