---
title: "vImageBufferFill_ARGBFFFF(_:_:_:)"
framework: accelerate
role: symbol
role_heading: Function
path: "accelerate/vimagebufferfill_argbffff(_:_:_:)"
---

# vImageBufferFill_ARGBFFFF(_:_:_:)

Fills a floating-point 32-bit-per-channel, 4-channel interleaved buffer with a specified color.

## Declaration

```swift
func vImageBufferFill_ARGBFFFF(_ dest: UnsafePointer<vImage_Buffer>, _ color: UnsafePointer<Float>, _ flags: vImage_Flags) -> vImage_Error
```

## Parameters

- `dest`: A pointer to the destination vImage buffer structure. You’re responsible for filling out the doc://com.apple.accelerate/documentation/Accelerate/vImage_Buffer/height, doc://com.apple.accelerate/documentation/Accelerate/vImage_Buffer/width, and doc://com.apple.accelerate/documentation/Accelerate/vImage_Buffer/rowBytes fields of this structure, and for allocating a data buffer of the appropriate size. On return, the data buffer this structure points to contains the destination image data. When you no longer need the data buffer, deallocate the memory to prevent memory leaks.
- `color`: The fill color.
- `flags`: The options to use when performing the operation. If your code implements its own tiling or its own multithreading, pass doc://com.apple.accelerate/documentation/Accelerate/kvImageDoNotTile; otherwise, pass doc://com.apple.accelerate/documentation/Accelerate/kvImageNoFlags.

## Return Value

Return Value kvImageNoError; otherwise, one of the error codes in Data Types and Constants.

## Discussion

Discussion The following code fills the buffer with the specified color: let pixelBuffer = vImage.PixelBuffer<vImage.InterleavedFx4>(     size: .init(width: 1, height: 2))

let fillColor: [Pixel_F] = [64, 127, 192, 255]

pixelBuffer.withUnsafePointerToVImageBuffer { buf in     _ = vImageBufferFill_ARGBFFFF(buf,                                  fillColor,                                  vImage_Flags(kvImageNoFlags)) }

print(pixelBuffer.array) // Prints: //      "[64.0, 127.0, 192.0, 255.0, //        64.0, 127.0, 192.0, 255.0]"

## See Also

### Filling buffers

- [vImageBufferFill_CbCr8(_:_:_:)](accelerate/vimagebufferfill_cbcr8(_:_:_:).md)
- [vImageBufferFill_CbCr16U(_:_:_:)](accelerate/vimagebufferfill_cbcr16u(_:_:_:).md)
- [vImageBufferFill_CbCr16S(_:_:_:)](accelerate/vimagebufferfill_cbcr16s(_:_:_:).md)
- [vImageBufferFill_ARGB8888(_:_:_:)](accelerate/vimagebufferfill_argb8888(_:_:_:).md)
- [vImageBufferFill_ARGB16U(_:_:_:)](accelerate/vimagebufferfill_argb16u(_:_:_:).md)
- [vImageBufferFill_ARGB16S(_:_:_:)](accelerate/vimagebufferfill_argb16s(_:_:_:).md)
- [vImageBufferFill_ARGB16F(_:_:_:)](accelerate/vimagebufferfill_argb16f(_:_:_:).md)
