Class IESEngine
IES class which is common for the Importers
Namespace: UnityEditor.Rendering
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, Single, Int32, Boolean)
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. |
| Single | coneAngle | Cone angle used to performe the Gnomonic projection. |
| Int32 | textureSize | The resquested size. |
| Boolean | applyLightAttenuation | Bool to enable or not the Light Attenuation based on the squared distance. |
Returns
| Type | Description |
|---|---|
| (T1, T2)<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, Int32)
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. |
| Int32 | textureSize | The resquested size. |
Returns
| Type | Description |
|---|---|
| (T1, T2)<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 |
|---|---|
| (T1, T2)<Single, 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 |