Answer:
The mass of the object involved and the value of the gravitational acceleration
Explanation:
- Gravitational potential energy is defined as the energy possessed by an object in a gravitational field due to its position with respect to the ground:

where m is the mass of the object, g is the gravitational acceleration and h is the heigth of the object with respect to the ground.
- Elastic potential energy is defined as the energy possessed by an elastic object and it is given as:

where k is the spring constant of the elastic object, while x is the compression/stretching of the spring with respect to the equilibrium position.
As we can see from the equations, both types of energy depends on the relative position of the object/end of the spring with respect to a certain reference position (h in the first formula, x in the second formula), but gravitational potential energy also depends on m (the mass) and g (the gravitational acceleration) while the elastic energy does not.