This may sounds like a obvious question, but I\'m missing something about either how UTF-8 is encoded or how the toUtf8 function works.
Let\'s look at a very simple
Running your code I get expected result
"4dc3bc6c6c6572"
I think the problem is with your input not output. Check the encoding of your source file and look at void QTextCodec::setCodecForCStrings ( QTextCodec * codec ) [static]