C# Class DjvuNet.DjvuPage

TODO: Update summary.
Inheritance: INotifyPropertyChanged
Mostra file Open project: Telavian/DjvuNet Class Usage Examples

Public Methods

Method Description
BuildBitmap ( Graphics rect, int subsample, int align, Bitmap retVal ) : Graphics.System.Drawing.Bitmap
BuildImage ( int subsample = 1 ) : System.Drawing.System.Drawing.Bitmap

Gets the image for the page

BuildPageImage ( ) : System.Drawing.System.Drawing.Bitmap

Gets a complete image for the page

ClearImage ( ) : void

Clears the stored image from memory

DjvuPage ( int pageNumber, DjvuDocument document, DjvuNet.DataChunks.Directory.DirmComponent header, DjvuNet.DataChunks.TH44Chunk thumbnail, DjviChunk includedItems, DjvuNet.DataChunks.FormChunk form ) : System
ExtractThumbnailImage ( ) : System.Drawing.System.Drawing.Bitmap

Extracts a thumbnail image for the page

GetBgPixmap ( DjvuNet.Graphics.Rectangle rect, int subsample, double gamma, DjvuNet.Graphics.PixelMap retval ) : DjvuNet.Graphics.PixelMap

Gets the background pixmap

GetBitmap ( DjvuNet.Graphics.Rectangle rect, int subsample, int align, DjvuNet.Graphics.Bitmap retval ) : DjvuNet.Graphics.Bitmap
GetBitmapList ( DjvuNet.Graphics.Rectangle rect, int subsample, int align, List components ) : DjvuNet.Graphics.Bitmap
GetMap ( DjvuNet.Graphics.Rectangle segment, int subsample, DjvuNet.Graphics.Map retval ) : DjvuNet.Graphics.Map
GetPixelMap ( DjvuNet.Graphics.Rectangle rect, int subsample, double gamma, DjvuNet.Graphics.PixelMap retval ) : DjvuNet.Graphics.PixelMap
GetTextForLocation ( Rectangle rect ) : string

Gets the text for the rectangle location

Preload ( ) : void

Preloads the page

ResizeImage ( System srcImage, int newWidth, int newHeight ) : System.Drawing.System.Drawing.Bitmap

Resizes the image to the new dimensions

ResizeImage ( int newWidth, int newHeight ) : System.Drawing.System.Drawing.Bitmap

Resizes the pages image to the new dimensions

Private Methods

Method Description
ComputeRed ( int w, int h, int rw, int rh ) : int
ConvertDataToImage ( int pixels ) : System.Drawing.System.Drawing.Bitmap

Converts the pixel data to a bitmap image

CreateBlankImage ( Brush imageColor, int width, int height ) : System.Drawing.System.Drawing.Bitmap

Creates a blank image with the given color

GetBackgroundImage ( int subsample, bool resizeImage = false ) : System.Drawing.System.Drawing.Bitmap

Gets the background image for the page

GetForegroundImage ( int subsample, bool resizeImage = false ) : System.Drawing.System.Drawing.Bitmap

Gets the foreground image for the page

GetPixelSize ( BitmapData data ) : int

Gets the pixel size for the pixel data

GetTextImage ( int subsample, bool resizeImage = false ) : System.Drawing.System.Drawing.Bitmap
InvertColor ( int color ) : int

Inverts the color value

InvertColor ( uint color ) : uint

Inverts the color value

InvertImage ( System invertImage ) : System.Drawing.System.Drawing.Bitmap
IsLegalBilevel ( ) : bool
IsLegalCompound ( ) : bool
Stencil ( DjvuNet.Graphics.PixelMap pm, Graphics rect, int subsample, double gamma ) : bool

Method Details

BuildBitmap() public method

public BuildBitmap ( Graphics rect, int subsample, int align, Bitmap retVal ) : Graphics.System.Drawing.Bitmap
rect System.Drawing.Graphics
subsample int
align int
retVal System.Drawing.Bitmap
return Graphics.System.Drawing.Bitmap

