if ( $mime ) {
$this->mime = $mime;
}
- $this->dims = array();
+ $this->dims = [];
}
/**
return $this->handler->getImageSize( $this, $this->getLocalRefPath() );
}
+ /**
+ * @return int
+ */
+ function getBitDepth() {
+ $gis = $this->getImageSize( $this->getLocalRefPath() );
+
+ if ( !$gis || !isset( $gis['bits'] ) ) {
+ return 0;
+ }
+ return $gis['bits'];
+ }
+
/**
* @return bool
*/