Contents

ImagePlaygroundOptions.SizeSpecification

A type that specifies image size and aspect ratio information.

Declaration

struct SizeSpecification

Overview

The Image Playground framework supports the creation of images with a finite set of sizes and aspect ratios. To request an image of a particular size, call the static closest(to:) method to create an instance of this structure. That method creates a structure with a supported size that most closely matches the size information you provided. The method considers both the resolution and aspect ratio you specified.

Assign an instance of this structure to the sizeSpecification property of your options, and use those options to generate your image.

Topics

Type Methods