Generally, there will be some sort of swearing in for you to be under oath - this is the process where an officer or judge asks that you swear that you are telling the truth. However, if you are giving testimony at a hearing, even if this did not take place, you would be much safer to assume you are under oath.
The first answer is correct regarding the oath. On your second question about whether they would announce everyone who is at the hearing, the answer is no. They do not need to announce all individuals in the room.
At the beginning of a court hearing, the judge typically says all the 'parties' who are present. This usually only means the defendant, plaintiff, and their lawyers. Sometimes a judge will announce a guardian ad litem, probation agent, or some other official who is appearing.
But witnesses, sheriff's deputies, and citizens watching in the gallery are usually not announced. So for that reason, you cannot assume that someone was or was not present just because you did not hear the name.
Perhaps a more interesting response is to ask why does it matter? I hope you haven't shaded the truth. If you have, you should consult competent counsel. Perjury is a serious crime (just ask Bill Clinton).