Processor for padding images to given size.
More...
#include <pad_to_size.h>
|
void | SetWidthHeight (int width, int height) |
| Process the input images. More...
|
|
virtual bool | operator() (FDMat *mat) |
| operator () for calling processor in this way: processor(mat) More...
|
|
virtual bool | operator() (FDMat *mat, ProcLib lib) |
| operator () for calling processor in this way: processor(mat, lib) This function is for backward compatibility, will be removed in the near future, please use operator()(FDMat* mat) instead and set proc_lib in mat. More...
|
|
virtual bool | operator() (FDMatBatch *mat_batch) |
| operator () for calling processor in this way: processor(mat_batch) More...
|
|
|
static bool | Run (Mat *mat, int width, int height, const std::vector< float > &value, ProcLib lib=ProcLib::DEFAULT) |
| Process the input images. More...
|
|
Processor for padding images to given size.
◆ Run()
bool fastdeploy::vision::PadToSize::Run |
( |
Mat * |
mat, |
|
|
int |
width, |
|
|
int |
height, |
|
|
const std::vector< float > & |
value, |
|
|
ProcLib |
lib = ProcLib::DEFAULT |
|
) |
| |
|
static |
Process the input images.
- Parameters
-
[in] | mat | The input image data, result = mat * alpha + beta |
[in] | width | width of the output image. |
[in] | height | height of the output image. |
[in] | value | value vector used by padding of the output image. |
[in] | lib | to define OpenCV or FlyCV or CVCUDA will be used. |
- Returns
- true if the process successed, otherwise false
◆ SetWidthHeight()
void fastdeploy::vision::PadToSize::SetWidthHeight |
( |
int |
width, |
|
|
int |
height |
|
) |
| |
|
inline |
Process the input images.
- Parameters
-
[in] | width | set the value of the width parameter |
[in] | height | set the value of the height parameter |
The documentation for this class was generated from the following files:
- /fastdeploy/my_work/FastDeploy/fastdeploy/vision/common/processors/pad_to_size.h
- /fastdeploy/my_work/FastDeploy/fastdeploy/vision/common/processors/pad_to_size.cc