Image.pad Method¶
Module: Image
Definition¶
Add padding around the image
Only works for BGR 24 bits, RGB 24 bits and Grayscale 8bits images.
For grayscale image, the padding color is the red component.
pad(self, top: int, left: int, bottom: int, right: int, color_red: int, color_green: int, color_blue: int) -> None
Parameters
topintin Padding on top.leftintin Padding on left.bottomintin Padding on bottom.rightintin Padding on right.color_redintin Padding color red (from 0 to 255)color_greenintin Padding color green (from 0 to 255)color_blueintin Padding color blue (from 0 to 255)
Exceptions
An error has occurred during Face Library execution.
void pad(int top, int left, int bottom, int right, int colorRed, int colorGreen, int colorBlue)
Parameters
topintin Padding on top.leftintin Padding on left.bottomintin Padding on bottom.rightintin Padding on right.colorRedintin Padding color red (from 0 to 255)colorGreenintin Padding color green (from 0 to 255)colorBlueintin Padding color blue (from 0 to 255)
Exceptions
An error has occurred during Face Library execution.
public void Pad(int top, int left, int bottom, int right, int colorRed, int colorGreen, int colorBlue)
Parameters
topintin Padding on top.leftintin Padding on left.bottomintin Padding on bottom.rightintin Padding on right.colorRedintin Padding color red (from 0 to 255)colorGreenintin Padding color green (from 0 to 255)colorBlueintin Padding color blue (from 0 to 255)
Exceptions
An error has occurred during Face Library execution.
public void pad(int top, int left, int bottom, int right, int colorRed, int colorGreen, int colorBlue) throws FaceException
Parameters
topintin Padding on top.leftintin Padding on left.bottomintin Padding on bottom.rightintin Padding on right.colorRedintin Padding color red (from 0 to 255)colorGreenintin Padding color green (from 0 to 255)colorBlueintin Padding color blue (from 0 to 255)
Exceptions
An error has occurred during Face Library execution.
public func pad(top: Int32, left: Int32, bottom: Int32, right: Int32, colorRed: Int32, colorGreen: Int32, colorBlue: Int32) throws
Parameters
topInt32in Padding on top.leftInt32in Padding on left.bottomInt32in Padding on bottom.rightInt32in Padding on right.colorRedInt32in Padding color red (from 0 to 255)colorGreenInt32in Padding color green (from 0 to 255)colorBlueInt32in Padding color blue (from 0 to 255)
Exceptions
An error has occurred during Face Library execution.
int id3FaceImage_Pad (
ID3_FACE_IMAGE hImage,
int top,
int left,
int bottom,
int right,
int colorRed,
int colorGreen,
int colorBlue)
Parameters
hImageID3_FACE_IMAGEin Handle to the Image object.topintin Padding on top.leftintin Padding on left.bottomintin Padding on bottom.rightintin Padding on right.colorRedintin Padding color red (from 0 to 255)colorGreenintin Padding color green (from 0 to 255)colorBlueintin Padding color blue (from 0 to 255)
Returns