Skip to content

Commit 7449ce4

Browse files
stuartjmoorealejandro-isaza
authored andcommitted
Update CGImage+vImage.swift
1 parent 5c62fab commit 7449ce4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

swift/StableDiffusion/pipeline/CGImage+vImage.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ extension CGImage {
5858
let cgImage = uint8Image.makeCGImage(cgImageFormat:
5959
.init(bitsPerComponent: 8,
6060
bitsPerPixel: 3*8,
61-
colorSpace: CGColorSpace(name: CGColorSpace.sRGB),
61+
colorSpace: CGColorSpace(name: CGColorSpace.sRGB) ?? CGColorSpaceCreateDeviceRGB(),
6262
bitmapInfo: bitmapInfo)!)!
6363

6464
return cgImage

0 commit comments

Comments
 (0)