private System.Drawing.Bitmap SetImageEffect(SlideShowEffect effect, System.Drawing.Bitmap pic, int imageCountPerImage, int loopCount) { if (effect == SlideShowEffect.Swirl && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Swirl(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.Water && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Water(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.Moire && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Moire(pic, EffectValue(imageCountPerImage, loopCount)); } else if (effect == SlideShowEffect.Pixelate && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Pixelate(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.RandomJitter && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.RandomJitter(pic, EffectValue(imageCountPerImage, loopCount)); } else if (effect == SlideShowEffect.TimeWarp && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.TimeWarp(pic, (byte)EffectValue(imageCountPerImage, loopCount), true); } return(pic); }
public SlideShowInfo(string filepath, SlideShowEffect effect) { this.FilePath = filepath; this.Effect = effect; }
private System.Drawing.Bitmap SetImageEffect(SlideShowEffect effect, System.Drawing.Bitmap pic, int imageCountPerImage, int loopCount) { if (effect == SlideShowEffect.Swirl && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Swirl(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.Water && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Water(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.Moire && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Moire(pic, EffectValue(imageCountPerImage, loopCount)); } else if (effect == SlideShowEffect.Pixelate && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.Pixelate(pic, EffectValue(imageCountPerImage, loopCount), true); } else if (effect == SlideShowEffect.RandomJitter && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.RandomJitter(pic, EffectValue(imageCountPerImage, loopCount)); } else if (effect == SlideShowEffect.TimeWarp && EffectImage(imageCountPerImage, loopCount)) { LibImages.BitmapFilter.TimeWarp(pic, (byte)EffectValue(imageCountPerImage, loopCount), true); } return pic; }