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