# DoesSourceTextureHaveAlpha()

> Allows you to check whether the texture source image has an alpha channel.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/6000.6/script-reference/unityeditor.md)
* **Assembly:** UnityEditor.CoreModule

```csharp
public bool DoesSourceTextureHaveAlpha()
```

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |

### Remarks

This method throws an exception if the texture has not finished importing. For example, it would throw an exception if you called this method in an [AssetPostprocessor.OnPreprocessAsset()](/engine/6000.6/script-reference/unityeditor/assetpostprocessor/onpreprocessasset.md) callback.
