Normal Dolby surround sound is encoded into analogue stereo sound sources and so you should be able to record that no problem from video or TV.
However DD5.1 is a digitally encoded sound and so you will need a digital sound source which is 5.1 encoded to record it from. You won't get this from the TV or video unfortunatetly. But I'm not sure that DVD recorders do 5.1 digital recording anyway. Check the specs. From what I can find it only does 2 channel digital sound.