D3D10_FILTER enumeration
Filtering options during texture sampling.
Syntax
typedef enum D3D10_FILTER { D3D10_FILTER_MIN_MAG_MIP_POINT = 0, D3D10_FILTER_MIN_MAG_POINT_MIP_LINEAR = 0x1, D3D10_FILTER_MIN_POINT_MAG_LINEAR_MIP_POINT = 0x4, D3D10_FILTER_MIN_POINT_MAG_MIP_LINEAR = 0x5, D3D10_FILTER_MIN_LINEAR_MAG_MIP_POINT = 0x10, D3D10_FILTER_MIN_LINEAR_MAG_POINT_MIP_LINEAR = 0x11, D3D10_FILTER_MIN_MAG_LINEAR_MIP_POINT = 0x14, D3D10_FILTER_MIN_MAG_MIP_LINEAR = 0x15, D3D10_FILTER_ANISOTROPIC = 0x55, D3D10_FILTER_COMPARISON_MIN_MAG_MIP_POINT = 0x80, D3D10_FILTER_COMPARISON_MIN_MAG_POINT_MIP_LINEAR = 0x81, D3D10_FILTER_COMPARISON_MIN_POINT_MAG_LINEAR_MIP_POINT = 0x84, D3D10_FILTER_COMPARISON_MIN_POINT_MAG_MIP_LINEAR = 0x85, D3D10_FILTER_COMPARISON_MIN_LINEAR_MAG_MIP_POINT = 0x90, D3D10_FILTER_COMPARISON_MIN_LINEAR_MAG_POINT_MIP_LINEAR = 0x91, D3D10_FILTER_COMPARISON_MIN_MAG_LINEAR_MIP_POINT = 0x94, D3D10_FILTER_COMPARISON_MIN_MAG_MIP_LINEAR = 0x95, D3D10_FILTER_COMPARISON_ANISOTROPIC = 0xd5, D3D10_FILTER_TEXT_1BIT = 0x80000000 } D3D10_FILTER;
Constants
- D3D10_FILTER_MIN_MAG_MIP_POINT
-
Use point sampling for minification, magnification, and mip-level sampling.
- D3D10_FILTER_MIN_MAG_POINT_MIP_LINEAR
-
Use point sampling for minification and magnification; use linear interpolation for mip-level sampling.
- D3D10_FILTER_MIN_POINT_MAG_LINEAR_MIP_POINT
-
Use point sampling for minification; use linear interpolation for magnification; use point sampling for mip-level sampling.
- D3D10_FILTER_MIN_POINT_MAG_MIP_LINEAR
-
Use point sampling for minification; use linear interpolation for magnification and mip-level sampling.
- D3D10_FILTER_MIN_LINEAR_MAG_MIP_POINT
-
Use linear interpolation for minification; use point sampling for magnification and mip-level sampling.
- D3D10_FILTER_MIN_LINEAR_MAG_POINT_MIP_LINEAR
-
Use linear interpolation for minification; use point sampling for magnification; use linear interpolation for mip-level sampling.
- D3D10_FILTER_MIN_MAG_LINEAR_MIP_POINT
-
Use linear interpolation for minification and magnification; use point sampling for mip-level sampling.
- D3D10_FILTER_MIN_MAG_MIP_LINEAR
-
Use linear interpolation for minification, magnification, and mip-level sampling.
- D3D10_FILTER_ANISOTROPIC
-
Use anisotropic interpolation for minification, magnification, and mip-level sampling.
- D3D10_FILTER_COMPARISON_MIN_MAG_MIP_POINT
-
Use point sampling for minification, magnification, and mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_MAG_POINT_MIP_LINEAR
-
Use point sampling for minification and magnification; use linear interpolation for mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_POINT_MAG_LINEAR_MIP_POINT
-
Use point sampling for minification; use linear interpolation for magnification; use point sampling for mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_POINT_MAG_MIP_LINEAR
-
Use point sampling for minification; use linear interpolation for magnification and mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_LINEAR_MAG_MIP_POINT
-
Use linear interpolation for minification; use point sampling for magnification and mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_LINEAR_MAG_POINT_MIP_LINEAR
-
Use linear interpolation for minification; use point sampling for magnification; use linear interpolation for mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_MAG_LINEAR_MIP_POINT
-
Use linear interpolation for minification and magnification; use point sampling for mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_MIN_MAG_MIP_LINEAR
-
Use linear interpolation for minification, magnification, and mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_COMPARISON_ANISOTROPIC
-
Use anisotropic interpolation for minification, magnification, and mip-level sampling. Compare the result to the comparison value.
- D3D10_FILTER_TEXT_1BIT
-
For use in pixel shaders with textures that have the R1_UNORM format.
Remarks
During texture sampling, one or more texels are read and combined (this is calling filtering) to produce a single value. Point sampling reads a single texel while linear sampling reads two texels (endpoints) and linearly interpolates a third value between the endpoints.
HLSL texture-sampling functions also support comparison filtering during texture sampling. Comparison filtering compares each sampled texel against a comparison value. The boolean result is blended the same way that normal texture filtering is blended.
You can use HLSL intrinsic texture-sampling functions that implement texture filtering only or companion functions that use texture filtering with comparison filtering.
| Texture Sampling Function | Texture Sampling Function with Comparison Filtering |
|---|---|
| sample | samplecmp or samplecmplevelzero |
Comparison filters only work with textures that have the following formats: R32_FLOAT_X8X24_TYPELESS, R32_FLOAT, R24_UNORM_X8_TYPELESS, R16_UNORM.
Requirements
|
Header |
|
|---|
See also