---
title: "setFragmentIntersectionFunctionTable(_:bufferIndex:)"
framework: metal
role: symbol
role_heading: Instance Method
path: "metal/mtlrendercommandencoder/setfragmentintersectionfunctiontable(_:bufferindex:)"
---

# setFragmentIntersectionFunctionTable(_:bufferIndex:)

Assigns an intersection function table to an entry in the fragment shader argument table.

## Declaration

```swift
func setFragmentIntersectionFunctionTable(_ intersectionFunctionTable: (any MTLIntersectionFunctionTable)?, bufferIndex: Int)
```

## Parameters

- `intersectionFunctionTable`: An doc://com.apple.metal/documentation/Metal/MTLIntersectionFunctionTable instance the command assigns to an entry in the fragment shader argument table for intersection function tables.
- `bufferIndex`: An integer that represents the entry in the fragment shader argument table for intersection function tables that stores a record of intersectionFunctionTable.

## Discussion

Discussion By default, the intersection function table at each index is nil.

## See Also

### Assigning intersection function tables

- [setFragmentIntersectionFunctionTables(_:bufferRange:)](metal/mtlrendercommandencoder/setfragmentintersectionfunctiontables(_:bufferrange:).md)
