Changeset 39187
- Timestamp:
- 11/09/2016 09:04:04 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-image-editor-imagick.php
r38949 r39187 148 148 $this->image = new Imagick(); 149 149 $file_parts = pathinfo( $this->file ); 150 $filename = $this->file; 150 151 151 152 // By default, PDFs are rendered in a very low resolution. … … 153 154 if ( 'pdf' == strtolower( $file_parts['extension'] ) ) { 154 155 $this->image->setResolution( 128, 128 ); 156 157 // Only load the first page. 158 $filename .= '[0]'; 155 159 } 156 160 157 161 // Reading image after Imagick instantiation because `setResolution` 158 162 // only applies correctly before the image is read. 159 $this->image->readImage( $ this->file );163 $this->image->readImage( $filename ); 160 164 161 165 if ( ! $this->image->valid() )
Note: See TracChangeset
for help on using the changeset viewer.