Optical output on Windows complies with the SPDIF standard which means that it can carry mono, stereo, AC3 (Dolby Digital), or DTS. It cannot carry LPCM which is necessary for unencoded multichannel playback.
So, while you can hook your PC up to an external receiver via optical you will only be able to play sound from stereo sources or AC3/DTS sources. Multichannel sources such as those found in most games will not work unless you use a real time Dolby Digital encoder. Creative makes this function available on a few of their high end sound cards.