jjdh API

dh.javax.sound
Class BufferStrategy.Stream

java.lang.Object
  extended by dh.javax.sound.BufferStrategy.Stream
All Implemented Interfaces:
BufferStrategy
Enclosing interface:
BufferStrategy

public static class BufferStrategy.Stream
extends Object
implements BufferStrategy

Will stream the audio.

Positive: Uses so less memory as possible.

Negative: Depends on the speed of the underlying input stream and needs cpu Time to decode the audio.

This approch should be used for larger or rare used sound files (for example background music).


Nested Class Summary
 
Nested classes/interfaces inherited from interface dh.javax.sound.BufferStrategy
BufferStrategy.BufferCompressed, BufferStrategy.BufferUncompressed, BufferStrategy.OldBufferUncompressed, BufferStrategy.Stream
 
Field Summary
private  AudioInputStream audioInputStream
           
 
Constructor Summary
BufferStrategy.Stream(AudioInput ai)
           
 
Method Summary
 AudioInputStream getAudioInputStream()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

audioInputStream

private final AudioInputStream audioInputStream
Constructor Detail

BufferStrategy.Stream

public BufferStrategy.Stream(AudioInput ai)
Method Detail

getAudioInputStream

public AudioInputStream getAudioInputStream()
Specified by:
getAudioInputStream in interface BufferStrategy

jjdh API

Copyright © 2006 Jonas Jacobi and Dennis Heidsiek. All Rights Reserved.