My stud is pastured with another stud and geldings
And they can see and smell mares. It depends on the horses.
First I got them used to eachother by my cousin and I would go out riding them together. hand grazed them together. Then shared a fence line. Then let them together for supervised visits, and eventually left them. Now my Stud gets along with pretty much any male. the boys do play very rough. Some marks at times but by looking at their facial expression and little movements can tell they're Playing. they will kind of test each other on occasion, but not serious.
I wouldn't leave them completely alone at first. You said they've shared a fence line, id let then do that for a while, if there's no mares in the mix.. Unless your stud is just aggressive they should be ok.
My stud was used for breeding for 11 years and never met another male horse before I got him. It took Time, and working with them but you'd think they have grown up together now.
He prefers the company, than to be all alone like some studs are kept.
Herd animals... He might enjoy being with your gelding.
My geldings are the dominant ones over the stud.
Friend of mine only had studs. Had 5 pastured together and they acted like geldings together.