Skip to content

DiGi.Solar.ComputeSharp.Classes

github-actions[bot] edited this page Jul 15, 2026 · 2 revisions

DiGi.Solar.ComputeSharp.Classes Namespace

Classes

ShadingSolver Class

Provides a solver implementation to calculate shading effects on objects using ComputeSharp for GPU acceleration.

public class ShadingSolver : DiGi.Solar.Interfaces.IShadingObject, DiGi.Solar.Interfaces.ISolarObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Interfaces.ISolver, DiGi.Core.Interfaces.IEvaluator

Inheritance System.Object → ShadingSolver

Implements DiGi.Solar.Interfaces.IShadingObject, DiGi.Solar.Interfaces.ISolarObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Interfaces.ISolver, DiGi.Core.Interfaces.IEvaluator

Constructors

ShadingSolver(ShadingModel, ShadingSolverOptions) Constructor

Initializes a new instance of the ShadingSolver class with the specified shading model and options.

public ShadingSolver(DiGi.Solar.Classes.ShadingModel? shadingModel, DiGi.Solar.ComputeSharp.Classes.ShadingSolverOptions? shadingSolverOptions);

Parameters

shadingModel DiGi.Solar.Classes.ShadingModel

The shading model to be used for calculations.

shadingSolverOptions ShadingSolverOptions

The options that configure the solver's behavior.

ShadingSolver(ShadingModel, DateTime[]) Constructor

Initializes a new instance of the ShadingSolver class with the specified shading model and a collection of date-times.

public ShadingSolver(DiGi.Solar.Classes.ShadingModel? shadingModel, System.DateTime[]? dateTimes);

Parameters

shadingModel DiGi.Solar.Classes.ShadingModel

The shading model to be used for calculations.

dateTimes System.DateTime[]

An array of date-time values for which shading should be calculated.

Properties

ShadingSolver.ShadingModel Property

Gets or sets the ShadingModel associated with this solver.

public DiGi.Solar.Classes.ShadingModel? ShadingModel { get; set; }

Property Value

DiGi.Solar.Classes.ShadingModel

ShadingSolver.ShadingSolverOptions Property

Gets or sets the ShadingSolverOptions that define the parameters for the solving process.

public DiGi.Solar.ComputeSharp.Classes.ShadingSolverOptions? ShadingSolverOptions { get; set; }

Property Value

ShadingSolverOptions

Methods

ShadingSolver.Solve() Method

Executes the shading calculation process, utilizing GPU shaders to determine intersections and project shading results onto objects.

public bool Solve();

Implements Solve()

Returns

System.Boolean
True if the solving operation completed successfully; otherwise, false.

ShadingSolverOptions Class

Provides configuration options for the shading solver, including tolerances and time series settings.

public class ShadingSolverOptions : DiGi.Core.Classes.SerializableObject, DiGi.Solar.Interfaces.IShadingSerializableObject, DiGi.Solar.Interfaces.IShadingObject, DiGi.Solar.Interfaces.ISolarObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IOptions

Inheritance System.ObjectDiGi.Core.Classes.ObjectDiGi.Core.Classes.SerializableObject → ShadingSolverOptions

Implements DiGi.Solar.Interfaces.IShadingSerializableObject, DiGi.Solar.Interfaces.IShadingObject, DiGi.Solar.Interfaces.ISolarObject, DiGi.Core.Interfaces.IObject, DiGi.Core.Interfaces.ISerializableObject, DiGi.Core.Interfaces.ICloneableObject<DiGi.Core.Interfaces.ISerializableObject>, DiGi.Core.Interfaces.ICloneableObject, DiGi.Core.Interfaces.IOptions

Constructors

ShadingSolverOptions() Constructor

Initializes a new instance of the ShadingSolverOptions class with default values.

public ShadingSolverOptions();

ShadingSolverOptions(ShadingSolverOptions) Constructor

Initializes a new instance of the ShadingSolverOptions class by copying values from an existing options instance.

public ShadingSolverOptions(DiGi.Solar.ComputeSharp.Classes.ShadingSolverOptions? shadingSolverOptions);

Parameters

shadingSolverOptions ShadingSolverOptions

The source shading solver options to copy from.

ShadingSolverOptions(JsonObject) Constructor

Initializes a new instance of the ShadingSolverOptions class using a JSON object.

public ShadingSolverOptions(System.Text.Json.Nodes.JsonObject? jsonObject);

Parameters

jsonObject System.Text.Json.Nodes.JsonObject

The JSON object containing the options data.

Properties

ShadingSolverOptions.AngleTolerance Property

Gets or sets the angle tolerance used by the shading solver.

public double AngleTolerance { get; set; }

Property Value

System.Double

ShadingSolverOptions.ShadingSolverType Property

Gets or sets the type of shading solver to be employed.

public DiGi.Solar.Enums.ShadingSolverType ShadingSolverType { get; set; }

Property Value

DiGi.Solar.Enums.ShadingSolverType

ShadingSolverOptions.TimeSeries Property

Gets or sets the time series used for shading calculations.

public DiGi.Core.Interfaces.ITimeSeries TimeSeries { get; set; }

Property Value

DiGi.Core.Interfaces.ITimeSeries

ShadingSolverOptions.Tolerance Property

Gets or sets the distance tolerance used by the shading solver.

public double Tolerance { get; set; }

Property Value

System.Double

Clone this wiki locally