Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 84114c3f authored by jiabin's avatar jiabin
Browse files

Init haptic intensity for the first fast track.

The haptic intensity for fast track should be initialized, or it will be
HAPTIC_SCALE_MUTE by default, which may result in no haptics.

Bug: 130312331
Test: play haptics stream with FastMixer enabled
Change-Id: If5a1ea12c563c4af1422b2e32451b80e69d2ef58
parent d21b6de7
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -4191,6 +4191,7 @@ AudioFlinger::MixerThread::MixerThread(const sp<AudioFlinger>& audioFlinger, Aud
                                                                     // audio to FastMixer
        fastTrack->mFormat = mFormat; // mPipeSink format for audio to FastMixer
        fastTrack->mHapticPlaybackEnabled = mHapticChannelMask != AUDIO_CHANNEL_NONE;
        fastTrack->mHapticIntensity = AudioMixer::HAPTIC_SCALE_NONE;
        fastTrack->mGeneration++;
        state->mFastTracksGen++;
        state->mTrackMask = 1;