Fix getSamples(), use doubles instead of floats