It's actually both.
Fuel duty is charged at 47.10p per litre, so revenue per litre is fixed regardless of the overall cost of fuel.
On top of that, VAT is charged on the total sale amount at 17.5%, so as fuel prices increase VAT revenue increases as well.
Eg. for petrol at 95p a litre you have 47p in fuel duty, 15p in VAT and the acutal cost of the fuel is about 34p.