---
id: fast-colors.rgbtolinearluminance
title: rgbToLinearLuminance() function
hide_title: true
---
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[@microsoft/fast-colors](./fast-colors.md) &gt; [rgbToLinearLuminance](./fast-colors.rgbtolinearluminance.md)

## rgbToLinearLuminance() function

Get the luminance of a color in the linear RGB space. This is not the same as the relative luminance in the sRGB space for WCAG contrast calculations. Use rgbToRelativeLuminance instead.

<b>Signature:</b>

```typescript
export declare function rgbToLinearLuminance(rgb: ColorRGBA64): number;
```

## Parameters

|  Parameter | Type | Description |
|  --- | --- | --- |
|  rgb | [ColorRGBA64](./fast-colors.colorrgba64.md) | The input color |

<b>Returns:</b>

number
