Quantcast
Channel: magick Discussions Rss Feed
Viewing all articles
Browse latest Browse all 3693

New Post: Is MagickImage thread safe for reading?

$
0
0

Thank you!

19 марта 2015 г. 20:20 пользователь "dlemstra" <[email removed]> написал:

From: dlemstra

Reading from a MagickImage is thread safe. You can do the following without any problems:
using (MagickImage watermark = new MagickImage(@"C:\watermark.png"))
{
  Parallel.ForEach(Directory.GetFiles(@"c:\input", "*.png"), (string fileName) =>
  {using (MagickImage image = new MagickImage(fileName))
    {
      image.Composite(watermark, CompositeOperator.Over);
      image.Write(@"c:\output\uniquefilename.png");
    }
  });
}

Read the full discussion online.

To add a post to this discussion, reply to this email ([email removed])

To start a new discussion for this project, email [email removed]

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com


Viewing all articles
Browse latest Browse all 3693

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>