docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class OptimizationResult

    Represents the result of an image optimization process. This class encapsulates the outcome of optimizing reference images, including the time taken, the number of comparisons made, and the status of the optimization. It also includes lists of deleted and moved files as part of the optimization process.

    Inheritance
    object
    EventArgs
    OptimizationResult
    Inherited Members
    EventArgs.Empty
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: UnityEditor.TestTools.Graphics
    Assembly: UnityEditor.TestTools.Graphics.dll
    Syntax
    public class OptimizationResult : EventArgs

    Properties

    DeletedFiles

    A list of file paths that were deleted as part of the optimization process. This property contains the paths of files that were removed to streamline the reference images, helping to reduce clutter and improve the efficiency of the image set.

    Declaration
    public IList<string> DeletedFiles { get; init; }
    Property Value
    Type Description
    IList<string>

    ElapsedTime

    The time taken to complete the optimization process. This property indicates how long the optimization took from start to finish.

    Declaration
    public TimeSpan ElapsedTime { get; init; }
    Property Value
    Type Description
    TimeSpan

    MovedFiles

    A list of tuples representing files that were moved during the optimization. Each tuple contains the source file path and the destination file path. This property is useful for tracking changes made to the file structure during optimization, allowing users to see which files were relocated and where they were moved to.

    Declaration
    public IList<(string Source, string Destination)> MovedFiles { get; init; }
    Property Value
    Type Description
    IList<(string Source, string Destination)>

    Status

    The status of the optimization process. This property indicates whether the optimization was successful, failed, or encountered any issues. It provides a summary of the outcome, allowing users to quickly assess the result of the optimization.

    Declaration
    public OptimizationStatus Status { get; set; }
    Property Value
    Type Description
    OptimizationStatus

    TotalComparisons

    The total number of image comparisons performed during the optimization. This property provides insight into the scale of the optimization effort, indicating how many images were compared to determine the best reference images.

    Declaration
    public int TotalComparisons { get; init; }
    Property Value
    Type Description
    int

    TotalTextureLoads

    The total number of texture loads that occurred during the optimization. This property tracks how many times textures were loaded into memory, including the times we hit the LRU texture cache.

    Declaration
    public int TotalTextureLoads { get; init; }
    Property Value
    Type Description
    int

    UniqueComparisons

    The number of unique image comparisons made during the optimization. This property indicates how many distinct pairs of images were compared, helping to understand the efficiency of the optimization process.

    Declaration
    public int UniqueComparisons { get; init; }
    Property Value
    Type Description
    int

    UniqueTextureLoads

    The total number of texture loads that occurred during the optimization. This property tracks how many times textures were loaded from disk, without considering cache hits. It helps to understand the efficiency of texture loading during the optimization process. It is particularly useful for identifying how many unique textures were loaded, which can impact performance and memory usage.

    Declaration
    public int UniqueTextureLoads { get; init; }
    Property Value
    Type Description
    int

    Methods

    ToString()

    Declaration
    public override string ToString()
    Returns
    Type Description
    string
    Overrides
    object.ToString()
    In This Article
    Back to top
    Copyright © 2026 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)