Method Image.Dims.get()
- Method
get
array
(int
|string
)|zero
get(string
|Stdio.BlockFile
file
,bool
|void
exif
)- Description
Read dimensions from a JPEG, GIF, PNG, WebP, TIFF or PSD file and return an array with width and height, or if the file isn't a valid image,
0
. The argumentfile
should be file object or the data from a file. The offset pointer will be assumed to be at the start of the file data and will be modified by the function.- Returns
Array int
0
Image width.
int
1
Image height.
string
2
Image type. Any of
"gif"
,"png"
,"tiff"
,"jpeg"
,"webp"
and"psd"
.