Quantcast
Channel: Magick.NET
Viewing all 5763 articles
Browse latest View live

New Post: How do I translate this to Magick.net?

$
0
0
I am sorry, I don't think you understood me correctly and I am not sure if the bug you found relates to my issue. Let me explain again

What i need to do is get the difference between two images. The following command does exactly what I need:
convert IMG1.png IMG2.png -compose ChangeMask -composite OUTPUT.png 
Now I am trying to accomplish that in Magick.NET, but I fail.

I tried the code You proposed, but in OUTPUT.png I get exactly the same content of IMG1.png
IMG=New MagickImage("IMG1.png")

Mask=New MagickImage("IMG2.png")

IMG.Composite(Mask, Gravity.Center, CompositeOperator.ChangeMask)

IMG.Write("OUTPUT.png")
So, I am not sure if I am doing correctly the translation from the Imagemagick command to Magick.NET

New Post: Resample doesn't seem to work as expected

$
0
0
Wonderful! That's the behavior I was seeing as well (forgot to update the topic after re-testing).

Looking forward to the next build! Thanks again!

Reviewed: Magick.NET 7.0.0.0007 (Dec 17, 2014)

$
0
0
Rated 5 Stars (out of 5) - While this is an Alpha release, it works very well and very reliably. The couple small issues I've found have been quickly resolved by the project's developer, who is very responsive and helpful in addressing questions and issues. I'm using Magick.NET it in a touchscreen web-based design app, where users can add, scale, rotate and position images and text on screen, and then I render it all to a high-resolution printable file.

New Post: How do I translate this to Magick.net?

$
0
0
I don't know if this will help you or not, but there have been a lot of changes in ImageMagick version 7 that are great for making things more consistent but work a bit different than version 6. If you are comparing to output of a version 6 command line convert command you might try dropping back to an older Magick.Net version built on IM 6 since he is saying this is a bug in V7

New Post: How do I translate this to Magick.net?

$
0
0
jbleach wrote:
I don't know if this will help you or not, but there have been a lot of changes in ImageMagick version 7 that are great for making things more consistent but work a bit different than version 6. If you are comparing to output of a version 6 command line convert command you might try dropping back to an older Magick.Net version built on IM 6 since he is saying this is a bug in V7
Ah, this could be it.. I just now realized my IM is ver 6, while the one in Magick.NET is 7...

Reverting back to previous Magick.NET is not a solution for me as there is difference in some of the filters I use.. will wait for Dirk to see if we can get this going with the newest version

New Post: Image transparency and opacity issue.

$
0
0
I'm currently having an issue where the transparent portion of a PNG is turning gray when I adjust the opacity of the image. The following code replicates the issue I'm having in my application:
MagickImage img = new MagickImage(responseStream);

double opacitySetting = Quantum.Max / (Quantum.Max * 0.5);
img.Alpha(AlphaOption.Set);
img.Evaluate(Channels.Alpha, EvaluateOperator.Set, Quantum.Max / opacitySetting);

MagickImage tiles = new MagickImage(new FileInfo("C:\\bar.png"));
MagickImage canvas = new MagickImage(Color.Transparent, tiles.Width, tiles.Height);

canvas.Composite(tiles, Gravity.Center, CompositeOperator.Atop);
canvas.Composite(img, Gravity.Center, CompositeOperator.Atop);

byte[] bytes = canvas.ToByteArray(MagickFormat.Png);
using (Stream fileStream = File.Create("C:\\foo.png"))
{
   fileStream.Write(bytes, 0, bytes.Length);
}
The above produces this image where instead it should look like this (with more transparency in the overlay). Does this have anything to do with this issue?

Thanks in advance for any help!

New Post: Multilayer psd, png with transparency displayed with errors/wrong colors

New Post: Need some help about crashes..

