Images from Pixel Data
This example shows how to create Pixel data that you can use to generate an image.
Pixel
We created a Pixel
struct which is unique to C4. It is a very simple struct that contains 4 values, measured in 0…255, and has four initializers.
Here are three two ways to create a Pixel
:
Example