-
Backend
-
Behaviors
-
Classes
-
Controllers
-
Database
-
Seeds
-
-
Facades
-
FormWidgets
-
Helpers
-
Models
-
ReportWidgets
-
Skins
-
Traits
-
VueComponents
-
Widgets
- ServiceProvider
-
-
Cms
-
Classes
- Asset
- CmsCompoundObject
- CmsController
- CmsException
- CmsObject
- CmsObjectCollection
- CodeBase
- CodeParser
- ComponentBase
- ComponentHelpers
- ComponentManager
- ComponentPartial
- Content
- Controller
- EditorExtension
- Layout
- LayoutCode
- MediaLibrary
- MediaLibraryItem
- MediaViewHelper
- Meta
- ObjectMemoryCache
- Page
- PageCode
- Partial
- PartialCode
- PartialStack
- Router
- Theme
- ThemeManager
-
Components
-
Controllers
-
Facades
-
FormWidgets
-
Helpers
-
Models
-
ReportWidgets
-
Traits
-
Twig
- ComponentNode
- ComponentTokenParser
- ContentNode
- ContentTokenParser
- DebugExtension
- DefaultNode
- DefaultTokenParser
- Extension
- FlashNode
- FlashTokenParser
- FrameworkNode
- FrameworkTokenParser
- Loader
- PageNode
- PageTokenParser
- PartialNode
- PartialTokenParser
- PlaceholderNode
- PlaceholderTokenParser
- PutNode
- PutTokenParser
- ScriptsNode
- ScriptsTokenParser
- StylesNode
- StylesTokenParser
-
VueComponents
-
Widgets
- ServiceProvider
-
-
Editor
-
Behaviors
-
Classes
-
Controllers
-
VueComponents
- ServiceProvider
-
-
Media
-
Classes
-
Controllers
-
FormWidgets
-
Twig
-
Widgets
- ServiceProvider
-
-
System
-
Behaviors
-
Classes
-
Console
-
OctoberUtil
- ComposerScript
- OctoberDown
- OctoberFresh
- OctoberMigrate
- OctoberMirror
- OctoberPasswd
- OctoberUp
- OctoberUpdate
- OctoberUtil
- PluginCheck
- PluginDisable
- PluginEnable
- PluginInstall
- PluginList
- PluginRefresh
- PluginRemove
- ProjectSet
- ProjectSync
- ThemeCheck
- ThemeInstall
- ThemeList
- ThemeRemove
- ThemeSync
- ThemeUse
-
-
Controllers
-
Database
-
Facades
-
Helpers
-
Models
-
ReportWidgets
-
Traits
-
Twig
-
Widgets
- ServiceProvider
-
-
Events
-
backend
-
ajax
-
filter
-
form
-
list
-
menu
-
page
-
user
-
-
cms
-
ajax
-
block
-
combiner
-
component
-
object
-
page
-
resizer
-
router
-
template
-
theme
-
-
exception
-
halcyon
-
datasource
-
-
mailer
-
media
-
model
-
auth
-
form
-
relation
-
/docs/api/model/relation/add
-
/docs/api/model/relation/associate
- attach
-
/docs/api/model/relation/beforeadd
-
/docs/api/model/relation/beforeassociate
- beforeAttach
- beforeDetach
-
/docs/api/model/relation/beforedissociate
-
/docs/api/model/relation/beforeremove
- detach
-
/docs/api/model/relation/dissociate
-
/docs/api/model/relation/remove
-
- afterBoot
- afterCreate
- afterDelete
- afterFetch
- afterRestore
- afterSave
- afterUpdate
- afterValidate
- beforeCreate
- beforeDelete
- beforeFetch
- beforeGetAttribute
- beforeRestore
- beforeSave
- beforeSetAttribute
- beforeUpdate
- beforeValidate
- getAttribute
- saveInternal
- setAttribute
-
-
system
-
assets
-
console
-
mirror
-
theme
-
-
reportwidgets
-
resizer
-
settings
- extendConfigFile
-
-
translator
-
-
Library
-
Argon
-
Assetic
-
Asset
-
Cache
-
Exception
-
Factory
-
Filter
- BaseCssFilter
- CallablesFilter
- CssCacheBustingFilter
- CssImportFilter
- CssMinFilter
- CssRewriteFilter
- FilterCollection
- JavascriptImporter
- JSMinFilter
- JSMinPlusFilter
- JSqueezeFilter
- LessCompiler
- LessphpFilter
- MinifyCssCompressorFilter
- PackagerFilter
- PackerFilter
- ScssCompiler
- ScssphpFilter
- StylesheetMinify
-
Util
- README
- AssetManager
- AssetWriter
- FilterManager
-
-
Auth
-
Models
- AuthException
- Manager
-
-
Config
-
Database
-
Attach
-
Behaviors
-
Concerns
-
Connections
-
Connectors
-
Models
-
Relations
-
Schema
-
Traits
-
Updates
- README
- Builder
- Collection
- DatabaseServiceProvider
- DataFeed
- Dongle
- MemoryCache
- MigrationServiceProvider
- Model
- ModelBehavior
- ModelException
- MorphPivot
- NestedTreeScope
- Pivot
- QueryBuilder
- SortableScope
- TreeCollection
- Updater
-
-
Events
-
Exception
-
Extension
-
Filesystem
-
Flash
-
Foundation
-
Bootstrap
-
Console
-
Exception
-
Http
-
Middleware
- Kernel
-
-
Providers
- Application
- Maker
-
-
Halcyon
-
Datasource
-
Exception
-
Processors
-
Traits
- README
- Builder
- Collection
- HalcyonServiceProvider
- MemoryCacheManager
- MemoryRepository
- Model
-
-
Html
-
Mail
-
Network
-
Parse
-
Parsedown
-
Syntax
- Bracket
- Ini
- Markdown
- MarkdownData
- ParseServiceProvider
- Twig
- Yaml
-
-
Process
-
Resize
-
Router
-
Scaffold
-
Support
-
Translation
-
- Documentation
- API
- Library
- Database
- Attach
- Resizer
October\Rain\Database\Attach\Resizer
Extends:
Resizer for images
See also:
Protected properties
There are no protected properties in the class.
Show inherited protected properties
Inherited protected properties
- protected Resource $file - defined in October\Rain\Resize\Resizer. The symfony uploaded file object.
- protected string $extension - defined in October\Rain\Resize\Resizer. extension of the uploaded file.
- protected string $mime - defined in October\Rain\Resize\Resizer. mime type of the uploaded file.
- protected Resource $image - defined in October\Rain\Resize\Resizer. image (on disk) that's being resized.
- protected Resource $originalImage - defined in October\Rain\Resize\Resizer. originalImage cached.
- protected int $width - defined in October\Rain\Resize\Resizer. width of the original image being resized.
- protected int $height - defined in October\Rain\Resize\Resizer. height of the original image being resized.
- protected int|null $orientation - defined in October\Rain\Resize\Resizer. orientation (Exif) of image.
- protected array $options - defined in October\Rain\Resize\Resizer. options used for resizing.
Public methods
public void __construct($file)
__construct instantiates the Resizer and receives the path to an image we're working with
Parameters
- $file
Inherited public methods
- public void crop(int $cropStartX, int $cropStartY, int $newWidth, int $newHeight, int $srcWidth=NULL, int $srcHeight=NULL) - defined in October\Rain\Resize\Resizer. Crops an image from its center.
- public static Resizer open(mixed $file) - defined in October\Rain\Resize\Resizer. Static call, Laravel style.
- public void reset() - defined in October\Rain\Resize\Resizer. reset the image back to the original.
- public void resize(int $newWidth, int $newHeight, array $options=array()) - defined in October\Rain\Resize\Resizer. resize and/or crop an image.
- public void save(string $savePath) - defined in October\Rain\Resize\Resizer. save the image based on its file type.
- public void setOptions($options) - defined in October\Rain\Resize\Resizer. setOptions sets resizer options. Available options are:.
- public void sharpen(int $sharpness) - defined in October\Rain\Resize\Resizer. sharpen the image across a scale of 0 - 100.
Protected methods
Show inherited protected methods
Inherited protected methods
- protected array getDimensions(int $newWidth, int $newHeight) - defined in October\Rain\Resize\Resizer. getDimensions returns the image dimensions based on the option that was chosen.
- protected int getHeight() - defined in October\Rain\Resize\Resizer. getHeight receives the image's height while respecting.
- protected void getOptimalCrop(int $newWidth, int $newHeight) - defined in October\Rain\Resize\Resizer. getOptimalCrop attempts to find the best way to crop. Whether crop is based on the.
- protected mixed getOption(string $option) - defined in October\Rain\Resize\Resizer. getOption gets an individual resizer option.
- protected int|null getOrientation(Symfony\Component\HttpFoundation\File\File $file) - defined in October\Rain\Resize\Resizer. getOrientation receives the image's exif orientation.
- protected resource getRotatedOriginal() - defined in October\Rain\Resize\Resizer. getRotatedOriginal receives the original but rotated image.
- protected void getSizeByAuto(int $newWidth, int $newHeight) - defined in October\Rain\Resize\Resizer. getSizeByAuto checks to see if an image is portrait or landscape and resizes accordingly.
- protected void getSizeByFit(int $maxWidth, int $maxHeight) - defined in October\Rain\Resize\Resizer. getSizeByFit fits the image inside a bounding box using maximum width.
- protected int getSizeByFixedHeight(int $newHeight) - defined in October\Rain\Resize\Resizer. getSizeByFixedHeight returns the width based on the image height.
- protected int getSizeByFixedWidth(int $newWidth) - defined in October\Rain\Resize\Resizer. Returns the height based on the image width.
- protected int getWidth() - defined in October\Rain\Resize\Resizer. getWidth receives the image's width while respecting.
- protected mixed openImage(Symfony\Component\HttpFoundation\File\File $file) - defined in October\Rain\Resize\Resizer. openImage opens a file, detect its mime-type and create an image resource from it.
- protected void retainImageTransparency($img) - defined in October\Rain\Resize\Resizer. retainImageTransparency manipulates an image resource in order to keep.
- protected void setOption(string $option, mixed $value) - defined in October\Rain\Resize\Resizer. setOption sets an individual resizer option.