How can I decode OGG vorbis data from a ByteBuffer?
问题 The libraries I founded so far only have methods to decode from a file or InputStream . I have a ByteBuffer with OGG vorbis data and I need it decoded to PCM without having to write it to a file first. 回答1: There seem to be 2 parts to this problem. 1) Getting Java Sound to deal with OGG Vorbis format. 2) Avoiding the File. For (1), the Java Sound API allows the addition of extra formats via the Service Provider Interface. The idea is to put an encoder/decoder into a Jar and use a standard