There used to be a LUA script that did it, but it doesn't work anymore. Wasn't useful for anything other than handling replays & even then it was pretty crap.
Also if a recorder was built into the game it'd be too slow to be usable, it'd just grind the game to a halt.
For quality vs performance FRAPS is the way to go, but if you don't want to pay anything get Xfire & use it's built in recorder. I wouldn't bother with others, they wither want money for something worse than FRAPS & the other free ones are pretty shit.