Exemplo n.º 1
0
	// Constructor.
	public DrawingImage(Screen screen, DotGNU.Images.Image image, int frame)
		: base(image, frame)
			{
				this.screen = screen;
				base.frame = frame;
				base.image = image;
				ImageChanged();
			}
	// Create a toolkit image from the properties in the specified object.
	public override IToolkitImage CreateImage
				(DotGNU.Images.Image image, int frame)
			{
				return new PostscriptImage(image, frame);
			}
Exemplo n.º 3
0
	internal Image(DotGNU.Images.Image dgImage)
			{
				SetDGImage(dgImage);
			}
Exemplo n.º 4
0
	// Set the dgImage field within this object.
	internal void SetDGImage(DotGNU.Images.Image dgImage)
			{
				flags = 0;
			#if !ECMA_COMPAT
				switch(dgImage.LoadFormat)
				{
					case DotGNU.Images.Image.Png:
						rawFormat = ImageFormat.Png; break;
					case DotGNU.Images.Image.Jpeg:
						rawFormat = ImageFormat.Jpeg; break;
					case DotGNU.Images.Image.Gif:
						rawFormat = ImageFormat.Gif; break;
					case DotGNU.Images.Image.Tiff:
						rawFormat = ImageFormat.Tiff; break;
					case DotGNU.Images.Image.Bmp:
						rawFormat = ImageFormat.Bmp; break;
					case DotGNU.Images.Image.Icon:
						rawFormat = ImageFormat.Icon; break;
					case DotGNU.Images.Image.Exif:
						rawFormat = ImageFormat.Exif; break;
				}
				frameDimensionsList = new Guid [0];
				this.dgImage = dgImage;
				// If we are loading an icon, set the size of the image
				// to the size of the first icon
				if (rawFormat == ImageFormat.Icon)
				{
					width = dgImage.GetFrame(0).Width;
					height = dgImage.GetFrame(0).Height;
				}
				else
				{
					width = dgImage.Width;
					height = dgImage.Height;
				}
			#else
				this.dgImage = dgImage;
				width = dgImage.GetFrame(0).Width;
				height = dgImage.GetFrame(0).Height;
			#endif
				horizontalResolution = Graphics.DefaultScreenDpi;
				verticalResolution = Graphics.DefaultScreenDpi;
				pixelFormat = (System.Drawing.Imaging.PixelFormat)
					(dgImage.PixelFormat);
			}
Exemplo n.º 5
0
	internal Bitmap(DotGNU.Images.Image image) : base(image) {}
	public IToolkitImage CreateImage(DotGNU.Images.Image image, int frame)
			{
				return new DrawingImage
					(app.Display.DefaultScreenOfDisplay, image, frame);
			}
	public IToolkitImage CreateImage(DotGNU.Images.Image image, int frame)
	{
		return new DrawingImage(image, frame);
	}