50 if ( $name ===
'quality' ) {
53 return parent::validateParam( $name,
$value );
69 $res =
"q{$params['quality']}-$res";
81 if (
preg_match(
'/q([^-]+)-(.*)$/', $str, $m ) ) {
83 if ( self::validateQuality( $v ) ) {
84 $res = parent::parseParamString( $m[2] );
90 $res = parent::parseParamString( $str );
108 throw new MWException(
'Metadata array is not an array' );
113 }
catch ( Exception
$e ) {
116 wfDebug( __METHOD__ .
': ' .
$e->getMessage() .
"\n" );
155 if ( $result->getExitCode() !== 0 ) {
157 $result->getStdout(),
166 return parent::rotate( $file,
$params );
224 realpath( __DIR__ ) .
'/tinyrgb.icc'
243 array $oldProfileStrings, $profileFilepath
251 $result = Shell::command(
254 '-ICC_Profile:ProfileDescription',
263 $data = explode(
"\t",
trim( $result->getStdout() ) );
265 if ( $result->getExitCode() !== 0 ) {
272 if ( empty(
preg_grep( $colorSpaceRegex, $colorSpaces ) ) ) {
278 if ( empty(
preg_grep( $profileRegex, $oldProfileStrings ) ) ) {
284 '-overwrite_original',
285 '-icc_profile<=' . $profileFilepath,
292 if ( $result->getExitCode() !== 0 ) {
294 $result->getStdout(),
and that you know you can do these things To protect your we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights These restrictions translate to certain responsibilities for you if you distribute copies of the or if you modify it For if you distribute copies of such a whether gratis or for a you must give the recipients all the rights that you have You must make sure that receive or can get the source code And you must show them these terms so they know their rights We protect your rights with two and(2) offer you this license which gives you legal permission to copy
$wgUseTinyRGBForJPGThumbnails
When this variable is true and JPGs use the sRGB ICC profile, swaps it for the more lightweight (and ...
$wgJpegTran
used for lossless jpeg rotation
$wgExiftool
Path to exiftool binary.
wfDebug( $text, $dest='all', array $context=[])
Sends a line to the debug log if enabled or, optionally, to a comment in output.
Stuff specific to JPEG and (built-in) TIFF handler.
getRotation( $file)
On supporting image formats, try to read out the low-level orientation of the file and return the ang...
makeParamString( $params)
Merge a parameter array into a string appropriate for inclusion in filenames.
validateParam( $name, $value)
Validate a thumbnail parameter at parse time.
const SRGB_ICC_PROFILE_DESCRIPTION
getScriptParams( $params)
getMetadata( $image, $filename)
Get handler-specific metadata which will be saved in the img_metadata field.
swapICCProfile( $filepath, array $colorSpaces, array $oldProfileStrings, $profileFilepath)
Swaps an embedded ICC profile for another, if found.
static validateQuality( $value)
Validate and normalize quality value to be between 1 and 100 (inclusive).
supportsBucketing()
Returns whether or not this handler supports the chained generation of thumbnails according to bucket...
const SRGB_EXIF_COLOR_SPACE
parseParamString( $str)
Parse a param string made with makeParamString back into an array.
sanitizeParamsForBucketing( $params)
Returns a normalised params array for which parameters have been cleaned up for bucketing purposes.
normaliseParams( $image, &$params)
transformImageMagick( $image, $params)
@inheritDoc
this hook is for auditing only or null if authentication failed before getting that far or null if we can t even determine that When $user is not it can be in the form of< username >< more info > e g for bot passwords intended to be added to log contexts Fields it might only if the login was with a bot password it is not rendered in wiki pages or galleries in category pages allow injecting custom HTML after the section Any uses of the hook need to handle escaping see BaseTemplate::getToolbox and BaseTemplate::makeListItem for details on the format of individual items inside of this array or by returning and letting standard HTTP rendering take place modifiable or by returning false and taking over the output modifiable modifiable after all normalizations have been except for the $wgMaxImageArea check $image
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped noclasses & $ret
returning false will NOT prevent logging $e
$data
Utility to generate mapping file used in mw.Title (phpCharToUpper.json)
The wiki should then use memcached to cache various data To use multiple just add more items to the array To increase the weight of a make its entry a array("192.168.0.1:11211", 2))