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

[@microsoft/fast-colors](./fast-colors.md) &gt; [rgbToTemperature](./fast-colors.rgbtotemperature.md)

## rgbToTemperature() function

Convert a rgb color to a color temperature

<b>Signature:</b>

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

## Parameters

|  Parameter | Type | Description |
|  --- | --- | --- |
|  rgb | [ColorRGBA64](./fast-colors.colorrgba64.md) | the color to convert |

<b>Returns:</b>

number

## Remarks

The alpha channel of the input is ignored
