IRangeAudio class

Inheritance
  • Object
  • NativeClass
  • IRangeAudio

Constructors

IRangeAudio([NativeClassOptions? options])

Properties

$resource → NativeResource
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
ready Future<void>
Whether the instance is initialized
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

destroy() → void
inherited
enableRangeAudio(boolean enable) FutureOr<void>
@detail api @author chuzhongtao @brief Enable/disable the range audio function.
Range audio means that within a certain range in a same RTC room, the audio volume of the remote user received by the local user will be amplified/attenuated as the remote user moves closer/away. The audio coming from out of the range cannot be heard. See updateReceiveRange{@link #IRangeAudio#updateReceiveRange} to set audio receiving range. @param enable Whether to enable audio range function:
- true: Enable - false: Disable(Defaulting setting) @note You can call this API anytime before or after entering a room. To ensure a smooth switch to the range audio mode after entering the room, you need to call updatePosition{@link #IRangeAudio#updatePosition} before this API to set your own position coordinates, and then enable the range audio function.
nativeCall<T>(String method, [List? args, NativeMethodMeta? meta]) Future<T>
Call instance method
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
sendInstanceGet<T>(String property) Future<T>
Get instance property
inherited
sendInstancePropertiesGet(dynamic nativeClass) Future<Map<String, dynamic>>
Get instance properties
inherited
sendInstanceSet(String property, dynamic value) Future<void>
Set instance property
inherited
setAttenuationModel(AttenuationType type, float coefficient) FutureOr<int>
@detail api @author huangshouqin @brief Set the volume roll-off mode that a 3D sound has in an audio source when using the Range Audio feature. @param type Volume roll-off mode. It is linear roll-off mode by default. Refer to AttenuationType{@link #AttenuationType} for more details. @param coefficient Coefficient for the exponential roll-off mode. The default value is 1. It ranges 0.1,100. We recommended to set it to 50. The volume roll-off speed gets faster as this value increases. @return Result of the call
- 0: Success - -1: Failure because of calling this API before the user has joined a room or before enabling the Range Audio feature by calling enableRangeAudio{@link #IRangeAudio#enableRangeAudio}. @note Call updateReceiveRange{@link #IRangeAudio#updateReceiveRange} to set the range outside which the volume of the sound does not attenuate.
setNoAttenuationFlags(List<String> flags) FutureOr<void>
@detail api @author chuzhongtao @brief Set the flags to mark the user groups, within which the users talk without attenuation.
In the RTC room, if the flags of the users intersects with each other, the users talk without attenuation.
For example, the user is a member of multiple teams, and teammates of the same team talks without attentuation. You can set the flag for each team, and includes the flags of the user's teams in the user's flags. @param flags Array of flags.
toString() String
A string representation of this object.
inherited
updatePosition(Position pos) FutureOr<int>
@detail api @author chuzhongtao @brief Updates the coordinate of the local user's position in the rectangular coordinate system in the current room. @param pos 3D coordinate values, the default value is 0, 0, 0, see Position{@link #Position}. @return API call result:
- 0: Success - !0: Failure @note - After calling this API, you should call enableRangeAudio{@link #IRangeAudio#enableRangeAudio} to enable range audio function to actually enjoy the range audio effect.
updateReceiveRange(ReceiveRange range) FutureOr<int>
@detail api @author chuzhongtao @brief Updates the audio receiving range for the local user. @param range Audio receiving range, see ReceiveRange{@link #ReceiveRange}. @return API call result:
- 0: Success - !0: Failure
updateResource(NativeResource resource) → void
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

codegen_$namespace → dynamic
no setter