Updated on 2024-10-24 GMT+08:00

Setting Image Effects

Setting the Brightness

You can use the GUI or code mode on OBS Console or make an API call to adjust the brightness of an image.

Table 1 describes the parameters.

This operation is represented by bright.

Table 1 Brightness parameters

Parameter

Value Description

Code Example

value

It adjusts the brightness of an image and ranges from -100 to 100.

The original brightness value is 0. A larger value means a higher level of brightness.

image/bright,50

Setting the Contrast

You can use the GUI or code mode on OBS Console or make an API call to adjust the contrast of an image.

Table 2 describes the parameters.

This operation is represented by contrast.

Table 2 Contrast parameters

Parameter

Value Description

Code Example

value

It adjusts the contrast of an image and ranges from -100 to 100.

The original contrast value is 0. A larger value means a higher level of contrast.

image/contrast,-50

Setting the Sharpness

You can use the GUI or code mode on OBS Console or make an API call to adjust the sharpness of an image.

Table 3 describes the parameters.

This operation is represented by sharpen.

Table 3 Sharpness parameters

Parameter

Value Description

Code Example

value

It adjusts the sharpness of an image and ranges from 50 to 399.

The recommended value is 100. Technically, a larger value means a clearer image, but a too large value will make the image grainy.

image/sharpen,100

Setting the Blur

You can use the GUI or code mode on OBS Console or make an API call to adjust the blur of an image.

Table 4 describes the parameters.

This operation is represented by blur.

Table 4 Blur parameters

Parameter

Value Description

Code Example

r

It represents the blur radius. Its value ranges from 1 to 50.

A larger radius means a larger blurred area.

image/blur,r_3,s_2

s

It represents the standard deviation of normal distribution. Its value ranges from 1 to 50.

A large standard deviation significantly blurs, while a small standard deviation blurs less.

In GUI mode, the parameter r and s increase or decrease simultaneously.

Setting the Grayscale

You can edit code on OBS Console or make an API call to convert an image to grayscale.

Table 5 describes the parameters.

This operation is represented by colorspace.

Table 5 Grayscale parameters

Parameter

Value Description

Code Example

value

It changes the color mode of an image. You can set the parameter to gray to convert the image to grayscale.

image/colorspace,gray