ElectronNativeImage.getAspectRatio method
ElectronNativeImage › getAspectRatio
Unofficial
Returns the image's aspect ratio. IfscaleFactor is passed, this returns the aspect ratio corresponding to the image representation most closely matching the passed value. Signature:
getAspectRatio(scaleFactor?: number | undefined): numberParameters:
| Parameter | Type | Description |
|---|---|---|
| scaleFactor? | number | undefined | The scale factor to get the aspect ratio for. |
Returns: number — The image's aspect ratio.