My thoughts on the ending:

(SPOILER)I thought it was very good and not what I expected. It clearly shows that Joel is not a 'good guy'. In fact, he hinted at this throughout the game, saying he's 'been on both sides' and the disagreement with his brother. His decisions at the end of the game were completely wrong and selfish, but also understandable given his character and history. He also knew this, which is why he tried to keep from getting close to Ellie. If anything, the more distant he was towards her the more he was trying to do the 'right thing'. He know how this might end for her. The Winter chapter changed all that though, and at that point he was too far gone to ever come back. The prologue and epilogue were perfect, showing his character come full circle.