No, it doesn't necessarily mean you're ugly.
1.~ A person who is unphotogenic is one that may not appear in photos as they really are in "real life". For example, your hair could appear much darker, or one eye bigger than the other, or your nose may look crooked, but in real life this isn't noticeable.
2.~ A stupid person's synonym for ugly. But you have to be stupid - like REALLY stupid - to think they are actually the same thing.
>>Jackie: Oh no, I look awful in this picture! My left eye looks wider than my right eye!
>>Ben: Aww no Jackie, you're just unphotogenic. Your eyes are gorgeous and the same size when I look at them.
>>Jackie: thanks Ben, you're a sweetie.