copied useful methods to GifReparator and make them public