summaryrefslogtreecommitdiffstats
path: root/services/audioflinger/AudioMixer.h
diff options
context:
space:
mode:
authorGlenn Kasten <gkasten@google.com>2012-01-26 10:53:32 -0800
committerGlenn Kasten <gkasten@google.com>2012-02-17 09:39:07 -0800
commita111792f1314479c649d1d44c30c2caf70c00c2a (patch)
treef67b5f32a61a259f292b7d0d992f31b8e2ff857c /services/audioflinger/AudioMixer.h
parent761defc341c5ce9019a42919c441f035f665ec0d (diff)
downloadframeworks_av-a111792f1314479c649d1d44c30c2caf70c00c2a.zip
frameworks_av-a111792f1314479c649d1d44c30c2caf70c00c2a.tar.gz
frameworks_av-a111792f1314479c649d1d44c30c2caf70c00c2a.tar.bz2
Simplify code
Use DefaultKeyedVector::valueFor to avoid extra test Make local variables as local as possible No double parentheses No typedef for single use No parentheses around indirect function call No AudioFlinger:: prefix when not needed Remove unnecessary casts Remove block with only one line Saves 128 bytes Change-Id: I3a87430eeb01b81e7b81a1c38f6fdd3274ec48f3
Diffstat (limited to 'services/audioflinger/AudioMixer.h')
-rw-r--r--services/audioflinger/AudioMixer.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/services/audioflinger/AudioMixer.h b/services/audioflinger/AudioMixer.h
index f442671..c3174ae 100644
--- a/services/audioflinger/AudioMixer.h
+++ b/services/audioflinger/AudioMixer.h
@@ -114,7 +114,6 @@ private:
struct state_t;
struct track_t;
- typedef void (*mix_t)(state_t* state, int64_t pts);
typedef void (*hook_t)(track_t* t, int32_t* output, size_t numOutFrames, int32_t* temp, int32_t* aux);
static const int BLOCKSIZE = 16; // 4 cache lines
@@ -167,7 +166,7 @@ private:
uint32_t enabledTracks;
uint32_t needsChanged;
size_t frameCount;
- mix_t hook;
+ void (*hook)(state_t* state, int64_t pts); // one of process__*, never NULL
int32_t *outputTemp;
int32_t *resampleTemp;
int32_t reserved[2];