다음을 통해 공유


TvView.SetStreamVolume(Single) Method

Definition

Sets the relative stream volume of this TvView.

[Android.Runtime.Register("setStreamVolume", "(F)V", "GetSetStreamVolume_FHandler")]
public virtual void SetStreamVolume (float volume);
[<Android.Runtime.Register("setStreamVolume", "(F)V", "GetSetStreamVolume_FHandler")>]
abstract member SetStreamVolume : single -> unit
override this.SetStreamVolume : single -> unit

Parameters

volume
Single

A volume value between 0.0f to 1.0f.

Attributes

Remarks

Sets the relative stream volume of this TvView.

This method is primarily used to handle audio focus changes or mute a specific TvView when multiple views are displayed. If the method has not yet been called, the TvView assumes the default value of 1.0f.

Java documentation for android.media.tv.TvView.setStreamVolume(float).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to