php - Can anyone explain discoloration after saving a local copy of a GD image? -


So I'm working on a GD image modifier, due to a lack of a better word, loads in JPEG, adds some

I have achieved all of them, and it seems that this is doing amazing work.

There is a problem here - after I got pulled into a browser, if I go to save the image in my system, it comes out with some serious discoloration. Blues turn into purple, for example.

  $ TemplatePath = "template / $ agency / jpg /" $ agency "_" $ TemplateAffinity "_Template.jpg"; $ Image = image frame framespag ($ TemplatePath); $ FontColor = imagecolorallocate ($ image, 255, 255, 255); $ Shadow-color = painter's request ($ image, 0,0,0); $ Fontosiz = 20; ImageFactory ($ image, $ fontSize, 0, $ margin less + 3, $ margin top + 3, shadow color, "c: / windows / font / gotham-bold .tft", $ item text); ImageFacex ($ image, $ fontSize, 0, $ margin lift, $ margin top, $ fontolar, "c: / windows / font / gotham-bold.TTF", $ item text); Header ("content-dispute: inline; filename = test"); // Header ("Content-Disposal: Attachment; Filename = Test"); Header ("Content-Type: Image / JPEG"); Imagejpeg ($ Image, Null, 100);  

This code works all the way I expect; The image is clearly visible in the appropriate colors in the browser crystal, but as I said - when I save a local copy, I get some serious discoloration issues.

Thoughts or suggestions greatly appreciated We do. Thank you.


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -