Avatar of accucom
accucom
 asked on

resize image with send to mail recipient - blurry image

Server 2012 R2 fully patched
XenDesktop 7.9
VMware 6
Outlook 2016

Above is our environment.  When I right click a single or multiple image(s) and select Send to Mail Recipient, I change the Picture size to small 800 x 600, it comes out blurry.  all selections for smaller, small, Medium and Large all come out blurry.  If I select Original size, it is fine.  I have an exact same setup at another client and the images come in clear when I resize the picture to small 800 x 600.

I have checked the win.ini file on both of these set ups and they are the same.  The mail recipient.MAPIMail in the SendTo folder is also the same on both servers.  I have been banging my head on this for a few days now.
Windows Server 2012CitrixEmail ClientsOutlook

Avatar of undefined
Last Comment
BillDL

8/22/2022 - Mon
BillDL

Would it be possible to attach one of the original images and the same image after it has been resized?
Davis McCarn

Ditto on what BillDL is asking for.  Having both would go a long way in helping us to understand and analyze your problem.
And watch out for the problem simply being a printing issue or a screen issue.
800X600 is OK for a 4"X3" print, at best and could look quite blurry on 2K monitor.
accucom

ASKER
Attached is the original picture.  Clear as can be.  Also attached is the resized picture created by right clicking on the original image, selecting send to Mail recipient and changing to 800 x 600.  Did the same thing on a exact 2012 r2 server and the 800 x 600 is clear.  This server is replacing a 2008 r2 server which worked correctly.  Thanks for the help.
original.jpg
resized.jpg
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
SOLUTION
Joe Winograd

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
accucom

ASKER
attached is the clear 800 x 600 image from an identical 2012 r2 server with xendesktop installed.
resized.jpg
SOLUTION
Joe Winograd

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
ASKER CERTIFIED SOLUTION
BillDL

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Joe Winograd

> the most significant difference is the compression ratio

Hi Bill,
Thank you for confirming my suspicion that the JPEG compression is different on the two machines. That JPEGsnoop is an awesome tool! I was not aware of it, but it is now in my imaging bag-of-tricks, and a donation to the author is on the way. Really appreciate the heads-up on it! Regards, Joe
accucom

ASKER
thanks for all the help.  I ended up rebuilding the a new server with the same configuration.  I installed software one at a time and tested the sendto feature and so far so good.  They only thing I have not installed are the 140 fonts that are needed for certain users.  I think it may just been a corrupt dll file some how but will not research anymore since I have spent way too much time on this.

Thanks again for all the assistance.
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Joe Winograd

You're welcome. Happy to help. And thanks to you for the update. Regards, Joe
Davis McCarn

Unfortunately; a wipe and reload is not a fix so delete, please!
Joe Winograd

I disagree with the suggestion to delete. There are some good comments in this thread that an EE member would be well-advised to consider when having a similar problem. In other words, a thread like this should be found in the PAQ when a member searches for such a problem.

I recommend that BillDL's excellent post with a link to the JPEGsnoop tool be the Accepted Solution:
https:#a41754571

