flac encoding functionality