PNG  IHDR;IDATxܻn0K )(pA 7LeG{ §㻢|ذaÆ 6lذaÆ 6lذaÆ 6lom$^yذag5bÆ 6lذaÆ 6lذa{ 6lذaÆ `}HFkm,mӪôô! x|'ܢ˟;E:9&ᶒ}{v]n&6 h_tڠ͵-ҫZ;Z$.Pkž)!o>}leQfJTu іچ\X=8Rن4`Vwl>nG^is"ms$ui?wbs[m6K4O.4%/bC%t Mז -lG6mrz2s%9s@-k9=)kB5\+͂Zsٲ Rn~GRC wIcIn7jJhۛNCS|j08yiHKֶۛkɈ+;SzL/F*\Ԕ#"5m2[S=gnaPeғL lذaÆ 6l^ḵaÆ 6lذaÆ 6lذa; _ذaÆ 6lذaÆ 6lذaÆ RIENDB` --- layout: default title: Defaults & presets --- # Defaults & presets In certain situations you may want to define default image manipulations. For example, maybe you want to specify that all images are outputted as JPEGs (`fm=jpg`). Or maybe you have a watermark that you want added to all images. Glide makes this possible using default manipulations. ~~~ php [ 'mark' => 'logo.png', 'markw' => '30w', 'markpad' => '5w', ] ]); // Set using setter method $server->setDefaults([ 'mark' => 'logo.png', 'markw' => '30w', 'markpad' => '5w', ]); ~~~ ## Presets Glide also makes it possible to define groups of defaults, known as presets. This is helpful if you have standard image manipulations that you use throughout your app. ### Configuring presets ~~~ php [ 'small' => [ 'w' => 200, 'h' => 200, 'fit' => 'crop', ], 'medium' => [ 'w' => 600, 'h' => 400, 'fit' => 'crop', ] ] ]); // Set using setter method $server->setPresets([ 'small' => [ 'w' => 200, 'h' => 200, 'fit' => 'crop', ], 'medium' => [ 'w' => 600, 'h' => 400, 'fit' => 'crop', ] ]); ~~~ ### Using presets To use a presets, set it using the `p` parameter: ~~~ html ~~~ It's also possible to use multiple presets together: ~~~ html ~~~ It's even possible to use presets with additional parameters: ~~~ html ~~~ ## Overriding defaults and presets You can override the default and preset manipulations for a specific request by passing a new parameter (e.x. `mark=different.png`), or even disable it entirely by setting it to blank (e.x. `mark=`).