Defecating in front of you is an unusual experience for your dog. Therefore you may have observed that he stares at you the whole time. It's not that he's ashamed to admit it. While he "does his thing," he is not hoping you would turn away or offer him solitude. More nuanced layers exist.