https://github.com/umjammer/vavi-sound-nsf
🔊 NSF (NES Sound File) Java sound SPI
https://github.com/umjammer/vavi-sound-nsf
java java-ports jitpack nsf pure-java sound spi
Last synced: 6 months ago
JSON representation
🔊 NSF (NES Sound File) Java sound SPI
- Host: GitHub
- URL: https://github.com/umjammer/vavi-sound-nsf
- Owner: umjammer
- License: gpl-2.0
- Created: 2015-03-13T07:30:35.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2024-11-21T04:59:35.000Z (over 1 year ago)
- Last Synced: 2024-11-21T05:27:28.341Z (over 1 year ago)
- Topics: java, java-ports, jitpack, nsf, pure-java, sound, spi
- Language: Java
- Homepage:
- Size: 201 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://jitpack.io/#umjammer/vavi-sound-nsf)
[](https://github.com/umjammer/vavi-sound-nsf/actions/workflows/maven.yml)
[](https://github.com/umjammer/vavi-sound-nsf/actions/workflows/codeql-analysis.yml)

# vavi-sound-nsf
[NSF](https://www.nesdev.org/wiki/NSF) Java Sound SPI powered by [nsf](https://github.com/orangelando/nsf) and festalon (wip)
### chips
| name | status | comment |
|------|:------:|---------|
| AY | | |
| FDS | ️ | |
| MMC5 | ️ | |
| N106 | ️ | |
| OPLL | ️ | |
| VRC6 | | |
| VRC7 | ️ | |
## Install
* [maven](https://jitpack.io/#umjammer/vavi-sound-nsf)
## Usage
```java
AudioInputStream ais = AudioSystem.getAudioInputStream(Paths.get(nsf).toFile());
Clip clip = AudioSystem.getClip();
clip.open(AudioSystem.getAudioInputStream(new AudioFormat(Encoding.PCM_SIGNED, 44100, 16, 1, 2, 44100, false, props), ais));
clip.loop(Clip.LOOP_CONTINUOUSLY);
```
### properties for target `AudioFormat`
* `track` ... specify track # in the file to play
* `maxPlaySecs` ... specify max play time in \[sec]
## References
* [nsf](https://github.com/orangelando/nsf)
* [Festalon original](https://projects.raphnet.net/)
* [Festalon github](https://github.com/ahefner/festalon)
## TODO
* ~~improve decoding speed (i7 imac)~~
* on m2 ultra mac no problem
* ~~use jpl instead of jul~~
* ~~festalon~~
* spi
* fidlib