Class IESEngine
IES class which is common for the Importers
Inherited Members
Namespace: UnityEditor.Rendering
Assembly: Unity.RenderPipelines.Core.Editor.dll
Syntax
[Serializable]
public class IESEngine
Properties
TextureGenerationType
setter for the Texture generation Type
Declaration
public TextureImporterType TextureGenerationType { set; }
Property Value
| Type | Description |
|---|---|
| TextureImporterType |
Methods
Generate2DCookie(TextureImporterCompression, float, int, bool)
Generating a 2D Texture of this cookie, using a Gnomonic projection of the bottom of the IES
Declaration
public (string, Texture) Generate2DCookie(TextureImporterCompression compression, float coneAngle, int textureSize, bool applyLightAttenuation)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureImporterCompression | compression | Compression parameter requestted. |
| float | coneAngle | Cone angle used to performe the Gnomonic projection. |
| int | textureSize | The resquested size. |
| bool | applyLightAttenuation | Bool to enable or not the Light Attenuation based on the squared distance. |
Returns
| Type | Description |
|---|---|
| (string, Texture) | A Generated 2D texture doing the projection of the IES using the Gnomonic projection of the bottom half hemisphere with the given 'cone angle' |
GenerateCubeCookie(TextureImporterCompression, int)
Generated a Cube texture based on the internal PhotometricType
Declaration
public (string, Texture) GenerateCubeCookie(TextureImporterCompression compression, int textureSize)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureImporterCompression | compression | Compression parameter requestted. |
| int | textureSize | The resquested size. |
Returns
| Type | Description |
|---|---|
| (string, Texture) | A Cubemap representing this IES |
GetKeywordValue(string)
Check a keyword
Declaration
public string GetKeywordValue(string keyword)
Parameters
| Type | Name | Description |
|---|---|---|
| string | keyword | A keyword to check if exist. |
Returns
| Type | Description |
|---|---|
| string | A Keyword if exist inside the internal Dictionary |
GetMaximumIntensity()
Get the CUrrent Max intensity
Declaration
public (float, string) GetMaximumIntensity()
Returns
| Type | Description |
|---|---|
| (float, string) | A pair of the intensity follow by the used unit (candelas or lumens) |
GetPhotometricType()
Getter (as a string) for the Photometric Type
Declaration
public string GetPhotometricType()
Returns
| Type | Description |
|---|---|
| string | The current Photometric Type |
ReadFile(string)
Method to read the IES File
Declaration
public string ReadFile(string iesFilePath)
Parameters
| Type | Name | Description |
|---|---|---|
| string | iesFilePath | Path to the IES file in the Disk. |
Returns
| Type | Description |
|---|---|
| string | An error message or warning otherwise null if no error |