Enum Class ConsistencyMode

java.lang.Object
java.lang.Enum<ConsistencyMode>
com.banuba.sdk.effect_player.ConsistencyMode
All Implemented Interfaces:
Serializable, Comparable<ConsistencyMode>, Constable

public enum ConsistencyMode extends Enum<ConsistencyMode>
These modes describe the relationship between processing loop and render loop frames

Synchronous - Asynchronous:


- Synchronous means to output (render) a frame only once after a new frame was fully processed
- Asynchronous may render multiple (not waiting for frx), further divided into Consistent and Inconsistent sub-modes. (note: Synchronous mode by definition is always Consistent.)

Consistent - Inconsistent:


- Consistent renders the processed frames as-is, the only change being in the advancement of time (e.g. animations, videos), while
- Inconsistent changes the camera image for that frame to the latest available (not yet processed), resulting in smoother rendering in case frx is slow or unsteady.

"Smart" modes:


There are modes with the "when effect loaded" suffix. These modes behave exactly the same as corresponding modes without such suffix, but only with one difference - they are activated only when the effect was completely loaded.
These modes can be used to avoid image freeze during effect activation.
  • Enum Constant Details

    • SYNCHRONOUS

      public static final ConsistencyMode SYNCHRONOUS
    • SYNCHRONOUS_WHEN_EFFECT_LOADED

      public static final ConsistencyMode SYNCHRONOUS_WHEN_EFFECT_LOADED
      switches to async-inconsistent mode while effect is loading
    • ASYNCHRONOUS_INCONSISTENT

      public static final ConsistencyMode ASYNCHRONOUS_INCONSISTENT
    • ASYNCHRONOUS_CONSISTENT

      public static final ConsistencyMode ASYNCHRONOUS_CONSISTENT
    • ASYNCHRONOUS_CONSISTENT_WHEN_EFFECT_LOADED

      public static final ConsistencyMode ASYNCHRONOUS_CONSISTENT_WHEN_EFFECT_LOADED
      switches to async-inconsistent mode while effect is loading
  • Method Details

    • values

      public static ConsistencyMode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ConsistencyMode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null