This payload is used to share items using the native sharing UI.
/// <summary>/// Create a share payload./// </summary>SharePayload ();
This payload does not require any parameters.
/// <summary>/// Add plain text to the payload./// </summary>/// <param name="text">Plain text to add.</param>void AddText (string text);
Refer to the Adding Text section of the ISharePayload
interface for more information.
/// <summary>/// Add an image to the payload from a pixel buffer./// The pixel buffer MUST have an RGBA8888 pixel layout./// </summary>/// <param name="pixelBuffer">Pixel buffer containing image to add.</param>/// <param name="width">Image width.</param>/// <param name="height">Image height.</param>void AddImage<T> (T[] pixelBuffer, int width, int height) where T : struct;/// <summary>/// Add an image to the payload./// Note that the image MUST be readable./// </summary>/// <param name="image">Image to add.</param>void AddImage (Texture2D image);
Refer to the Adding Images section of the ISharePayload
interface for more information.
/// <summary>/// Add a media file to the payload./// </summary>/// <param name="path">Path to media file to add.</param>void AddMedia (string path);
Refer to the Adding Media Files section of the ISharePayload
interface for more information.
/// <summary>/// Commit the payload and return the success value./// </summary>/// <returns>Whether the sharing action was successfully completed.</returns>Task<bool> Commit ();
Refer to the Committing the Payload section of the ISharePayload
interface for more information.