Search found 19 matches

by GlennIM
2019-06-06T08:01:56-07:00
Forum: Magick.NET
Topic: Trim White Space From Image?
Replies: 2
Views: 251

Re: Trim White Space From Image?

I added this line to the code below and it worked! Is that the correct code to use?

Code: Select all

 image.ColorFuzz = new Percentage(5);
by GlennIM
2019-06-05T22:41:02-07:00
Forum: Magick.NET
Topic: Trim White Space From Image?
Replies: 2
Views: 251

Trim White Space From Image?

I'm trying to remove "white space" from images using the Trim() function but doesn't seem to work. Here is my code and the sourceImgTrimmed. What is wrong? string sourceImg = @"D:\\large_1683_EK08BK_Open_WEB.jpg"; string sourceImgTrimmed = @"D:\\large_1683_EK08BK_Open_Trimmed.jpg"; using (MagickImag...
by GlennIM
2019-05-13T22:02:26-07:00
Forum: Magick.NET
Topic: Creating a Slide Show using MagicK.net ?
Replies: 1
Views: 928

Creating a Slide Show using MagicK.net ?

Is there a way to create a slide show from a series of images using C#, perhaps combining them into a .GIF ?
by GlennIM
2019-04-20T07:50:45-07:00
Forum: Magick.NET
Topic: Permission Denied When Writing Image To File Again
Replies: 0
Views: 2587

Permission Denied When Writing Image To File Again

I'm writing images to a directory on my drive and I put each image I write into Image parameter of a CheckBox control using the code below... Each checkbox is then added to a FlowLayoutPanel control. myCheckBox.Image = Image.FromFile(filetarget); Then when I select the CheckBox control that is in a ...
by GlennIM
2019-04-03T13:04:52-07:00
Forum: Magick.NET
Topic: Freeing Up Memory?
Replies: 0
Views: 2819

Freeing Up Memory?

I have a method that creates several new MagickImage objects and this method gets run many times through the execution of my application. I see the memory increasing rapidly and the application goes into Non-Responding state because it is using a lot of memory. After the method is called I call GC.C...
by GlennIM
2019-03-20T21:25:37-07:00
Forum: Magick.NET
Topic: 3D Effects ?
Replies: 0
Views: 2465

3D Effects ?

I'm trying to convert some of the 3-D logos on https://www.imagemagick.org/Usage/advanced/#3d-logos to C# and don't have a clue how to write the code. Either one of 2 sets of code... convert logo.png -alpha extract -blur 0x6 -shade 110x30 -normalize \ logo.png -compose Overlay -composite \ logo.png ...
by GlennIM
2018-10-31T11:42:05-07:00
Forum: Magick.NET
Topic: C# Code for Frame, adding a 3D-like border ?
Replies: 1
Views: 3448

Re: C# Code for Frame, adding a 3D-like border ?

UPDATE:

Never Mind. It was easy to figure out using the C# API
by GlennIM
2018-10-27T21:01:50-07:00
Forum: Magick.NET
Topic: C# Code for Frame, adding a 3D-like border ?
Replies: 1
Views: 3448

C# Code for Frame, adding a 3D-like border ?

Does anyone have the C# equivalent code for creating 3D Like Borders as shown at http://www.imagemagick.org/Usage/crop/#frame using the frame operator? These specific command line options work but have no clue as to converting them to Magick.NET C# code: D:\>magick imagetotest.jpg -frame 10x10 image...
by GlennIM
2018-10-20T21:41:54-07:00
Forum: Magick.NET
Topic: What Transformation For .JPG Format ?
Replies: 1
Views: 2820

What Transformation For .JPG Format ?

I can only use .JPG image format for my images.

What transformation are possible to use for that format at https://www.imagemagick.org ?

Thanks
by GlennIM
2018-09-03T20:26:18-07:00
Forum: Magick.NET
Topic: Why Is File size SO Much Larger ?
Replies: 3
Views: 4004

Re: Why Is File size SO Much Larger ?

The reason I am writing the file to .PNG is because this function includes code to round the corners of the image. If I write it to .JPG format the rounded corners to show. The whole image is just square but the file size is OK at 198K - Please advise on how I can have rounded corners but use .JPG i...
by GlennIM
2018-09-03T13:36:24-07:00
Forum: Magick.NET
Topic: Why Is File size SO Much Larger ?
Replies: 3
Views: 4004

Why Is File size SO Much Larger ?

When I use var image = new MagickImage(MagickColors.Red, 1000, 1000); the final output file size is 64K but when I use a real image .JPG file of 147K the resulting file is the size of 1.55 MB even after I compress it. Why is the resulting .PNG file so much larger than the original using the code bel...
by GlennIM
2018-09-01T22:44:59-07:00
Forum: Magick.NET
Topic: Best Way To Compress .PNG Image File?
Replies: 1
Views: 3811

Best Way To Compress .PNG Image File?

What is the best way to compress a .PNG format file that ImageMagicK creates to make the image file smaller in size?

ImageOptimizer optimizer = new ImageOptimizer();

optimizer.LosslessCompress(imageMod);

Or...

optimizer.Compress(imageMod);
by GlennIM
2018-08-25T12:02:43-07:00
Forum: Magick.NET
Topic: Dynamically Set FontPointSize for Text?
Replies: 10
Views: 7013

Re: Dynamically Set FontPointSize for Text?

Thank you SO much. I set the Width to the width of the image minus a little to give some padding and it works.

I'm curious, what does setting the Width actually do? Does it "scale" the text?

-Glenn
by GlennIM
2018-08-21T19:25:48-07:00
Forum: Magick.NET
Topic: Dynamically Set FontPointSize for Text?
Replies: 10
Views: 7013

Re: Dynamically Set FontPointSize for Text?

Here is the test image where you can see the text does not size properly inside the rounded corner image on the top and bottom. The code I wrote is below. http://spygearco.net/TestImage.png Yes. Here is the sample code below that produces the image above. Please tell me how I can resize the text wit...
by GlennIM
2018-08-19T11:39:14-07:00
Forum: Magick.NET
Topic: Dynamically Set FontPointSize for Text?
Replies: 10
Views: 7013

Re: Dynamically Set FontPointSize for Text?

I also tried this code and it returns the wrong font point size... static public int MeasureDisplayStringWidth(Graphics graphics, string text, Font font) { System.Drawing.StringFormat format = new System.Drawing.StringFormat(); System.Drawing.RectangleF rect = new System.Drawing.RectangleF(0, 0, 100...