Uses 654K of libraries. Click here for Pure Java version (1820L/12K/41K).
1 | !7 |
2 | |
3 | lib 1006985 // JAAD for AAC decoding |
4 | |
5 | import javax.sound.sampled.*; |
6 | |
7 | p {
|
8 | File file = getProgramFile(#1006739, "Prince - Motherless Child - Live!-99Q31nyH16w.m4a"); |
9 | assertTrue("Please run #1006739", file.exists());
|
10 | fixContextClassLoader(); |
11 | AudioInputStream ais = AudioSystem.getAudioInputStream(file); |
12 | AudioInputStream a; |
13 | int numBytes = ais.available(); |
14 | System.out.println("numbytes: "+numBytes);
|
15 | byte[] buffer = new byte[numBytes]; |
16 | int count=0; |
17 | while (count!=-1) |
18 | count=ais.read(buffer, count, numBytes-count); |
19 | print("Read " + count + " bytes");
|
20 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1006984 |
| Snippet name: | Test AudioInputStream on .m4a [fails] |
| Eternal ID of this version: | #1006984/7 |
| Text MD5: | 99b0b10dc2fefddcf234d4d3848db6f9 |
| Transpilation MD5: | b26c87450b8eebfa2d3367c3be512a49 |
| Author: | stefan |
| Category: | javax / audio |
| Type: | JavaX source code |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-02-24 13:39:44 |
| Source code size: | 595 bytes / 20 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 771 / 887 |
| Version history: | 6 change(s) |
| Referenced in: | [show references] |