I recommend that my post (just prior to Bill's) with the comment that JPEG compression is probably the issue be an Assisted Solution:
#a41752936

As a general comment, I believe we should always think beyond the specific question at hand to a broader audience where other members may have the same, or a similar, problem. When the thread has ideas that will help future situations (such as JPEGsnoop in this case), I think we should not delete the question, even if the specific solution in this one particular instance was something different (such as rebuilding the server in this case).

Just one person's opinion. Regards, Joe
Your help has saved me hundreds of hours of internet surfing.
fblack61
Joe Winograd

Good comments that will help other members who have the same, or a similar, problem.
BillDL

Thank you Joe
Joe Winograd

You're welcome, Bill — well-deserved!
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
accucom

ASKER
Ok, thanks for all the help with the issue so far.  Apparently, the rebuild of server fixed the blurry image issue with Send To Mail Recipient but still having a big issue when resizing to the smaller, small or medium size from Send To Mail Recipient.  This has go to be a windows issue as I just built the same XenDesktop 7.9 on a server 2012 r2 running on vCenter with the same Guest parameters and the Send To Mail Recipient works perfectly.  I have attached the original file and also the resized image at small 800 x 600.  I have also attached the resized ph
MH-SQ-251B_Soul-Be-Still-1.jpg
resized-bad.jpg
accucom

ASKER
attached is the same original file that was resized on the another 2012r2 server with XD.  Also, both running on esxi 5.5.
Good-Resized.jpg
Joe Winograd

The original image is 2,467,124 bytes. The "good" resized image is 61,983 bytes; the "bad" is 57,931. In other words, they're both highly compressed, and not a big difference between them. The fantastic tool that Bill introduced us to (JPEGsnoop) says that the compression ratio on the "good" is 17.22:1, while on the "bad" it is 18.61:1 — again, not a big difference between them. In fact, looking at the "good" and "bad" side-by-side, I don't see a difference in the "blurriness", although there's certainly a big difference in the shades of green:

good bad side-by-side
Regards, Joe
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23
accucom

ASKER
thanks Joe.  The blurriness issue was resolved by rebuilding the server from scratch.  Now the issue is resizing and the color after resizing.  Whats crazy is it looks great if you select large or original size, but selecting medium, small or smaller causes the lighter green to show.  It appears it may just affect green and yellow.  My client uses photoshop but insist on being able to right click several images and sent to mail recipient in order to resize as it saves many steps and time.
Joe Winograd

Sorry...misunderstood your comment. So now the issue is color, not blurriness.

> Whats crazy is it looks great if you select large or original size, but selecting medium, small or smaller causes the lighter green to show.

I guess that's because whatever resizing tool it uses is changing the color channels on medium/small/smaller but not on large. I just ran the original through IrfanView and used its feature that allows you to specify the resulting size. I set it at 60KB and it came out to 61,117 bytes and looks fine:

IV-60kb
JPEGsnoop says the compression ratio is 20.80:1. It is not blurry and it is the right color green. I really don't know what to say. Regards, Joe
accucom

ASKER
Thanks Joe,

I am at a loss also.  There isnt much information on the send to feature in windows.  I thought it may be the sendmail.dll in system32.  I compared the registry key with the working 2012 server and all settings are the same.
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
BillDL

I am really puzzled by this issue also.

sendmail.dll is certainly the DLL that is called for the Right-Click > Send To > "Desktop (create shortcut)" and "Mail Recipient" options on any Windows system that I have used, however Server 2012 is not one of those.  I cannot imagine that there should be any significant difference in this respect though.

As to the question of what program actually does the resizing, I'm afraid that I do not know whether sendmail.dll does the processing internally or passes it out to another DLL or EXE.

I DO NOT think that the shared Graphics Filters will have any relationship to this.  Microsoft applications like MS Office (and possibly also Windows applications like MS Paint) use shared graphics filters, and from what I can see they are used to import and unencode and also to export and re-encode to different image formats such as would be done when using the "Save As" option and changing the file type.  An example is:
C:\Program Files\Common Files\Microsoft Shared\GRPHFLT\JPEGIM32.FLT
This is the "JPEG Import/Export Graphic Filter" from the 32-bit XP computer I am currently using, so any comparable filters on recent versions of Windows may be in different locations.  There are filters for GIF and PNG in that same folder.

My gut feeling is that these are not used for the resize process that is causing issues on your system as I believe they are installed by (or updated from Windows default by) Microsoft Office, but I suppose it might be worth comparing the versions on the system that resizes with good results and the one that messes up the images.

The most puzzling thing about the two images is that there is so little difference between the file sizes, the compression ratios, and the bits per pixel values, and it is therefore surprising that there should be such a noticeable difference with the colours.  In my experience, downsizing JPG images has never noticeably altered the shades of colour.  Sometimes they lose sharpness, but I have never experienced such a radical colour change.

Increasing JPEG compression will change the image incrementally until too much noticeably degrades it, but normally the colours are not affected as much as the actual quality of the image.  There is always going to be a change in the luminance between the darkest and lightest pixels, and various other changes, but the difference between your two systems is radical.  It is almost as though a JPG with a rich colour range has been re-encoded as a GIF which supports a more limited range of colours, but that is not the case here.   In fact, the "bad" image that is a lighter shade of green contains 68,540 unique colours, and the one with the darker shade of green contains 65,133 unique colours.  The "Bad" image has a wider colour range than the "Good" one !!

Adjusting the "Gamma" values of an image will change the number of unique colours used.  The gamma of an image is a measure of its contrast and brightness.  The gamma curve has three components: red, green, and blue and is represented by a curve.  Where an image has a colour "cast" (eg. yellow due to halogen lighting), gamma adjustments are used to correct this.  By increasing the green, the "good" image can be made to match the "bad" one's green hue without touching the red and blue, and by decreasing only the green the "bad" image can be made to match the hues of the "good" image.  In each case the number of unique colours is either increased or decreased by approximately the same difference as you currently have between your good and bad images.

Whatever function is doing the resizing and resaving is, in my opinion, messing with the gamma and is adding a green colour cast.  I would be curious to see whether a predominantly red image would become a lighter shade of red, and if a predominantly blue image would become a lighter shade of blue by similar degrees as the green one has been affected, or if this is restricted to green only.  I am not saying that I can pin-point the problem or fix it, I am just curious.