SurfaceSyncGroup.Add Method

Definition

Overloads

Add(IAttachedSurfaceControl, IRunnable)

Add an AttachedSurfaceControl to the SurfaceSyncGroup.

Add(SurfaceControlViewHost+SurfacePackage, IRunnable)

Add(IAttachedSurfaceControl, IRunnable)

Add an AttachedSurfaceControl to the SurfaceSyncGroup.

[Android.Runtime.Register("add", "(Landroid/view/AttachedSurfaceControl;Ljava/lang/Runnable;)Z", "", ApiSince=34)]
public bool Add (Android.Views.IAttachedSurfaceControl? attachedSurfaceControl, Java.Lang.IRunnable? runnable);
[<Android.Runtime.Register("add", "(Landroid/view/AttachedSurfaceControl;Ljava/lang/Runnable;)Z", "", ApiSince=34)>]
member this.Add : Android.Views.IAttachedSurfaceControl * Java.Lang.IRunnable -> bool

Parameters

attachedSurfaceControl
IAttachedSurfaceControl

The AttachedSurfaceControl that will be add to this SurfaceSyncGroup.

runnable
IRunnable

This is run on the same thread that the call was made on, but after the rendering is paused and before continuing to render the next frame. This method will not return until the execution of the runnable completes. This can be used to make changes to the AttachedSurfaceControl, ensuring that the changes are included in the sync.

Returns

true if the AttachedSurfaceControl was successfully added to the SurfaceSyncGroup, false otherwise.

Attributes

Remarks

Add an AttachedSurfaceControl to the SurfaceSyncGroup. The AttachedSurfaceControl will pause rendering to ensure the runnable can be invoked and that the sync picks up the frame that contains the changes.

Java documentation for android.window.SurfaceSyncGroup.add(android.view.AttachedSurfaceControl, java.lang.Runnable).

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

Add(SurfaceControlViewHost+SurfacePackage, IRunnable)

[Android.Runtime.Register("add", "(Landroid/view/SurfaceControlViewHost$SurfacePackage;Ljava/lang/Runnable;)Z", "", ApiSince=34)]
public bool Add (Android.Views.SurfaceControlViewHost.SurfacePackage surfacePackage, Java.Lang.IRunnable? runnable);
[<Android.Runtime.Register("add", "(Landroid/view/SurfaceControlViewHost$SurfacePackage;Ljava/lang/Runnable;)Z", "", ApiSince=34)>]
member this.Add : Android.Views.SurfaceControlViewHost.SurfacePackage * Java.Lang.IRunnable -> bool

Parameters

runnable
IRunnable

Returns

Attributes

Applies to