Added compression function prototype, removed decoding to fix encoding as whole bytes