Variable displacement pump is a type of energy that transfers the mechanical energy of a device to a hydraulic (fluid). The displacement or pumping volume per revolution of the input shaft of the pump can be changed while the pump is running.
Many variable pumps are “reversible”, which means they can be used as hydraulic motors and convert fluid energy into mechanical energy.

A conventional variable displacement pump for vehicle technology is an axial piston pump. The pump has a plurality of pistons arranged in a cylinder parallel to each other and rotating about a central axis. A swash plate at one end is attached to the piston. When the piston rotates, the angle of the plates causes them to enter and exit the cylinder. A rotary valve alternately connects each cylinder to the fluid supply line and the transfer line at the other end of the swash plate.

By changing the angle of the swash plate,  the stroke of the piston can be continuously varied. If the swash plate is perpendicular to the axis of rotation, there will be no fluid flow.  If the angle is sharp, a lot of fluid will be pumped. Some pumps allow the swash plate to move from zero to both directions, pumping fluid in any direction without reversing the rotation of the pump.

An effective change is the bending shaft pump. The curved shaft reduces the lateral load on the piston.

The piston pump can be made to have a variable displacement by inserting the piston into the piston. The displacement is not positively controlled, but decreases as the back pressure increases.

Another variation is a variable displacement vane pump.