I don't know if there is a gene that can make your body process food more efficiently, but I think there are both genetic and learned factors that mean people can be predisposed to obesity through behaviour, lifestyle or physicality.
DH is tall and slim and comes from a tall, slim family. I am short and fat and my family tends towards that (not entirely). So I do consider our differences often. Of course we are only two people, but the things I have observed do (in my opinion) apply to others.
One example is the fidget factor that others have mentioned. DH and his family are always on the go, can't sit still. DH drumming his fingers drives me to distraction! My family are very much of the flop down variety. We don't fidget in the same way, don't feel the need to pop out. It would never occur to us to go for a walk unless it was to somewhere in particular. It is hard to know whether this is learned behaviour or because we don't have that genetic athleticism or instinct to keep moving.
Food-wise, I was always given a sort of comfort food for most meals - soft, hearty stuff like shepherd's pie, savoury suet puddings. Stuff my mum learnt to make at school. I hate the taste of anything bitter like coffee and had always refused cheesy or other savoury flavours even from weaning. Do some people have genetically different taste buds or is it all learned?
On school trips my packed lunches would be epic and I would still be eating when others had finished. So probably that's mostly learned behaviour as I was used to feeling full and to having sweet or bland tastes. DH's family will make a packed lunch to take to the seaside and it will be a sandwich each, an apple and some water. An ice cream is a rare treat. Whereas for my family, a packed lunch is always a full picnic with lots of little extras, an ice cream is mandatory.
The other thing is fluid. I rarely feel thirsty and often forget to drink at all unless reminded. I eat a lot of fruit and that seems to keep thirst at bay.
From time to time I've lost weight so I know it is possible but I'm currently at my heaviest and doing all the worst things despite my fears about cv. Self discipline and good mental health are also factors in remaining slim. But why do some people find this achievable and others don't? What is going on psychologically and is it learned or genetic? If it's personality, how much of that was I born with?
I now have a DS who is physically like his father and seems to naturally moderate his own eating. DD is far more inclined to ask for treats (but as she's younger it could be due to seeing her big brother eating them) and less interested in savoury. I will do everything I can to make sure she doesn't end up like me. But I know, ultimately, the most effective thing I can do is model healthy eating and a healthy weight. I am going to try and do that.
So my conclusion is that yes, being a healthy weight is scientifically calories-in v calories-out. But the factors that cause those calories to go in and out are more complicated and may be a combination of genetic and learned. I may learn to be a healthy weight, but I expect it will always be a battle.