In Philosopher's Stone, when Harry, Hermione and Neville all lose 50 points each for Gryffindor, Harry mentions that it wiped out all the points they had earned beating Slytherin in the Quidditch game earlier. My question is, how do the House Cup and the Quidditch Cup relate to each other at Hogwarts? I was under the impression that they were seperate competitions.
Not quite. TL;DR: We don't know from canon.
The exact quote is:
As for you, Mr Potter, I thought Gryffindor meant more to you than this. All three of you will receive detentions – yes, you too, Mr Longbottom, nothing gives you the right to walk around school at night, especially these days, it's very dangerous – and fifty points will be taken from Gryffindor.'
'Fifty?' Harry gasped – they would lose the lead, the lead he'd won in the last Quidditch match.
'Fifty points each,' said Professor McGonagall, breathing heavily through her long pointed nose.
As you can see, by the time Harry thinks of losing the points he won, he's only aware of being docked 50 points for himself.
However, the last match was against Hufflepuff (NOT Slytheryn which was game #1), and Harry won by catching the Snitch within 5 minutes, meaning that Gryffindor most likely earned more than 50 points (150+ absolute value, and very unlikely that they earned only 50 difference - which would have meant that Hufflepuff managed to score 10 times in 5 minutes).
Therefore, it's basically unknown how much Quidditch games contribute to House Cup but more likely than not, they do NOT attribute the exact amount of points from the game.
It's plausible that they attribute 50 points based on the quote above, but even that is not definite - the quote says "they would lose the lead", but it could very well have been the lead of 49 points, BUT that Harry's Quidditch win gained a lot more than 49 points.
Based on that same line I always assumed that you gained points towards the house cup equal to the number of points earned in the Quidditch Match. You are correct in assuming that the House and Quidditch cups are two separate items, as told found at the end of the Philospher's stone. The Quidditch cup is awarded to the team with the best Quidditch record of the course of the year, where as the House cup is awarded to the House that earned and lost the least amount points from all activities.