public void CaptureScreen(Rectangle captureArea) { DisposeGarbage(); // previewBitmaps = new Bitmap[1]; workingBitmaps = new Bitmap[1]; workingBitmaps[0] = bp.ScreenToBitmap(captureArea); ImgType = imType.screen; anyImageLoaded = true; }
void LoadGifAsyncComplete(object sender, RunWorkerCompletedEventArgs e) { GifLoadParameters data = e.Result as GifLoadParameters; workingBitmaps = new Bitmap[data.workingBitmaps.Length]; workingBitmaps = data.workingBitmaps; previewBitmaps = new Bitmap[workingBitmaps.Length]; ImgType = imType.gif; anyImageLoaded = true; form.LoadGifComplete(); }
public void LoadStillFromDisk(string path) { DisposeGarbage(); previewBitmaps = new Bitmap[1]; workingBitmaps = new Bitmap[1] { new Bitmap(path) }; if (workingBitmaps[0].Width < form.pixlx || workingBitmaps[0].Height < form.pixly) { workingBitmaps[0] = new Bitmap(workingBitmaps[0], form.pixlx, form.pixly); } ImgType = imType.still; anyImageLoaded = true; }