Creates the builder an image is decoded into, after checking its size against MaxPixels and
MaxDecodedLength; reports ImageTooLarge instead when it is too large.
public bool TryCreateImage(int width, int height, int components, int bitsPerComponent, [NotNullWhen(true)] scoped out DecodedImageBuilder? image)
The number of samples in each row, at least 1.
The number of rows, at least 1.
The number of components, 1 to 32.
The logical bits per component, 1 to 16.
The builder, with zeroed pooled memory.
false when the image is larger than the limits allow.ISO 32000-2 §8.9.3. Rejecting before renting is what stops a few header bytes from claiming gigabytes.