Rename frame_generator to generator_player

We already have tone_generators.h that defines several type of wave
generators. The name frame_generator is confusing. What it actually does
is generating a wave, and writes the wave to the player client. To avoid
confusion, rename it into generator_player.

This CL also remove the redundant code in frame_generator, and using raw
bytes instead of 'frames' as the interface of player for better
efficiency and consistency with tone_generators.

Some of the duplicated code in common.h / utils.h is also removed.
SampleFormat is moved out as a separated file.

BUG=chromium:630919
TEST=manually tested on elm.

Change-Id: I1679a49978092ca79b449b3cf31c64f7cc53de91
Reviewed-on: https://chromium-review.googlesource.com/415692
Commit-Ready: Shun-Hsing Ou <shunhsingou@chromium.org>
Tested-by: Shun-Hsing Ou <shunhsingou@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Wei-Han Chen <stimim@chromium.org>
20 files changed
tree: 5fdfe2b659ba79a7f07feb145bec01726c065712
  1. include/
  2. src/
  3. Android.mk
  4. common.mk
  5. CPPLINT.cfg
  6. LICENSE
  7. Makefile
  8. README.txt