---
title: "render(_:to:bounds:colorSpace:)"
framework: coreimage
role: symbol
role_heading: Instance Method
path: "coreimage/cicontext/render(_:to:bounds:colorspace:)-54b9l"
---

# render(_:to:bounds:colorSpace:)

Renders a region of an image into an IOSurface object.

## Declaration

```swift
func render(_ image: CIImage, to surface: IOSurfaceRef, bounds: CGRect, colorSpace: CGColorSpace?)
```

## Parameters

- `image`: A Core Image image object.
- `surface`: The destination IOSurface object.
- `bounds`: The rectangle in the destination IOSurface object to draw into.
- `colorSpace`: The color space of the destination IOSurface object.

## See Also

### Rendering Images

- [createCGImage(_:from:)](coreimage/cicontext/createcgimage(_:from:).md)
- [createCGImage(_:from:format:colorSpace:)](coreimage/cicontext/createcgimage(_:from:format:colorspace:).md)
- [createCGImage(_:from:format:colorSpace:deferred:)](coreimage/cicontext/createcgimage(_:from:format:colorspace:deferred:).md)
- [render(_:toBitmap:rowBytes:bounds:format:colorSpace:)](coreimage/cicontext/render(_:tobitmap:rowbytes:bounds:format:colorspace:).md)
- [render(_:to:)](coreimage/cicontext/render(_:to:).md)
- [render(_:to:bounds:colorSpace:)](coreimage/cicontext/render(_:to:bounds:colorspace:)-2k8l2.md)
- [render(_:to:commandBuffer:bounds:colorSpace:)](coreimage/cicontext/render(_:to:commandbuffer:bounds:colorspace:).md)