BuildImage() public method

Gets the image for the page
public BuildImage ( int subsample = 1 ) : System.Drawing.System.Drawing.Bitmap
subsample int
return System.Drawing.System.Drawing.Bitmap

BuildPageImage() public method

Gets a complete image for the page
public BuildPageImage ( ) : System.Drawing.System.Drawing.Bitmap
return System.Drawing.System.Drawing.Bitmap

ClearImage() public method

Clears the stored image from memory
public ClearImage ( ) : void
return void

DjvuPage() public method

public DjvuPage ( int pageNumber, DjvuDocument document, DjvuNet.DataChunks.Directory.DirmComponent header, DjvuNet.DataChunks.TH44Chunk thumbnail, DjviChunk includedItems, DjvuNet.DataChunks.FormChunk form ) : System
pageNumber int
document DjvuDocument
header DjvuNet.DataChunks.Directory.DirmComponent
thumbnail DjvuNet.DataChunks.TH44Chunk
includedItems DjviChunk
form DjvuNet.DataChunks.FormChunk
return System

ExtractThumbnailImage() public method

Extracts a thumbnail image for the page
public ExtractThumbnailImage ( ) : System.Drawing.System.Drawing.Bitmap
return System.Drawing.System.Drawing.Bitmap

GetBgPixmap() public method

Gets the background pixmap
public GetBgPixmap ( DjvuNet.Graphics.Rectangle rect, int subsample, double gamma, DjvuNet.Graphics.PixelMap retval ) : DjvuNet.Graphics.PixelMap
rect DjvuNet.Graphics.Rectangle
subsample int
gamma double
retval DjvuNet.Graphics.PixelMap
return DjvuNet.Graphics.PixelMap

GetBitmap() public method

public GetBitmap ( DjvuNet.Graphics.Rectangle rect, int subsample, int align, DjvuNet.Graphics.Bitmap retval ) : DjvuNet.Graphics.Bitmap
rect DjvuNet.Graphics.Rectangle
subsample int
align int
retval DjvuNet.Graphics.Bitmap
return DjvuNet.Graphics.Bitmap

GetBitmapList() public method

public GetBitmapList ( DjvuNet.Graphics.Rectangle rect, int subsample, int align, List components ) : DjvuNet.Graphics.Bitmap
rect DjvuNet.Graphics.Rectangle
subsample int
align int
components List
return DjvuNet.Graphics.Bitmap

GetMap() public method

public GetMap ( DjvuNet.Graphics.Rectangle segment, int subsample, DjvuNet.Graphics.Map retval ) : DjvuNet.Graphics.Map
segment DjvuNet.Graphics.Rectangle
subsample int
retval DjvuNet.Graphics.Map
return DjvuNet.Graphics.Map

GetPixelMap() public method

public GetPixelMap ( DjvuNet.Graphics.Rectangle rect, int subsample, double gamma, DjvuNet.Graphics.PixelMap retval ) : DjvuNet.Graphics.PixelMap
rect DjvuNet.Graphics.Rectangle
subsample int
gamma double
retval DjvuNet.Graphics.PixelMap
return DjvuNet.Graphics.PixelMap

GetTextForLocation() public method

Gets the text for the rectangle location
public GetTextForLocation ( Rectangle rect ) : string
rect System.Drawing.Rectangle
return string

Preload() public method

Preloads the page
public Preload ( ) : void
return void

ResizeImage() public method

Resizes the image to the new dimensions
public ResizeImage ( System srcImage, int newWidth, int newHeight ) : System.Drawing.System.Drawing.Bitmap
srcImage System
newWidth int
newHeight int
return System.Drawing.System.Drawing.Bitmap

ResizeImage() public method

Resizes the pages image to the new dimensions
public ResizeImage ( int newWidth, int newHeight ) : System.Drawing.System.Drawing.Bitmap
newWidth int
newHeight int
return System.Drawing.System.Drawing.Bitmap