Class ScriptingAPI

A DeepAR Scripting API interop namespace.

Hierarchy

  • ScriptingAPI

Methods

  • Check if variable with the given name is already created.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    boolean True if the variable is already created, false otherwise.

  • Get the type of the variable with the given name.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns VarType

    VarType The variable type.

  • Get boolean variable with the given name.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    boolean Value of the variable with the specified name.

  • Get int variable with the given name.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns number

    int Value of the variable with the specified name.

  • Get the double variable with the given name.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns number

    double Value of the variable with the specified name.

  • Get the string variable with the given name.

    Parameters

    • name: string

      The variable name.

    • slot: number = 0

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns string

    string Value of the variable with the specified name.

  • Set the boolean variable with the given name.

    Parameters

    • name: string

      The variable name.

    • value: boolean

      Value to be set.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    True if the variable is created, false if the variable already exists and the new value is set.

  • Set the int variable with the given name.

    Parameters

    • name: string

      The variable name.

    • value: number

      Value to be set.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    True if the variable is created, false if the variable already exists and the new value is set.

  • Set the double variable with the given name.

    Parameters

    • name: string

      The variable name.

    • value: number

      Value to be set.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    True if the variable is created, false if the variable already exists and the new value is set.

  • Set the string variable with the given name.

    Parameters

    • name: string

      The variable name.

    • value: string

      Value to be set.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    True if the variable is created, false if the variable already exists and the new value is set.

  • Delete variable with the given name.

    Parameters

    • name: string

      The variable name.

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    boolean True if the variable is deleted, false otherwise.

  • Clear all variables or variables from the specified effect.

    Parameters

    • Optional slot: string

      The slot of the effect in which to search the variable. If it is not given, variable will be searched for in all the effects.

    Returns boolean

    boolean True if one or more variables are deleted, false otherwise.

Generated using TypeDoc