<!--
{
  "documentType" : "article",
  "framework" : "CoreVideo",
  "identifier" : "/documentation/CoreVideo/CVOpenGLTextureCache-cache-attributes",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Cache Attributes"
}
-->

# Cache Attributes

Dictionary keys and values for use with the cacheAttributes parameter of [`CVOpenGLTextureCacheCreate(_:_:_:_:_:_:)`](/documentation/CoreVideo/CVOpenGLTextureCacheCreate(_:_:_:_:_:_:))

## Overview

In some cases, a texture cache can do higher quality chroma upsampling on GPUs that support `ARB_fragment_program`. By default, it will be enabled automatically if the texture cache determines that the GPU has the needed support and the image size is something reasonable for the GPU being used. The default behavior can be overridden using the values defined below.

> Note: Setting the chroma sampling mode to `kCVOpenGLTextureCacheChromaSamplingModeHighQuality` is only a request. GPUs that don’t support `ARB_fragment_program` will still resort back to the native hardware support for YCbCr textures.

## Topics

### Key

[`let kCVOpenGLTextureCacheChromaSamplingModeKey: CFString`](/documentation/CoreVideo/kCVOpenGLTextureCacheChromaSamplingModeKey)

The key used to define the cache’s requested chroma sampling mode.

### Values

[`let kCVOpenGLTextureCacheChromaSamplingModeAutomatic: CFString`](/documentation/CoreVideo/kCVOpenGLTextureCacheChromaSamplingModeAutomatic)

The default mode if not otherwise specified.

[`let kCVOpenGLTextureCacheChromaSamplingModeHighestQuality: CFString`](/documentation/CoreVideo/kCVOpenGLTextureCacheChromaSamplingModeHighestQuality)

Forces the highest quality regardless of performance impact.

[`let kCVOpenGLTextureCacheChromaSamplingModeBestPerformance: CFString`](/documentation/CoreVideo/kCVOpenGLTextureCacheChromaSamplingModeBestPerformance)

Set the chroma sample mode to use the most performant way possible.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)