Back to project page android-wav-mixer.
The source code is released under:
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE Version 2, December 2004 Copyright (C) 2014 Nathan Sizemore <nathanrsizemore@gmail.com> Everyone is permitted to copy and distribute verbatim or modified ...
If you think the Android project android-wav-mixer listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.nathansizemore.beatmaker.audiomixer.extras; /*www . j a va2 s . c o m*/ public class WavStream { public static final int HEADER_SIZE = 44; public static final int BITS_PER_SAMPLE = 16; public static final int BPM = 80; public static final int SAMPLE_RATE = 44100; public static final int MINUTE = 60; public static final int NUM_CHANNELS = 2; public static final int SAMPLES_PER_MIN = SAMPLE_RATE * MINUTE; public static final int SAMPLE_INTERVAL = SAMPLES_PER_MIN / BPM; public static final int BEATS_PER_MEASURE = 4; public static final int SAMPLE_SECONDS = 6; public static final int SAMPLE_SIZE = (SAMPLE_RATE / 1000) * NUM_CHANNELS * (BITS_PER_SAMPLE / 8) * SAMPLE_SECONDS * 1024; public static final int CHUNK_SIZE = SAMPLE_SIZE / (BEATS_PER_MEASURE * 2); public static final int SAMPLE_NUM_MEASURES = 2; }