spv.ds.ImageParams
Classspv.ds.ImageParams()
This data structure holds all parameters used in image requests. The default values initialized by the constructor are not recommended, the context should provide a factory function for default construction. The image compose process goes as follows. 1. Image is rendered to it's native resolution 2. Image is scaled according to scaled_width and scaled_height 3. Image is cropped according to cropped_width and cropped_height 4. Image is auto cropped if auto_crop is set 5. Image is saved Note that a "0" in scaled_width, scaled_height, cropped_width or cropped_height means that it will use the "native/source" value for that dimension. If auto_crop is set however, and exactly one of scaled_width or scaled_height is set to "0", the "0" will be replaced with a value that keeps the source aspect ratio. @export @struct
.auto_crop
{boolean
}Automatically crops the image of all bordering "empty" pixels @nocollapse
.bg_color_hex
{string
}Specifies the color of the background. Should be a hexadecimal string representing the color. @nocollapse
.crop_x_ratio
{number
}Distribution of the cropped pixels along the X axis (0 = Crop right, 0.5 = Equal, 1 = Crop left) @nocollapse
.crop_y_ratio
{number
}Distribution of the cropped pixels along the Y axis (0 = Crop bottom, 0.5 = Equal, 1 = Crop top) @nocollapse
.cropped_height
{number
}Height of image after crop @nocollapse
.cropped_width
{number
}Width of image after crop @nocollapse
.file_type
{string
}Type of image (png or jpg) @nocollapse
.frame
{number
}Index for the frame/angle @nocollapse
.keep_aspect_ratio
{boolean
}Keep aspect ratio (set any of scaled_width or scaled_height in order for it to have any effect) @nocollapse
.only_use
{Array
.<string
>}The only items that should contribute to the image @nocollapse
.only_use_groups
{Array
.<string
>}The only item groups that should contribute to the image @nocollapse
.scaled_height
{number
}Height that the rendered image should be scaled to @nocollapse
.scaled_width
{number
}Width that the rendered image should be scaled to @nocollapse
.serie_name
{string
}Name of the series to be used (EXTERIOR or INTERIOR in most cases) @nocollapse
.skip
{Array
.<string
>}Items that should not contribute to the image (S-TENT is often set here) @nocollapse
.skip_groups
{Array
.<string
>}Itemgroups that should not contribute to the image @nocollapse
.use_hd
{boolean
}Use HD material @nocollapse