# CardboardMetalDistortionRendererTargetConfig


`#include <cardboard.h>`

Struct to set Metal distortion renderer target configuration.

## Summary

| ### Public attributes ||
|---|---|
| `https://developers.google.com/cardboard/reference/c/struct/cardboard-metal-distortion-renderer-target-config#struct_cardboard_metal_distortion_renderer_target_config_1af16067279346bf70ae18c2412731e23c` | `uint64_t` MTLRenderCommandEncoder id. |
| `https://developers.google.com/cardboard/reference/c/struct/cardboard-metal-distortion-renderer-target-config#struct_cardboard_metal_distortion_renderer_target_config_1ae7dd4e53679e50fc4f67d6ee311f356f` | `int` Full height of the screen in pixels. |
| `https://developers.google.com/cardboard/reference/c/struct/cardboard-metal-distortion-renderer-target-config#struct_cardboard_metal_distortion_renderer_target_config_1a25c4e137893a489d3d5d6010003bd133` | `int` Full width of the screen in pixels. |

## Public attributes

### render_command_encoder

```
uint64_t CardboardMetalDistortionRendererTargetConfig::render_command_encoder
```
MTLRenderCommandEncoder id.

This field holds a CFTypeRef variable pointing to a `MTLRenderCommandEncoder` object. The SDK client is expected to manage the object ownership and to guarantee the pointer validity during the `https://developers.google.com/cardboard/reference/c/group/distortion-renderer#group__distortion-renderer_1gab5fbf6c9f3dbe5029d228fa2cc68aa80` function execution to ensure it is properly retained. Usage example:


```
CardboardMetalDistortionRendererTargetConfig target_config;
target_config.render_command_encoder =
    CFBridgingRetain(renderCommandEncoder);
CardboardDistortionRenderer_renderEyeToDisplay(..., &target_config, ...);
CFBridgingRelease(target_config.render_command_encoder);
```

<br />

### screen_height

```
int CardboardMetalDistortionRendererTargetConfig::screen_height
```
Full height of the screen in pixels.

### screen_width

```
int CardboardMetalDistortionRendererTargetConfig::screen_width
```
Full width of the screen in pixels.