> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# D3D12_SAMPLE_POSITION

> Describes a sub-pixel sample position for use with programmable sample positions.

Describes a sub-pixel sample position for use with programmable sample positions.

## Syntax

```cpp theme={null}
typedef struct D3D12_SAMPLE_POSITION
{
    INT8 X;
    INT8 Y;
} D3D12_SAMPLE_POSITION
```

### Members

*X*\
Type: INT8

A signed sub-pixel coordinate value in the X axis.

*Y*\
Type: INT8

A signed sub-pixel coordinate value in the Y axis.

## Remarks

Sample positions have the origin (0, 0) at the pixel center. Each of the X and Y coordinates are signed values in the range -8 (top/left) to 7 (bottom/right). Values outside this range are invalid.

Each increment of these integer values represents 1/16th of a pixel. For example, X and Y values of -8 and 4, respectively, correspond to floating-point values of -0.5 and 0.25, a point located on the left-most edge of the pixel, half-way between its center-line and the bottom edge. Because of this, the bottom-most and right-most edge of a pixel are not reachable by sampling (these positions are reachable as the top-most and left-most edges of the neighboring pixels).

## Requirements

**Header:** d3d12\_xs.h or d3d12\_x.h\
**Library:** d3d12\_xs.lib or d3d12\_x.lib\
**Supported Platforms**: XBOX Series consoles and XBOX One family

## See Also

[Core Structures](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/direct3d-12-structures)


## Related topics

- [SetSamplePositions](/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist1/methods/id3d12graphicscommandlist1_setsamplepositions_public.md)
- [D3D12_PROGRAMMABLE_SAMPLE_POSITIONS_TIER](/reference/graphics/d3d12/enums/d3d12_programmable_sample_positions_tier_public.md)
- [D3D12_FEATURE_DATA_D3D12_OPTIONS2](/reference/graphics/d3d12/structs/d3d12_feature_data_d3d12_options2_public.md)
- [D3D12_GRAPHICS_STATES](/reference/graphics/d3d12/enums/d3d12_graphics_states_public.md)
- [D3D12_BOX](/reference/graphics/d3d12/structs/d3d12_box_public.md)
