---
title: "samplerComparisonT: constant in Types, TypeShade API"
description: "samplerComparisonT, a constant in Types. The comparison sampler textureSampleCompare takes…"
url: https://typeshade.dev/api/samplercomparisont/
language: en
---

# `samplerComparisonT`

Constant in Types

The comparison sampler `textureSampleCompare` takes: it compares a reference value against the texel and yields how much of the filter footprint passed, rather than the texel itself.

`import { samplerComparisonT } from 'typeshade/core/ir'`

The signature, the description and the examples come from the compiler's own source at commit af54ddad5.

## Syntax

```ts
const samplerComparisonT: { readonly kind: "sampler-comparison"; }
```

## Description

Not interchangeable with [`samplerT`](https://typeshade.dev/api/samplert/) in either direction.

## See also

- [`samplerT`](https://typeshade.dev/api/samplert/)

## Source

[`src/core/ir/types/texture-types.ts`, line 100](https://github.com/typeshade/typeshade/blob/af54ddad5/src/core/ir/types/texture-types.ts#L100), at commit af54ddad5
