more doxy
fixed first sample of next frame calculation