ImageTransformation
ImageTransformation
ImageTransformation provides Query on image URL
brightness
The brightness parameter allows you to increase or decrease the intensity with which an image reflects or radiates perceived ligh.
| Name | Type | Description |
|---|---|---|
| brightness (required) | int | you can also define brightness using any decimal number |
import contentstack;
final stack = contentstack.Stack("apiKey", "deliveryToken", "environment");
final imageTransformation = stack.imageTransform(imageUrl).brightness(3)blur
The blur parameter allows you to decrease the focus and clarity of a given image. To specify the extent to which you need to increase the blurriness of an image, use any decimal number (float) between 1 and 1000.
| Name | Type | Description |
|---|---|---|
| blur (required) | int | It can accept hexadecimal, combination of (Red, Blue, Green) and (Red, Blue, Green, Alpha) |
import contentstack;
final stack = contentstack.Stack("apiKey", "deliveryToken", "environment");
final imageTransformation = stack.imageTransform(imageUrl).bgBolor('Red')bgColor
he bg-color function lets you set a backgroud color for the given image. This is useful when applying padding or for replacing the transparent pixels of an image..
| Name | Type | Description |
|---|---|---|
| bgColor | String | It can accept hexadecimal, combination of (Red, Blue, Green) and (Red, Blue, Green, Alpha) |
import contentstack;
final stack = contentstack.Stack("apiKey", "deliveryToken", "environment");
final imageTransformation = stack.imageTransform(imageUrl).bgBolor('Red')auto
Specify the version number of the asset that you wish to retrieve. If the version is not specified, the details of the latest version will be retrieved.
| Name | Type | Description |
|---|---|---|
| auto | String | auto parameter is set to webp |
| format | String | The format |
import contentstack;
final stack = contentstack.Stack("apiKey", "deliveryToken", "environment");
final imageTransformation = stack.imageTransform(imageUrl).auto(auto: 'webp', format: 'pjpg')