fn create_sine_table() -> Vec<i32> {
    let mut idx: f64 = 0.0;
    let table = (0..512).map(|_| {
        idx += 1.0;
        (((0.703125f64 * idx) * 0.0174532f64).sin() * 1024f64) as i32
    })
    .collect();
    return table;
}