It seems it will return the thumbnail if I use the SIIGBF_THUMBNAILONLY flag, but the file type icon with any other combination of flags. This seems a bit weird. It's probably related to how thoroughly I've disabled thumbnails in Explorer.

So it seems all I can do is first try THUMBNAILONLY and then if that fails ICONONLY.