ImageResizer
3.4.0
|
Provides methods for generating resized images, and for reading and writing them to disk. Use ImageBuilder.Current to get the current instance (as configured in the application configuration), or use ImageBuilder.Current.Create() to control which extensions are used. More...
Public Member Functions | |
ImageBuilder (IEnumerable< BuilderExtension > extensions, IEncoderProvider encoderProvider, IVirtualImageProvider virtualFileProvider, ISettingsModifier settingsModifier) | |
Create a new instance of ImageBuilder using the specified extensions, encoder provider, file provider, and settings filter. Extension methods will be fired in the order they exist in the collection. More... | |
virtual ImageBuilder | Create (IEnumerable< BuilderExtension > extensions, IEncoderProvider writer, IVirtualImageProvider virtualFileProvider, ISettingsModifier settingsModifier) |
Creates another instance of the class using the specified extensions. Subclasses should override this and point to their own constructor. More... | |
virtual ImageBuilder | Copy () |
Copies the instance along with extensions. Subclasses must override this. More... | |
virtual Bitmap | LoadImage (object source, ResizeSettings settings) |
Loads a Bitmap from the specified source. If a filename is available, it will be attached to bitmap.Tag in a BitmapTag instance. The Bitmap.Tag.Path value may be a virtual, relative, UNC, windows, or unix path. Does not dispose 'source' if it is a Stream or Image instance - that's the responsibility of the calling code. More... | |
virtual IDictionary< string, object > | LoadImageInfo (object source, IEnumerable< string > requestedInfo) |
Returns a dictionary of information about the given image. More... | |
virtual Bitmap | LoadImage (object source, ResizeSettings settings, bool restoreStreamPos) |
Loads a Bitmap from the specified source. If a filename is available, it will be attached to bitmap.Tag in a BitmapTag instance. The Bitmap.Tag.Path value may be a virtual, relative, UNC, windows, or unix path. Does not dispose 'source' if it is a Stream or Image instance - that's the responsibility of the calling code. More... | |
override Bitmap | DecodeStream (Stream s, ResizeSettings settings, string optionalPath) |
Decodes the stream into a System.Drawing.Bitmap instance. As of 3.0.7, now ensures the stream can safely be closed after the method returns. May copy the stream. The copied stream will be in b.Tag.Source. Does not close or dispose any streams. More... | |
Stream | GetStreamFromSource (object source, ResizeSettings settings, ref bool disposeStream, out string path, out bool restoreStreamPosition) |
For plugin use only. Returns a stream instance from the specified source object and settings object. To exend this method, override GetStream. More... | |
virtual Bitmap | Build (object source, ResizeSettings settings) |
Resizes and processes the specified source image and returns a bitmap of the result. Note! This method assumes that transparency will be supported in the final output format, and therefore does not apply a matte color. Use &bgcolor to specify a background color if you use this method with a non-transparent format such as Jpeg. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior. More... | |
virtual Bitmap | Build (object source, ResizeSettings settings, bool disposeSource) |
Resizes and processes the specified source image and returns a bitmap of the result. Note! This method assumes that transparency will be supported in the final output format, and therefore does not apply a matte color. Use &bgcolor to specify a background color if you use this method with a non-transparent format such as Jpeg. More... | |
virtual void | Build (object source, object dest, ResizeSettings settings) |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior. More... | |
virtual ImageJob | Build (object source, object dest, Instructions instructions) |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior. More... | |
virtual void | Build (object source, object dest, ResizeSettings settings, bool disposeSource) |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will not be disposed unless disposeSource=true. More... | |
virtual string | Build (object source, object dest, ResizeSettings settings, bool disposeSource, bool addFileExtension) |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will not be disposed unless disposeSource=true. If passed a path destination, the physical path of the written file will be returned. More... | |
virtual ImageJob | Build (ImageJob job) |
The most flexible method for processing an image More... | |
virtual void | Process (ImageState s) |
Processes an ImageState instance. Used by Build, GetFinalSize, and TranslatePoint. Can be overriden by a plugin with the OnProcess method More... | |
virtual PointF[] | TranslatePoints (PointF[] sourcePoints, Size originalSize, ResizeSettings q) |
Doesn't support flipping. Translate a point on the original bitmap to a point on the new bitmap. If the original point no longer exists, returns Empty More... | |
virtual Size | GetFinalSize (Size originalSize, ResizeSettings q) |
Gets the final size of an image More... | |
virtual Size | GetFinalSize (Size originalSize, Instructions q) |
Gets the final size of an image More... | |
virtual IEnumerable< string > | GetSupportedFileExtensions () |
Returns a list of the file extensions ImageBuilder can load by default. Plugins can implement IFileExtensionPlugin to add new ones. More... | |
virtual IEnumerable< string > | GetSupportedQuerystringKeys () |
Returns a list of the querystring commands ImageBuilder can parse by default. Plugins can implement IQuerystringPlugin to add new ones. More... | |
Public Member Functions inherited from ImageResizer.Resizing.AbstractImageProcessor | |
AbstractImageProcessor () | |
Creates a new AbstractImageProcessor with no extensions More... | |
AbstractImageProcessor (IEnumerable< BuilderExtension > extensions) | |
Creates a new AbstractImageProcessor which will run the specified extensions with each method call. More... | |
virtual Bitmap | DecodeStreamFailed (Stream s, ResizeSettings settings, string optionalPath) |
Extensions are executed until one extension returns a non-null value. This is taken to mean that the error has been resolved. Extensions should not throw an exception unless they wish to cause subsequent extensions to not execute. If extensions throw an ArgumentException or ExternalException, it will be wrapped in an ImageCorruptedException instance. If the Bitmap class is used for decoding, read gdi-bugs.txt and make sure you set b.Tag to new BitmapTag(optionalPath,stream); More... | |
Protected Member Functions | |
ImageBuilder () | |
Shouldn't be used except to make a factory instance. More... | |
override RequestedAction | BuildJob (ImageJob job) |
override RequestedAction | buildToStream (Bitmap source, Stream dest, ResizeSettings settings) |
Override this when you need to override the behavior of image encoding and/or Bitmap processing Not for external use. Does NOT dispose of 'source' or 'source's underlying stream. More... | |
override Bitmap | buildToBitmap (Bitmap source, ResizeSettings settings, bool transparencySupported) |
Override this when you need to override the behavior of Bitmap processing. Not for external use. Does NOT dispose of 'source' or 'source's underlying stream. More... | |
override RequestedAction | Layout (ImageState s) |
Process.3: Handles the layout phase of Processing More... | |
override RequestedAction | Render (ImageState s) |
Handles the rendering phase of processing More... | |
override RequestedAction | PrepareSourceBitmap (ImageState s) |
Process.1 Switches the bitmap to the correct frame or page, and applies source flipping commands More... | |
override RequestedAction | LayoutPadding (ImageState s) |
Process.3(Layout).4: Ring "padding" is added to the layout More... | |
override RequestedAction | LayoutMargin (ImageState s) |
Process.3(Layout).10: Margins are added to the layout More... | |
override RequestedAction | LayoutBorder (ImageState s) |
Process.3(Layout).6: Ring "border" is added to the layout More... | |
override RequestedAction | LayoutRound (ImageState s) |
Process.3(Layout).anytime: Occurs when the layout point values are rounded to integers. May be called anytime during Layout() More... | |
override RequestedAction | LayoutRotate (ImageState s) |
Process.3(Layout).anytime: Occurs when the layout is rotated. May be called anytime during Layout() More... | |
override RequestedAction | LayoutNormalize (ImageState s) |
Process.3(Layout).anytime: Occurs when the layout is normalized to 0,0. May be called anytime during Layout() More... | |
override RequestedAction | EndLayout (ImageState s) |
Process.3(Layout).12: Occurs once layout has finished. No more changes should occur to points or rings in the layout after this method. destSize is calculated here. More... | |
override RequestedAction | PrepareDestinationBitmap (ImageState s) |
Creates a bitmap of s.destSize dimensions, intializes a graphics object for it, and configures all the default settings. More... | |
override RequestedAction | RenderBackground (ImageState s) |
Sets the background color if needed or requested More... | |
override RequestedAction | RenderPadding (ImageState s) |
Process.5(Render).5 Image padding is drawn More... | |
override RequestedAction | CreateImageAttribues (ImageState s) |
Process.5(Render).7: An ImageAttributes instance is created if it doesn't already exist. More... | |
override RequestedAction | RenderImage (ImageState s) |
Process.5(Render).10: The image is copied to the destination parallelogram specified by ring 'image'. More... | |
override RequestedAction | RenderBorder (ImageState s) |
Process.5(Render).12: The border is rendered More... | |
override RequestedAction | FlushChanges (ImageState s) |
Process.5(Render).17: Changes are flushed to the bitmap here and the graphics object is destroyed. More... | |
override RequestedAction | ProcessFinalBitmap (ImageState s) |
Process.6: Non-rendering changes to the bitmap object occur here, such as flipping. The graphics object is unavailable. More... | |
override RequestedAction | LayoutImage (ImageState s) |
Populates copyRect, as well as Rings image and imageArea. Translates and scales any existing rings as if they existed on the original bitmap. More... | |
Protected Member Functions inherited from ImageResizer.Resizing.AbstractImageProcessor | |
virtual void | PreLoadImage (ref object source, ref string path, ref bool disposeSource, ref ResizeSettings settings) |
Extend this to allow additional types of source objects to be accepted by transforming them into Bitmap instances. More... | |
virtual Stream | GetStream (object source, ResizeSettings settings, ref bool disposeStream, out string path, out bool restoreStreamPosition) |
Extend this to allow additional types of source objects to be accepted by transforming them into Stream instances. First plugin to return a Stream wins. More... | |
virtual RequestedAction | PostDecodeStream (ref Bitmap img, ResizeSettings settings) |
Extend this to modify the Bitmap instance after it has been decoded by DecodeStream or DecodeStreamFailed More... | |
virtual void | PreAcquireStream (ref object dest, ResizeSettings settings) |
Extend this to allow additional types of destination objects to be accepted by transforming them into a stream. More... | |
virtual RequestedAction | BuildJob (ImageResizer.ImageJob job) |
The method to override if you want to replace the entire pipeline. All Build() calls call this method first. Does nothing in ImageBuilder More... | |
virtual RequestedAction | OnProcess (ImageState s) |
Process.0 First step of the Process() method. Can replace the entire Process method if RequestAction.Cancel is returned. Can be used to add points to translate (for image maps), and also to modify the settings More... | |
virtual RequestedAction | PostPrepareSourceBitmap (ImageState s) |
Process.2 Extend this to apply any pre-processing to the source bitmap that needs to occur before Layout begins More... | |
virtual RequestedAction | FlipExistingPoints (ImageState s) |
Process.3(Layout).1: This is where the points in the layout are flipped the same way the source bitmap was flipped (unless their flags specify otherwise) More... | |
virtual RequestedAction | PostLayoutImage (ImageState s) |
Process.3(Layout).3: Add rings here to insert them between the image area and the padding More... | |
virtual RequestedAction | PostLayoutPadding (ImageState s) |
Process.3(Layout).5: Add rings here to insert them between the padding and the border More... | |
virtual RequestedAction | PostLayoutBorder (ImageState s) |
Process.3(Layout).7: Add rings here to insert them between the border and the effect rings More... | |
virtual RequestedAction | LayoutEffects (ImageState s) |
Process.3(Layout).8: Effects such as 'shadow' are added here. More... | |
virtual RequestedAction | PostLayoutEffects (ImageState s) |
Process.3(Layout).9: Add rings here to insert them between the effects and the margin More... | |
virtual RequestedAction | PostLayoutMargin (ImageState s) |
Process.3(Layout).11: Add rings here to insert them around the margin. Rings will be outermost More... | |
virtual RequestedAction | PostLayoutRotate (ImageState s) |
Process.3(Layout).anytime: Occurs after the layout is rotated. May be called anytime during Layout() More... | |
virtual RequestedAction | PostLayoutNormalize (ImageState s) |
Process.3(Layout).anytime: Occurs after the layout is normalized. May be called anytime during Layout() More... | |
virtual RequestedAction | PostLayoutRound (ImageState s) |
Process.3(Layout).anytime: Occurs after the layout point values are rounded to integers. May be called anytime during Layout() More... | |
virtual RequestedAction | PostRenderBackground (ImageState s) |
Process.5(Render).2 After the background color is rendered More... | |
virtual RequestedAction | RenderEffects (ImageState s) |
Process.5(Render).3 Effects (such as a drop shadow or outer glow) are rendered More... | |
virtual RequestedAction | PostRenderEffects (ImageState s) |
Process.5(Render).4 After outer effects are rendered More... | |
virtual RequestedAction | PostRenderPadding (ImageState s) |
Process.5(Render).6 After image padding is drawn More... | |
virtual RequestedAction | PostCreateImageAttributes (ImageState s) |
Process.5(Render).8: The ImageAttributes instance exists and can be modified or replaced. More... | |
virtual RequestedAction | PreRenderImage (ImageState s) |
Process.5(Render).9: Plugins have a chance to pre-process the source image before it gets rendered, and save it to s.preRenderBitmap More... | |
virtual RequestedAction | PostRenderImage (ImageState s) |
Process.5(Render).11: After the image is drawn More... | |
virtual RequestedAction | PostRenderBorder (ImageState s) |
Process.5(Render).13: After the border is drawn More... | |
virtual RequestedAction | PreRenderOverlays (ImageState s) |
Process.5(Render).14: Any last-minute changes before watermarking or overlays are applied More... | |
virtual RequestedAction | RenderOverlays (ImageState s) |
Process.5(Render).15: Watermarks can be rendered here. All image processing should be done More... | |
virtual RequestedAction | PreFlushChanges (ImageState s) |
Process.5(Render).16: Called before changes are flushed and the graphics object is destroyed. More... | |
virtual RequestedAction | PostFlushChanges (ImageState s) |
Process.5(Render).18: Changes have been flushed to the bitmap, but the final bitmap has not been flipped yet. More... | |
virtual RequestedAction | EndProcess (ImageState s) |
Process.7: Layout and rendering are both complete. More... | |
Protected Attributes | |
IEncoderProvider | _encoderProvider = null |
ISettingsModifier | _settingsModifier = null |
Protected Attributes inherited from ImageResizer.Resizing.AbstractImageProcessor | |
volatile IEnumerable < BuilderExtension > | exts |
Contains the set of extensions that are called for every method. More... | |
Properties | |
IEncoderProvider | EncoderProvider [get] |
Handles the encoder selection and provision proccess. More... | |
ISettingsModifier | SettingsModifier [get] |
May be null. A class to modify or normalize ResizeSettings instances before they are used. More... | |
IVirtualImageProvider | VirtualFileProvider [get] |
Provides a resolution service for app-relative URLs. More... | |
static ImageBuilder | Current [get] |
Returns a shared instance of ImageBuilder or a subclass, equivalent to Config.Current.CurrentImageBuilder More... | |
Provides methods for generating resized images, and for reading and writing them to disk. Use ImageBuilder.Current to get the current instance (as configured in the application configuration), or use ImageBuilder.Current.Create() to control which extensions are used.
Definition at line 27 of file ImageBuilder.cs.
|
inlineprotected |
Shouldn't be used except to make a factory instance.
Definition at line 32 of file ImageBuilder.cs.
Referenced by ImageResizer.ImageBuilder.Copy(), and ImageResizer.ImageBuilder.Create().
|
inline |
Create a new instance of ImageBuilder using the specified extensions, encoder provider, file provider, and settings filter. Extension methods will be fired in the order they exist in the collection.
extensions | |
encoderProvider | |
settingsModifier | |
virtualFileProvider |
Definition at line 68 of file ImageBuilder.cs.
|
inlinevirtual |
Resizes and processes the specified source image and returns a bitmap of the result. Note! This method assumes that transparency will be supported in the final output format, and therefore does not apply a matte color. Use &bgcolor to specify a background color if you use this method with a non-transparent format such as Jpeg. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior.
source | May be an instance of string (a physical path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. |
settings | Resizing and processing command to apply to the. |
Definition at line 319 of file ImageBuilder.cs.
Referenced by ImageResizer.ImageBuilder.LoadImageInfo().
|
inlinevirtual |
Resizes and processes the specified source image and returns a bitmap of the result. Note! This method assumes that transparency will be supported in the final output format, and therefore does not apply a matte color. Use &bgcolor to specify a background color if you use this method with a non-transparent format such as Jpeg.
If passed a source Stream, Bitmap, or Image instance, it will not be disposed unless disposeSource=true.
source | May be an instance of string (a physical path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. |
settings | Resizing and processing command to apply to the. |
disposeSource | If false, 'source' will not be disposed. |
Definition at line 334 of file ImageBuilder.cs.
|
inlinevirtual |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior.
source | May be an instance of string (a physical path or app-relative virtual path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. App-relative virtual paths will use the VirtualPathProvider system |
dest | May be a physical path (string), or a Stream instance. Does not have to be seekable. |
settings | Resizing and processing command to apply to the image. |
Definition at line 347 of file ImageBuilder.cs.
|
inlinevirtual |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will be disposed after use. Use disposeSource=False to disable that behavior.
source | May be an instance of string (a physical path or app-relative virtual path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. App-relative virtual paths will use the VirtualPathProvider system |
dest | May be a physical path (string), or a Stream instance. Does not have to be seekable. |
instructions | Resizing and processing command to apply to the image. |
Definition at line 358 of file ImageBuilder.cs.
|
inlinevirtual |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will not be disposed unless disposeSource=true.
source | May be an instance of string (a physical path or app-relative virtual path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. App-relative virtual paths will use the VirtualPathProvider system |
dest | May be a physical path (string), or a Stream instance. Does not have to be seekable. |
settings | Resizing and processing command to apply to the image. |
disposeSource | True to dispose 'source' after use. False to leave intact. |
Definition at line 373 of file ImageBuilder.cs.
|
inlinevirtual |
Resizes and processes the specified source image and stores the encoded result in the specified destination. If passed a source Stream, Bitmap, or Image instance, it will not be disposed unless disposeSource=true. If passed a path destination, the physical path of the written file will be returned.
source | May be an instance of string (a physical path or app-relative virtual path), VirtualFile, IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. App-relative virtual paths will use the VirtualPathProvider system |
dest | May be a physical path (string), or a Stream instance. Does not have to be seekable. |
settings | Resizing and processing command to apply to the image. |
disposeSource | True to dispose 'source' after use. False to leave intact. |
addFileExtension | If true, will add the correct file extension to 'dest' if it is a string. |
Definition at line 390 of file ImageBuilder.cs.
The most flexible method for processing an image
job |
Definition at line 400 of file ImageBuilder.cs.
|
inlineprotected |
They only want information/attributes
Definition at line 421 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Override this when you need to override the behavior of Bitmap processing. Not for external use. Does NOT dispose of 'source' or 'source's underlying stream.
source | |
settings | |
transparencySupported | True if the output method will support transparency. If false, the image should be provided a matte color |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 536 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Override this when you need to override the behavior of image encoding and/or Bitmap processing Not for external use. Does NOT dispose of 'source' or 'source's underlying stream.
source | |
dest | |
settings |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 516 of file ImageBuilder.cs.
|
inlinevirtual |
Copies the instance along with extensions. Subclasses must override this.
Definition at line 90 of file ImageBuilder.cs.
|
inlinevirtual |
Creates another instance of the class using the specified extensions. Subclasses should override this and point to their own constructor.
extensions | |
writer | |
virtualFileProvider | |
settingsModifier |
Definition at line 83 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.5(Render).7: An ImageAttributes instance is created if it doesn't already exist.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 829 of file ImageBuilder.cs.
|
inlinevirtual |
Decodes the stream into a System.Drawing.Bitmap instance. As of 3.0.7, now ensures the stream can safely be closed after the method returns. May copy the stream. The copied stream will be in b.Tag.Source. Does not close or dispose any streams.
s | |
settings | |
optionalPath |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 210 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).12: Occurs once layout has finished. No more changes should occur to points or rings in the layout after this method. destSize is calculated here.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 735 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.5(Render).17: Changes are flushed to the bitmap here and the graphics object is destroyed.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 895 of file ImageBuilder.cs.
|
inlinevirtual |
Gets the final size of an image
Definition at line 947 of file ImageBuilder.cs.
|
inlinevirtual |
Gets the final size of an image
Definition at line 956 of file ImageBuilder.cs.
|
inline |
For plugin use only. Returns a stream instance from the specified source object and settings object. To exend this method, override GetStream.
source | The physical or app-relative path, or a VirtualFile, IVirtualFile, Stream, HttpPostedFile, or HttpPostedFileBase instance. |
settings | Querystring settings to pass to the VirtualFileProvider |
disposeStream | You should externally initialize this to true, unless the user-provided 'source' is a Stream instance. Will be set to false for HttpPostedFile and HttpPostedFileBase instances, so they can be reused. |
path | The physical or virtual path associated with the stream (if present). Otherwise null |
restoreStreamPosition | True if you should save and restore the seek position of the stream. True for HttpPostedFile and HttpPostedFileBase instances. |
Definition at line 235 of file ImageBuilder.cs.
Referenced by ImageResizer.ImageBuilder.LoadImage().
|
inlinevirtual |
Returns a list of the file extensions ImageBuilder can load by default. Plugins can implement IFileExtensionPlugin to add new ones.
Implements ImageResizer.Plugins.IFileExtensionPlugin.
Definition at line 1137 of file ImageBuilder.cs.
|
inlinevirtual |
Returns a list of the querystring commands ImageBuilder can parse by default. Plugins can implement IQuerystringPlugin to add new ones.
Implements ImageResizer.Plugins.IQuerystringPlugin.
Definition at line 1154 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3: Handles the layout phase of Processing
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 575 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).6: Ring "border" is added to the layout
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 699 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Populates copyRect, as well as Rings image and imageArea. Translates and scales any existing rings as if they existed on the original bitmap.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 972 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).10: Margins are added to the layout
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 689 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).anytime: Occurs when the layout is normalized to 0,0. May be called anytime during Layout()
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 726 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).4: Ring "padding" is added to the layout
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 679 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).anytime: Occurs when the layout is rotated. May be called anytime during Layout()
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 719 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.3(Layout).anytime: Occurs when the layout point values are rounded to integers. May be called anytime during Layout()
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 711 of file ImageBuilder.cs.
|
inlinevirtual |
Loads a Bitmap from the specified source. If a filename is available, it will be attached to bitmap.Tag in a BitmapTag instance. The Bitmap.Tag.Path value may be a virtual, relative, UNC, windows, or unix path. Does not dispose 'source' if it is a Stream or Image instance - that's the responsibility of the calling code.
source | May be an instance of string, VirtualFile, IVirtualFile IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. If passed an Image instance, the image will be cloned, which will cause metadata, indexed state, and any additional frames to be lost. Accepts physical paths and application relative paths. (C:... and ~/path) |
settings | Will ignore ICC profile if ?ignoreicc=true. |
Definition at line 104 of file ImageBuilder.cs.
|
inlinevirtual |
Loads a Bitmap from the specified source. If a filename is available, it will be attached to bitmap.Tag in a BitmapTag instance. The Bitmap.Tag.Path value may be a virtual, relative, UNC, windows, or unix path. Does not dispose 'source' if it is a Stream or Image instance - that's the responsibility of the calling code.
source | May be an instance of string, VirtualFile, IVirtualFile IVirtualBitmapFile, HttpPostedFile, Bitmap, Image, or Stream. If passed an Image instance, the image will be cloned, which will cause metadata, indexed state, and any additional frames to be lost. Accepts physical paths and application relative paths. (C:... and ~/path) |
settings | Will ignore ICC profile if ?ignoreicc=true. |
restoreStreamPos | If true, the position of the source stream will be restored after being read |
Definition at line 127 of file ImageBuilder.cs.
|
inlinevirtual |
Returns a dictionary of information about the given image.
source | |
requestedInfo | Pass null to get the defaults ("source.width", source.height") |
Definition at line 114 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Creates a bitmap of s.destSize dimensions, intializes a graphics object for it, and configures all the default settings.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 749 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.1 Switches the bitmap to the correct frame or page, and applies source flipping commands
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 629 of file ImageBuilder.cs.
|
inlinevirtual |
Processes an ImageState instance. Used by Build, GetFinalSize, and TranslatePoint. Can be overriden by a plugin with the OnProcess method
s |
Definition at line 561 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.6: Non-rendering changes to the bitmap object occur here, such as flipping. The graphics object is unavailable.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 906 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Handles the rendering phase of processing
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 601 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Sets the background color if needed or requested
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 775 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.5(Render).12: The border is rendered
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 857 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.5(Render).10: The image is copied to the destination parallelogram specified by ring 'image'.
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 835 of file ImageBuilder.cs.
|
inlineprotectedvirtual |
Process.5(Render).5 Image padding is drawn
s |
Reimplemented from ImageResizer.Resizing.AbstractImageProcessor.
Definition at line 811 of file ImageBuilder.cs.
|
inlinevirtual |
Doesn't support flipping. Translate a point on the original bitmap to a point on the new bitmap. If the original point no longer exists, returns Empty
Definition at line 934 of file ImageBuilder.cs.
|
staticget |
Returns a shared instance of ImageBuilder or a subclass, equivalent to Config.Current.CurrentImageBuilder
Definition at line 59 of file ImageBuilder.cs.
|
get |
Handles the encoder selection and provision proccess.
Definition at line 37 of file ImageBuilder.cs.
|
get |
May be null. A class to modify or normalize ResizeSettings instances before they are used.
Definition at line 44 of file ImageBuilder.cs.
|
get |
Provides a resolution service for app-relative URLs.
Definition at line 51 of file ImageBuilder.cs.