With such a method, you could programmatically do interesting things with existing graphics. in Wargus' case, you could create night elves or jungle trolls this way, for example
void rotate_hue(QImage &image, const double degrees, const color_set &ignored_colors)
line 308
it uses Qt classes, but it shouldn't be too difficult to convert it to use something different
https://discord.com/channels/780082494447288340/780082494447288344/824247033468682310 It can be used to change skin color. Andrettin:
https://github.com/Andrettin/Wyrmgus/blob/master/src/util/image_util.cpp Andrettin: