Interface IPlaybackIntensity
interface IPlaybackIntensity
Extends com.amazon.apmf.IStandard
Interface that encapsulates Playback Intensity Effect
Methods
enable()
void enable()
Enable the effect
disable()
void disable()
Disable the effect
isEnabled()
bool isEnabled()
Get the effect enabled status
Returns
bool
true if effect is enabled, false otherwise
getDescriptor()
Get effect description. If this setting was not specified when building the effect, this API will return the effect descriptor for the default effect implementation chosen by the OS.EffectDescriptor*getDescriptor()
Returns
EffectDescriptor*
effect descriptor
getPlaybackIntensitySettings()
PlaybackIntensitySettings getPlaybackIntensitySettings()
Get output intensity algorithm settings. If this setting was not specified when
building the effect, this API will return the default PlaybackIntensity settings
used by the chosen effect implementation. Typically, the default value for
frameSizeMs will be 32ms and intensityNormalizationRange will be 1.0.
Returns
PlaybackIntensitySettings
current settings
addListener()
Register listener for playback intensity eventscom.amazon.apmf.ISubscription*addListener(IPlaybackIntensityListener*listener)
Parameters
listener
IPlaybackIntensityListener* — Required
pointer to PlaybackIntensitylistener interface
Returns
com.amazon.apmf.ISubscription*
ISubscription pointer to be used to unsubscribe to the listener
Throws
NullPointerError— if the callback pointer is null
getNormalizedIntensity()
float getNormalizedIntensity()
Get the computed intensity of the on-going stream
Client is expected to call this periodically, frameSizeMs, in the settings
queried using getPlaybackOutputIntensitySettings() api. If the client repeats
the call earlier than the frameSizeMs, the effect will return value computed
from previous frame data.
Returns
float
normalized intensity value within the range 0.0 to 1.0f
Throws
InvalidOperationError— if the effect is not enabled OR called after receiving the onIntensityProcessingStop callback event.

