To add to that, you don't have to say, “I'm sorry for your loss.” It's understandable, but we say/ask instead, “How are you?”
A typical conversation goes like this:
Family: Hey! How are you? You came from work?
Visitor: Hi! Yeah, I heard it earlier today, sorry I'm wearing black/red.
Family: That's fine, don't worry about it.
Visitor: How are you?
Family: Fine. I'm reserving my tears for the burial this weekend *laughs*
Visitor: *laughs*
Family: Come, come, we have food/snacks inside. Person B and Person C is inside. Or, if you want you can see him/her first (referring to the dearly departed)? Here, here. Look at him/her, so peaceful.
Then it's chit-chat. It can go from updating each other about our lives to remembering the good things about the dearly departed.
It goes back to solemn atmosphere if there's a religious prayer service. 30 minutes for Pentecostal and born-again; can be up to 60 minutes for Catholics and Protestants. (And if you just arrived, you can eat while the service is on-going, if you want, or stay outside if you don't subscribe to the particular religion). It's not rude to do so.
What is generally considered rude is playing loud music, especially upbeat non-religious music. Or, talking loudly while inside the venue, while someone is paying they respects (looking at the dearly departed; standing before the casket) but after that it's fine to talk loud again. ^^;;
I mean, kids can run around, play. Adults can talk about anything, even laugh.
It's very casual usually. ^_^