Today I encountered a task - I needed to resize and apply auto level on a batch of images. In the past, I would just open Gimp or Photoshop and process those images one by one (fortunately I never had to do it on more than a couple of dozens of images). However this time I had way too many files and I thought to myself - we are doing a top-notch imaging software, why not to use it to make my life easier?
I heard that it is possible to use .NET components with PowerShell which is created for the tasks like that, but I did not have any experience with it before. I used to write some .bat files and even creates some WSH scripts in the past, so I prepared to the worst, but after reading a couple of tutorials, I was really amazed how easy to do it! So I could not resist to a temptation to share my experience here in my blog.
As you can see the code is very clear and straghtforward. The PowerShell syntax is very easy to understand (comparing to a quite complicated C#). Just insert a single line to connect Graphics Mill to the script and you are ready to use it!
If you would like to play with it, just create a plain text file: