首页| JavaScript| HTML/CSS| Matlab| PHP| Python| Java| C/C++/VC++| C#| ASP| 其他|
购买积分 购买会员 激活码充值

您现在的位置是:虫虫源码 > Java > jorbis OpenAL支持库扩展

jorbis OpenAL支持库扩展

  • 资源大小:109.42 kB
  • 上传时间:2021-06-30
  • 下载次数:0次
  • 浏览次数:1次
  • 资源积分:1积分
  • 标      签: 扩展 支持

资 源 简 介

Compilation of several sources into one jar to simplify OGG Vorbis files play with OpenAL. (version 1.1 compatible with Java 1.5) Example of use: ``` // Create OGG Decoder OggDecoder oggDecoder = new OggDecoder(); // Decode OGG into PCM InputStream inputStream = new ByteArrayInputStream(bytes); oggData = oggDecoder.getData(inputStream); // Load PCM data into buffer AL10.alBufferData( bufferId, oggData.channels>1? AL10.ALFORMATSTEREO16 : AL10.ALFORMATMONO16, oggData.data, oggData.rate); if (AL10.alGetError() != AL10.ALNOERROR) { //Error check } ``` Special thanks to jcraft"s people and Kevin Glass for this library. Issues in versions 1.0 and 1.1: Problems decoding lower bit-rates (like 8kHz) - change static ints 4096 everywhere in the code to 512 (all java files) or lower values (64, 128). Unfortunately, the jorbis libs have 4096 block size hardcoded and

相 关 资 源

您 可 能 感 兴 趣 的

同 类 别 推 荐

VIP VIP