|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EffectControl
EffectControl
is an interface for controlling an abstract filter with various preset settings.
Individual effects might have various parameters.
The effects can be turned on and off by using the setEnabled
method. By default, effects are disabled.
Player
(or EffectModule
) will be stopped
instead. An effect which is not enforced can be dropped
if the system runs out of resources without stopping the associated Player
or EffectModule
. This automatic dropping does, however, not
affect the enabled state of the EffectControl
(set/getEnabled).
Enforcing affects only the LIVE part of the processing; the RECORD part is always "enforced". The enforcing setting of an EffectControl of a MediaProcessor does not affect in any way; that is, status changes are allowed and last value set is returned, but the value is ignored in processing.
Field Summary | ||
---|---|---|
static int |
SCOPE_LIVE_AND_RECORD
A constant used to identify both parts of the effect queue. |
|
static int |
SCOPE_LIVE_ONLY
A constant used to identify the live part of the effect queue. |
|
static int |
SCOPE_RECORD_ONLY
A constant used to identify the recording part of the effect queue. |
Method Summary | ||
---|---|---|
String |
getPreset()
Gets the current preset. |
|
String[] |
getPresetNames()
Gets the available preset names. |
|
int |
getScope()
|
|
boolean |
isEnabled()
|
|
boolean |
isEnforced()
|
|
void |
setEnabled(boolean enable)
Enables/disables the effect. |
|
void |
setEnforced(boolean enforced)
Enforces the effect to be in use. |
|
void |
setPreset(String preset)
Sets the effect according to the given preset. |
|
void |
setScope(int scope)
Sets the scope of the effect. |
Field Detail |
---|
static final int SCOPE_LIVE_ONLY
static final int SCOPE_RECORD_ONLY
static final int SCOPE_LIVE_AND_RECORD
Method Detail |
---|
void setEnabled(boolean enable)
enable
- true
to enable the effect, false
to disable it
IllegalStateException
- if the effect
cannot be enabled in this state of the playerboolean isEnabled()
true
if the effect is enabled,
false
if not
void setScope(int scope) throws MediaException
If this is an EffectControl of the MediaProcessor, the scope setting does not affect in anything.
scope
- SCOPE_LIVE_ONLY
,
SCOPE_RECORD_ONLY
or SCOPE_LIVE_AND_RECORD
.
MediaException
- if the given scope is not supportedint getScope()
SCOPE_LIVE_ONLY
,
SCOPE_RECORD_ONLY
or SCOPE_LIVE_AND_RECORD
void setEnforced(boolean enforced)
If this is an EffectControl of a MediaProcessor, the enforced setting does not affect in any way.
enforced
- true
if the effect is essential and cannot be dropped,
false
if the effect can be dropped if the system runs out of resourcesboolean isEnforced()
true
if the effect is an enforced effect, false
if not
void setPreset(String preset)
preset
- the new preset that will be taken into use
IllegalArgumentException
- if the preset
is not available or it is nullString getPreset()
String[] getPresetNames()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal