code: func Generate(r io.Reader, options ...OptionsFunc) (image.Image, error) {
  	w, err := New(r, options...)
  	if err != nil {
  		return nil, err
  	}
  
  	values, err := w.Compute()
  	return w.Draw(values), err
  }
docs: // Generate immediately opens and reads an input audio stream, computes
  // the values required for waveform generation, and returns a waveform image
  // which is customized by zero or more, variadic, OptionsFunc parameters.
  //
  // Generate is equivalent to calling New, followed by the Compute and Draw
  // methods of a Waveform struct.  In general, Generate should only be used
  // for one-time waveform image generation.