It's not really. If your receiver has an optical input (which most do if it's newer than say 8 years), than all you need is a new sound card with an optical output.
Here is a really cheap card that has it -
Newegg.com - PPA 1431v 6 Channels 16-bit PCI Interface Sound Card - Retail
Here is another card that is a bit more expensive and has many more reviews, but some of the reviews seem to indicate there may be some trouble installing drivers for it and you might have to do some hunting for different drivers -
Customer Reviews Of Turtle Beach RIVIERA 5.1 Channels 24-bit 48KHz PCI Interface Sound Card - Retail
That was just looking at Newegg.com. I'm sure if you do some searching around, you can find many other cards with an optical output.
Once you install the sound card (you can even find USB external ones with optical out for even easier installation), all you have to do is plug one single optical cable from the sound card to the receiver, then tell your sound card software to play sound through the optical jack rather than the headphone jack. Some cards may even auto sense which output to use.
If you try that first card I showed you, you're looking at a whopping 15 bucks. Not really a big cost for a fun project.
