Bitmap Clipping
C#
1
Posts
1
Posters
0
Views
1
Watching
-
Hi, I am try to clip the invisible area of a bit map. I have tried the following code. 1.Bitmap bmp = new Bitmap(100, 100); // create a bitmap 2.Graphics bmpG = Graphics.FromImage(bmp); // graphics handler to bitmap 3.bmpG.DrawRectangle(new Pen(Color.Blue), new Rectangle(1000, 1000, 99, 99)); Notice line 3, it allow me to draw the rectangle beyond the bitmap. The size of bitmap is 100 X 100 and I have drawn a rectangle at the location 1000, 1000. In think the device contexts automatically manage it. My question is that can I see the region that is not visible. Actually I want to clip the region in which my rectangle is situated. And want to show it when the user scroll. Please guide me I will b thankful. Regards,