Package com.banuba.sdk.effect_player
Class Effect.CppProxy
java.lang.Object
com.banuba.sdk.effect_player.Effect.CppProxy
- All Implemented Interfaces:
Effect
- Enclosing interface:
- Effect
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.banuba.sdk.effect_player.Effect
Effect.CppProxy
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
activate
(int fxWidth, int fxHeight, int surfaceWidth, int surfaceHeight) activate current effect MUST be called from the render thread for OpenGL backends.void
callJsMethod
(String methodName, String params) Call js method in effect.void
deserialize
(String resolvedUrl, String configOverride) Deserialize effect from the provided `resoved_url`.void
dump()
void
dumpJson()
void
evalJs
(String script, JsCallback resultCallback) Evaluate the `script` in effect.evalJsSync
(String script) Evaluate the `script` in effect.protected void
finalize()
void
reset()
Reset effect state MUST be called from the render threadscene()
If effect is based on Scene engine and it is activated completly - returns Scene object from the effect.status()
void
update()
Update effect state (evaluate scheduled JS calls) MUST be called from the render threadurl()
Thread-safe.
-
Method Details
-
_djinni_private_destroy
public void _djinni_private_destroy() -
finalize
-
url
Description copied from interface:Effect
Thread-safe. May be called from any thread -
callJsMethod
Description copied from interface:Effect
Call js method in effect.- Specified by:
callJsMethod
in interfaceEffect
- Parameters:
methodName
- JS global function name. Member functions are not supported.params
- Function arguments.
-
evalJs
Description copied from interface:Effect
Evaluate the `script` in effect. This method is thread safe. -
evalJsSync
Description copied from interface:Effect
Evaluate the `script` in effect. MUST be called from the render thread- Specified by:
evalJsSync
in interfaceEffect
- Returns:
- JS evaluation result
-
reset
public void reset()Description copied from interface:Effect
Reset effect state MUST be called from the render thread -
update
public void update()Description copied from interface:Effect
Update effect state (evaluate scheduled JS calls) MUST be called from the render thread -
scene
Description copied from interface:Effect
If effect is based on Scene engine and it is activated completly - returns Scene object from the effect. Otherwise returns null. MUST be called from the render thread Returned Scene object MUST be used only from the render thread and only while the effect is in the activated state. -
deserialize
Description copied from interface:Effect
Deserialize effect from the provided `resoved_url`. If `configOverride` is an empty string, will use `config.json` under provided `resolvedUrl`, otherwise content of `configOverride` will be used. Can be called from any thread.- Specified by:
deserialize
in interfaceEffect
-
activate
public void activate(int fxWidth, int fxHeight, int surfaceWidth, int surfaceHeight) Description copied from interface:Effect
activate current effect MUST be called from the render thread for OpenGL backends. -
dumpFs
-
dump
public void dump() -
dumpJson
-
status
-