Welcome to the forum and sorry you need to be here.
I am just as concerned as you, so not sure that I am the right person to give advice. I did manage to save my marriage four years ago, but I am back again.
The one thing that I think is the first step is to take a deep breath (literally) and calm yourself down. I know it seems almost impossible, but it needs to be done. Then you need to forgive yourself for past mistakes and live for today and tomorrow - and live for yourself. You need to make this about you first and then about your marriage. Regardless of the final outcome, if you can become a stronger, better man, than you will have done something very few people bother to do in their lives.
So...focus on the positive things in your life, focus on you, read and learn everything you can about self improvement, relationships, marriage etc and really apply what you learn to your daily life. I am now looking at this whole thing, as my second full time job. That may not work for everyone, but it does for me.
There are some great people here, going through an awful time, but we can all support each other. You will be okay. Maybe even better than ok. Make it your mantra. I WILL BE OKAY - BETTER THAN BEFORE.