I've clocked up over 150 military funerals so far, I should be fairly well able to answer this one..
Officially, anyone who served in the military and was not dishonourably discharged is entitled to have a representative of their service present for the honours. At a minimum, this is supposed to be two men and a tape deck/CD player. (Though now they've come up with a CD-player-in-a-bugle, so it looks the part). Officers are entitled to have an officer present the flag. The embarassing bit is if the CD batteries die half-way through. The families tend to be understanding of that, however.
In practise, however, sometimes we don't have the manpower to do all the funerals of one day, or sometimes traffic holds us up. I've done one or two one-man details in the past. Sometimes the VFW or AL show up and do a firing party, sometimes not.
As much as possible, we try to get as large an attendance as we can. If there is only one funeral that day, we might get a full team together.
The whole shebang is a firing party, bugler, flag detail and sometimes a piper. Full honours are rendered on request to anyone who has achieved sufficient rank (enlisted or commissioned), who earned medals of a certain level, or usually who was killed in action, the latter are usually Dress Blues occasions, if we can gather enough people who have Blues.
We will do whatever the survivng family wants, as long as it's not disrespectful. We did one flag-fold in the widow's living room, taking care not to trip over kids or furniture!
Incidently, the words 'the president' are no longer part of the flag presentation speech. It is now 'On behalf of a grateful nation and the United States Army'
In cases where the individual served as both law enforcement and military, we usually come to a gentleman's agreement as to who gets to do what in the service. (eg, we play taps, fire shots, they present flag) They are frequently quite fun events.
NTM