diff options
| author | Fuwn <[email protected]> | 2021-05-03 16:38:41 -0700 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2021-05-03 16:38:41 -0700 |
| commit | e1e781bb2135ef78592226f1a3eaba4925702f1f (patch) | |
| tree | 8a5b590463ed413e1c6eabb719130e701b95ca63 /NET/worlds/scape/WMPSoundPlayer.java | |
| download | worlds.jar-e1e781bb2135ef78592226f1a3eaba4925702f1f.tar.xz worlds.jar-e1e781bb2135ef78592226f1a3eaba4925702f1f.zip | |
Diffstat (limited to 'NET/worlds/scape/WMPSoundPlayer.java')
| -rw-r--r-- | NET/worlds/scape/WMPSoundPlayer.java | 92 |
1 files changed, 92 insertions, 0 deletions
diff --git a/NET/worlds/scape/WMPSoundPlayer.java b/NET/worlds/scape/WMPSoundPlayer.java new file mode 100644 index 0000000..c8dbd82 --- /dev/null +++ b/NET/worlds/scape/WMPSoundPlayer.java @@ -0,0 +1,92 @@ +/* */ package NET.worlds.scape; +/* */ +/* */ import NET.worlds.console.WebControlImp; +/* */ import NET.worlds.network.URL; +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ +/* */ public class WMPSoundPlayer +/* */ extends SoundPlayer +/* */ { +/* */ protected DirectShow ds; +/* */ protected boolean disabled; +/* */ +/* */ public WMPSoundPlayer(Sound owner) +/* */ { +/* 28 */ super(owner); +/* 29 */ this.ds = new DirectShow(); +/* */ } +/* */ +/* 32 */ static int activeCount = 0; +/* 33 */ boolean playing = false; +/* */ +/* */ public static boolean isActive() +/* */ { +/* 37 */ return activeCount > 0; +/* */ } +/* */ +/* */ +/* */ public boolean open(float volume, float stopDist, boolean atten, boolean pan) +/* */ { +/* 43 */ return true; +/* */ } +/* */ +/* */ public void start(int repeat) +/* */ { +/* 48 */ String megaURL = this.owner.getURL().toString(); +/* 49 */ megaURL = WebControlImp.processURL(megaURL); +/* */ +/* 51 */ this.ds.nOpen(URL.make(megaURL).unalias()); +/* 52 */ activeCount += 1; +/* 53 */ this.ds.nPlay(repeat); +/* 54 */ this.playing = true; +/* */ } +/* */ +/* */ +/* */ public boolean position(Point3Temp cam, Point3Temp obj, Point3Temp out, Point3Temp up) +/* */ { +/* 60 */ return true; +/* */ } +/* */ +/* */ public int getState() +/* */ { +/* 65 */ int nativeState = this.ds.nTick(); +/* 66 */ return nativeState == 3 ? 0 : 1; +/* */ } +/* */ +/* */ public void stop() +/* */ { +/* 71 */ this.ds.nStop(); +/* 72 */ activeCount -= 1; +/* 73 */ this.playing = false; +/* */ } +/* */ +/* */ public void close() +/* */ { +/* 78 */ if (this.playing) { +/* 79 */ stop(); +/* */ } +/* */ } +/* */ +/* */ public boolean setVolume(float v) { +/* 84 */ return true; +/* */ } +/* */ } + + +/* Location: C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\scape\WMPSoundPlayer.class + * Java compiler version: 6 (50.0) + * JD-Core Version: 0.7.1 + */
\ No newline at end of file |