The man Cain knew what would please God and he chose to disobey and do things his way. When God rejected his inappropriate sacrifice, he became angry.
We're left to wonder what the focus of his anger was.
Perhaps Cain was angry with the rejection of his sacrifice. He may have felt that the rejection was a rejection of him as a person. He may have been angry with himself for messing things up.
Whatever the reason for his anger, the Lord came to this disobedient man to help him with his anger and depression issues.
Note that God does seek out people whose actions displease Him. He's interested in reclaiming Cain.
God asks three questions, and the last one is especially important. "If you do what is right, will you not be accepted?"
The answer to Cain's depression or "long face" is to obey the Lord. This was where he fell off the pathway. He veered off into forbidden activity—as his parents did when they ate the forbidden fruit.
Depression can often result from disobedience to the Lord.
The Lord comes to erring Cain with the only possible solution to his dilemma. Trust the Lord and do right. As Peter wrote, 1 Peter 3:10-11 "For, 'Whoever would love life and see good days must keep their tongue from evil and their lips from deceitful speech. They must turn from evil and do good; they must seek peace and pursue it.'" (NIV)
One possible cause for you feeling disappointment with life and discouragement might be disobedience to God. It's between you and the Lord to determine if this is the case.
If this is the reason for your depression, turn from what is evil and seek God's forgiveness through believing in Jesus.
"And what does the Lord require of you? To act justly and to love mercy and to walk humbly with your God." Micah 6:8 (NIV)
Come to the Lord, ask Him to reveal to you what displeases Him and then follow the admonition in Hosea 10:12 "...it is time to seek the Lord, until he comes and showers his righteousness on you." (NIV)
The Lord is ready and willing to forgive and bring to you joy in the place of sorrow.
Seek Him until He makes your sad and sinful heart pure and joyful.