cv3.create.full

cv3.create.full(*args, value)[source]

Create an array filled with a specified value.

Parameters:
  • *args – Dimensions of the array. Can be passed as separate arguments (e.g., full(100, 100, 3, value=128)) or as a tuple.

  • value – The value to fill the array with.

Returns:

Array filled with the specified value of type uint8.

Return type:

numpy.ndarray

Example

>>> import cv3
>>> img = cv3.full(100, 100, 3, value=128)  # Create image filled with 128
>>> print(img[0, 0])  # All pixels have value 128
[128 128 128]