I'm lonely and I can't control myself.

I admit that I have no control over myself when it comes to sex. This lack of discipline has ruined my life and has made me accomplish much less then my full potential. This year I have made many changes in an attempt to  improve myself and it had become obvious that I need to address this issue with myself and really do something about it.
I've tried to do something about it before. I actually started this account about 5 years ago. I had a girlfriend. I thought she was great and we had a deep spiritual connection. The problems started when I was contacted by a previous girlfriend to tell me what a dirtbag I was. I didn't want my ex to contact my current girlfriend so I told her about my ex and everything that happened between up. I thought we were soul mates so it wouldn't be a big deal. Let's just say she didn't handle it well. 
She broke down completely! I'll have to explain what happened in that previous relationship later...  I'm not sure if I just date the wrong people or if I'm doing it all wrong.
She became extremely jealous. Also... she wouldn't let me leave when she was angry. We had many incidents with the police and at one time they even told me that I was a battered husband.
You know what I don't want to get into the whole 3 year relationship. I don't want to say I was the victim because I'm not sure if it was my fault. 
Eventually I ended up in a 3 hold institutionalized. I had to go to weekly therapy and I began taking a antidepressant when I finally let go of that relationship. 
 
It's five years later and I'm not sure if I am a complete dirtbag like my ex ex girlfriend says. I've been single for 5 year. I joined a couple adult website and I've met a few people with no emotional connection.  I've had experiences that I'm actually pretty ashamed about.
 
I know this disease that is also effected by biological need. There is a mechanism in my brain that make me want to procreate and continue my gene pool, but because of my use of technology my brain cannot handle having so much opportunity to get off. 
Am I addicted to porn or am I addicted to getting off?
I think it's both and that makes it worse.
I spend hours wasting time looking at either adult community website, camgirls, or porn videos. I have an extensive collection of videos that I downloaded so I can get off if I don't have wifi. I need to do alot better things with my time. I'm not sure if falling in love again would be a great experience for anyone that dates me....but I wish more then anything I had someone to talk to. I