What do you mean by "hifi?" Do you just mean for playing audio?
It's an old machine that Apple hasn't supported in a while. Depending on which G4 iMac it is, you could theoretically put 10.5 on it and therefore run the latest version of iTunes, but even that won't be supported for much longer.
If you really just want to play audio through it, an Airport Express would be a better investment, as it supports AirPlay.