$
0
0
dlemstra wrote:
Jordi, can you contact me through CodePlex so we can resolve this issue together? We might get a bit more information if you can enable debugging (https://magick.codeplex.com/wikipage?title=Detailed%20debug%20information&referringTitle=Documentation). I will be back next week and reply to your message then if you decide to send me one.
Sorry, I was really busy with some other project. For now we have a task that cleans all the temporary files periodically, and it works for now.
If we decide to investigate further I'll put all the information here.

New Post: tile

$
0
0
The -tile option set the fillpattern of the image. Your command translates to this:
using (MagickImage image = new MagickImage("xc:none", 320, 90))
{
  using (MagickImage tile = new MagickImage("gradient:white-snow4", 1, 90))
  {
    image.StrokeColor = new MagickColor("snow4");
    image.FillColor = new MagickColor("white");
    image.FillPattern = tile;
    Drawable[] draw_this =
    {
       new DrawableRoundRectangle(16, 5, 304, 85, 20, 40)
    };
    image.Draw(draw_this);
  }
  image.Write(@"D:\test.png");
}
I have not tested this with the IM6 version of Magick.NET and you might notice that I use new constructor. This constructor is not yet available in Magick.NET but will be in the next release. We are also working on fixing the transparency issue from your other post (http://magick.codeplex.com/discussions/571560) in ImageMagick. That will be fixed in the next release.

New Post: How do I translate this to Magick.net?

$
0
0
We are having some problems with transparency and the composite method in ImageMagick 7. We are working on fixing this and I will publish a new release after this has been fixed, this might take us a couple of days.

New Post: Image transparency and opacity issue.

$
0
0
That might be related to the other issue. We are having some problems with transparency in ImageMagick 7. We are working on fixing this right now. I will test your code later after that problem has been fixed and get back to you. Can you share a link to your input images so I can reproduce the problem easier? Feel free to contact me trough CodePlex if you don't want to share them publicly.

New Post: How do I translate this to Magick.net?

$
0
0
dlemstra wrote:
We are having some problems with transparency and the composite method in ImageMagick 7. We are working on fixing this and I will publish a new release after this has been fixed, this might take us a couple of days.
Sure, no hurry!

New Post: tile

$
0
0
Thanks much for the quick reply, makes me anxious for the next release if it will fix 2 of my issues!

New Post: .Write() crashes application

$
0
0
Dirk,

Is there something in the .Write() method which saves the image to a file that might not be multithread safe?

My app was crashing few times a day at random and I was thinking it is probably due to any of the filters it uses, however by luck i discovered it is because of the .Write() method. I needed to stop saving images to hdd for few days and noticed since then my app didn't crash even once. When i reenable saving to disk, it starts crashing again at random..

There's no exception or something thrown, directly those windows error reporting messages "this program has stopped working".. and some crash stuff in Magick.net.dll

Since it happens randomly, i don't think it is because of particular image, so i don't think this can be replicated with particular image..

All i am doing in a multithreading environment is generating a random filename string and then using .Write() to save the image

I will appreciate if you have time to look at that part of the code..

New Post: .Write() crashes application

$
0
0
Can you get me a crash dump? This could help me track down the problem. What is your output image format?

New Post: .Write() crashes application

$
0
0
dlemstra wrote:
Can you get me a crash dump? This could help me track down the problem. What is your output image format?
Is a crash dump file automatically generated somewhere or I need to enable it somehow?

I am working only with jpg,png,bmp,gif formats, and at this point I am not able to tell if it crashes at particular format, as the application receives a mix of all these format. I will now try to see if particular format causes the crash by enabling saving only for 1 format and will leave the app running 24 hours and see if it will crash, then will switch to next format and so on.. This way I think i will see if the format matters at all. Will let you know about this within few days

Thanks!

Reviewed: Magick.NET 7.0.0.0007 (Dec 21, 2014)

$
0
0
Rated 5 Stars (out of 5) - Thank you very much! System.Drawing only works partly on Azure Websites and I needed an alternative to convert ICO files to PNGs - and this library really made my day. It took a few minutes of trial and error how to load multi-frame ICO files and access all their images, but it turned out to be very easy with the MagicImageCollection. Really nice API, very useful and both the x86 and x64 version work flawlessly inside Azure Websites when you add Magick.NET over NuGet and simply deploy it - it's just important to have the application pool settings in Azure set to the correct platform. Thanks again for your hard work!

New Post: .Write() crashes application

Created Unassigned: Looking for version x64 for net 4.5 [1326]

$
0
0
Dear,

Where can I find a x64 version in order to use in net 4.5? Or how can I compile to produce those dlls?

Thanks,

Commented Unassigned: Looking for version x64 for net 4.5 [1326]

$
0
0
Dear,

Where can I find a x64 version in order to use in net 4.5? Or how can I compile to produce those dlls?

Thanks,
Comments: ** Comment from web user: dlemstra **

Can you please use the discussion (https://magick.codeplex.com/discussions) next time when you have a question?

You can just use the .NET 4.0 build of Magick.NET you can find on the download page: https://magick.codeplex.com/releases.

Viewing all 5763 articles
Browse latest View live


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