public class Conversions extends Object
Modifier and Type | Class and Description |
---|---|
static class |
Conversions.Conversion |
Modifier and Type | Field and Description |
---|---|
static Conversions.Conversion |
pcmSigned16BigEndian |
static Conversions.Conversion |
pcmSigned16LittleEndian |
Modifier and Type | Method and Description |
---|---|
static @Opt Conversions.Conversion |
get(AudioFormat af) |
static void |
main(String[] args) |
static void |
pcmSigned16BigEndian_float_to_raw(float x,
byte[] out,
int outindex)
(Copied from bt's code in DataLineSink)
|
static float |
pcmSigned16BigEndian_raw_to_float(byte[] in,
int inindex) |
static float |
pcmSigned16BigEndian_raw_to_float(byte b1,
byte b2)
(Copied from bt's code in DataLineSource)
|
static String |
printRaw(byte[] x) |
static void |
testCases(Conversions.Conversion c) |
public static Conversions.Conversion pcmSigned16BigEndian
public static Conversions.Conversion pcmSigned16LittleEndian
@Opt public static @Opt Conversions.Conversion get(AudioFormat af)
public static void pcmSigned16BigEndian_float_to_raw(float x, byte[] out, int outindex)
pcm
- the sound sample to convertout
- where to store the byte resultsoutindex
- where to store the byte resultspublic static float pcmSigned16BigEndian_raw_to_float(byte[] in, int inindex)
public static float pcmSigned16BigEndian_raw_to_float(byte b1, byte b2)
b1
- the first byte to convertb2
- the second byte to convertoutindex
- where to store the byte resultspublic static String printRaw(byte[] x)
public static void testCases(Conversions.Conversion c)
public static void main(String[] args)