Here you can find the source of millisPerBeat(final float bpm)
Parameter | Description |
---|---|
bpm | Beats per minute |
public static int millisPerBeat(final float bpm)
//package com.java2s; public class Main { /**//from w ww . ja v a2 s . c o m * Given a beats-per-minute rate, returns the number of milliseconds * in a single beat. * * @param bpm Beats per minute * @return Number of milliseconds per beat. */ public static int millisPerBeat(final float bpm) { return (int) (60000f / bpm); } }