Instance Method

convertSparsePixelRegions:toTileRegions:withTileSize:alignmentMode:numRegions:

Converts a list of regions, specified in pixel coordinates, to sparse tile units.

Declaration

- (void)convertSparsePixelRegions:(const MTLRegion *)pixelRegions toTileRegions:(MTLRegion *)tileRegions withTileSize:(MTLSize)tileSize alignmentMode:(MTLSparseTextureRegionAlignmentMode)mode numRegions:(NSUInteger)numRegions;

Parameters

pixelRegions

An array of pixel regions to convert.

tileRegions

The location to write the results to.

tileSize

The size, in pixels, of a sparse tile.

alignmentMode

The alignment mode to use.

numRegions

The number of regions to convert.

See Also

Converting Between Pixel Regions and Sparse Tile Regions

- convertSparseTileRegions:toPixelRegions:withTileSize:numRegions:

Converts a list of regions, specified in sparse tile coordinates, to pixel units.

MTLSparseTextureRegionAlignmentMode

Options used when converting between a pixel-based region within a texture to a tile-based region.