Sorry I can't help - I only know (a little bit) about the WINGATEs in Devon, England.
If your grandfather was born illegitimate in 1925 then you may have to resign yourself to not knowing who his father was. If he or his mother didn't tell anyone then presumably no-one would know.
In England in past times, you could sometimes find out because there were bastardy records but I'm afraid I don't know about Scots law. I imagine there will be lots of information somewhere about bastardy in Scotland and how it was dealt with.
If your relative was poor, you are more likely to find out - via these bastardy provisions - than if he or she was well off. If the mother was well off it would more likely be hushed up. But did your grandfather's mother keep him with her in her family? In the families I am interested in there are two or threee examples of women with illegitimate children keeping the child with them in the family home and then marrying when the child was aged one or two. The child was then 'adopted' into the new family and usually took on the surname of the stepfather.
Of course, we don't know whether that child may have actually been the biological child of the man the mother later married - although in one case I am fairly sure he wasn't because of the different locations of the mother and the stepfather at the time of his birth. Did Mary marry again later?
Again, I only know about England, but another thing you might try here in England is to look up the divorce court records to see if anyone cited Mary as a co-respondent in a divorce case. BUT AGAIN I don't know if this works in Scots law.
Does Hugh have a middle name? Again, in Devon at least, the middle name given to an illegitimate child was often the putative father's surname.
Good luck!
Sandra