Issue #5671: Fixed a bug about generateTintImage

Issue #5671: Fixed a bug about generateTintImage