Skip to content

AssetMedia

ClassAssetInventoryAssetInventory.Editor
public class AssetMedia

Persistent media attachment for a package, including its remote URL, cached path, preview identity, dimensions, and duration.

public string GetUrl(bool nonEmbedded = true)

Returns the media item’s original URL or cached local URL according to the requested preference.

Parameters

Name Type
nonEmbedded System.Boolean

Returns

System.String

public override string ToString()

Returns

System.String

public AssetMedia()

[PrimaryKey]
[AutoIncrement]
public int Id { get; set; }

Returns

System.Int32

[Indexed]
public int AssetId { get; set; }

Returns

System.Int32

[Indexed]
public string Type { get; set; }

Returns

System.String

public int Order { get; set; }

Returns

System.Int32

public string Url { get; set; }

Returns

System.String

public string ThumbnailUrl { get; set; }

Returns

System.String

public string WebpUrl { get; set; }

Returns

System.String

public int Width { get; set; }

Returns

System.Int32

public int Height { get; set; }

Returns

System.Int32

[Ignore]
public bool IsDownloading { get; set; }

Returns

System.Boolean

[Ignore]
public bool DownloadFailed { get; set; }

Returns

System.Boolean

[Ignore]
public Texture2D ThumbnailTexture { get; set; }

Returns

UnityEngine.Texture2D

[Ignore]
public Texture2D Texture { get; set; }

Returns

UnityEngine.Texture2D