22 Replies Latest reply on Sep 22, 2017 8:24 PM by mcb1

    Blurry image

    shabaz

      Hi,

       

      I'm experiencing a blurry image issue, I've seen this in the past a long time ago, but I don't know what the solution was.

      Basically, I edited a blog post (deleted and inserted an image), but it appears blurry now.

      This is the URL: A First Pi Project: Xmas Trees!

      Here is what it looks like (blurry image on the right):

      blurry.png

      Before I edited it, it was non-blurry and it was sharp:

      non-blurry.png

       

      I see this with multiple browsers, and I've tried opening (and clearing cache) several times in case it is a single server causing this.

      When I look at the page source, I see there is a link to downloadImage and one to showImage. The showImage is correct and sharp, but the downloadImage is blurry.

      What is causing this, and how can I resolve it?

      I ordinarily wouldn't mind if the image was non-essential, but in this case the image contains source code, so a sharp image is preferred.

       

      Many thanks!

        • Re: Blurry image
          dougw

          It looks like it is compressed due to its size.

          If you click on it, it pops up in great clarity....you could add a note to click on it...

          You could also compress it yourself, ensuring it was still legible.

            • Re: Blurry image
              shabaz

              Hi Doug!

               

              It's weird, the compacted image is still usually sharper, and I had a copy of the unmodified image so I reverted back to that (and explicitly set the image size using the html code view back to what it was when the image appeared sharper) but to no avail : ( In other words, I've tried to get back to the situation in the non-blurry screenshot above by reverting to the older image, but it always comes out blurry.

               

              A possible theory (just a guess) is that Jive makes copies of the image in different resolutions (or perhaps different compression) for serving up over slow links maybe and something has gone crazy but I'm not sure what..

               

              As you say clicking on it provides the correct original image which is sharp. It would just be nice to have the image sharp even when unclicked (as in the second screenshot above).

                • Re: Blurry image
                  Dudley Nelson

                  Hi shabaz,

                   

                  You always find interesting issues!

                   

                  I get the problem, but I don't quite get what it was you did to cause it to happen. If I understand it right:

                  • Create a blog post, with images
                  • Remove one of those images
                  • Replace it with a similar image of the exact same dimensions
                  • first image is clear, second is blurry

                   

                  Is that right?

                   

                  If that's right, can you pass me the two images and I'll put them on my local and see if I can get to the bottom of what's going on.

                   

                  Duds

                   

                  (edit: added bullet points)

                  2 of 2 people found this helpful
                    • Re: Blurry image
                      shabaz

                      Hi Dudley,

                       

                      Thanks for investigating! The steps you listed are correct, except that as part of adding images, I also resized them (using the handles after it is highlighted) and also moved it to the right side of the text using the image menu that appears when an image is selected in the editor.

                       

                      Original image that was non-blurry:

                      stick-code.png

                       

                      The updated image which was blurry (and then blurriness was experienced even reverting back to the original image):

                      stick-code2.png

                       

                      When I look at the source for the page that was non-blurry, I see this:

                      </p><h1>Stick Man Deciphered</h1><p><a href="https://www.element14.com/community/servlet/JiveServlet/showImage/38-25719-434320/stick-code.png"><img alt="stick-code.png" class="image-4 jive-image" height="717" src="https://www.element14.com/community/servlet/JiveServlet/downloadImage/38-25719-434320/447-717/stick-code.png" style="float: right; width:447px; height: 716.392px;" width="447"/></a></p><p><span style="font-size: 12pt;">Without knowing

                       

                      And for the page that was blurry:

                      </p><h1>Stick Man Deciphered</h1><p><span style="font-size: 12pt;"><a href="https://www.element14.com/community/servlet/JiveServlet/showImage/38-25719-434461/stick-code2.png"><img alt="stick-code2.png" class="image-7 jive-image" height="717" src="https://www.element14.com/community/servlet/JiveServlet/downloadImage/38-25719-434461/447-717/stick-code2.png" style="float: right; width:447px; height: 716.392px;" width="447"/></a></span></p><p><span style="font-size: 12pt;">Without knowing

                       

                      So, they look identical to me : ( When I experienced the blurriness, I went into the editor HTML source view and manually set the height/width to match, but it didn't make it unblurry.

                       

                      Currently the page A First Pi Project: Xmas Trees!  has the blurry effect, so the problem is still there, and I've tried reverting back to the original image there but it still looks blurry, so I've put it to the new image again, but the problem seems to persist : ( I don't believe I did anything unusual to the usual workflow when adding/manipulating images. I can't be certain that this is a new issue, because I have seen it occur a while ago, but I can't recall how it was resolved, if it was a Jive issue that was fixed or not.

                       

                      Thanks,

                       

                      Shabaz.

                      2 of 2 people found this helpful
                        • Re: Blurry image
                          shabaz

                          What's weird is that both of these images are now blurry in the discussion reply to you : ( And yet it is sharp in the original discussion post screenshot.

                          I've checked the date-codes of the two images on my PC, and the original image is untouched.

                          1 of 1 people found this helpful
                        • Re: Blurry image
                          shabaz

                          Hi Dudley,

                           

                          I've just spotted a similar issue on another blog post, here:

                          The Secret Life of the Pi

                           

                          In the screenshot below, the top grey diagram is quite sharp, but the lower (green) diagram is fuzzy. Both of the diagrams appear sharp when clicked on, but when reading the blog post without clicking on them the blurry issue is seen on that lower diagram.

                           

                           

                           

                          blurry2.png

                          1 of 1 people found this helpful
                    • Re: Blurry image
                      rachaelp

                      I had this issue on something I posted the other day, I can't remember what it was now though. I was intending to ask about it but got distracted with other things.... I tried scaling the image to different sizes and re-uploading but nothing fixed it. It's not an issue I usually have when uploading images so I think it's something changed behind the scenes which is now causing the issue maybe?

                        • Re: Blurry image
                          shabaz

                          Hi Rachael,

                           

                          That's interesting, so it's not just me. Normally it is pretty good with images, I like that everything is sharp usually when we resize it in the editor, and that we can put fairly large images in our blog posts (I hate it when images/photos are so small on other websites and I want to look at detail..).

                        • Re: Blurry image
                          Dudley Nelson

                          This is a great piece of investigation you've done here, and it's really piqued my curiosity.

                           

                          However, I'm in the midst of a piece of work and have a looming deadline, and I don't have time to spare to look into this :/ I need to get the work I'm doing on video finished before I go on holiday in early August, and it's not with our testers yet!

                           

                          So I'm going to create a ticket and come back to this at some point in the near future.

                          1 of 1 people found this helpful
                          • Re: Blurry image
                            shabaz

                            Hi,

                             

                            I hate to bring this topic up again, but it still persists : ( I created a blog post here:

                            Working with Sprites: Building Street Fighter with the Pi

                            The last two images in the blog post show code (the reason for having code as an image is just to make it easier to view and explain, I don't expect the user to copy-and-paste the code since they can just directly download the entire folder of code; the purpose of the image was to explain, not to provide a container for code that is copy-paste friendly).

                            Anyway, the second-to-last image shows very clear code, it is sharp and readable. But the last image shows very blurry code (until the user clicks the code). However, if the user clicks the code then they cannot read the description of the code simultaneously. The code goes hand-in-hand with the text description below it, and so both ideally need to be visible on the screen at the same time.

                            Both images were created in the same manner, so I'm sure it is a server/Jive related issue : (

                            1 of 1 people found this helpful
                              • Re: Blurry image
                                the-dubster

                                I have also recently had the same issue - this reply has 2 images - screenshots from my mobile. The first in 'portrait' mode is blurry in the post while the second in 'landscape' is not.

                                Both were inserted at the same time as I was creating the post so I don't really know why?

                                 

                                Does it possible have something to do with scaling the image? In the post the portrait image is considerably larger than the landscape, whilst when clicked the landscape image is displayed far larger than the portrait.

                                It seems it is zooming the smaller image (and somewhat more than it needs to).

                                 

                                Regards

                                 

                                Edit. Reviewing shabaz posts above - it seems the problem images (or at least, worst affected) are in portrait mode and not landscape! Is this relevant?

                                1 of 1 people found this helpful
                                  • Re: Blurry image
                                    shabaz

                                    Very interesting that it could be related to portrait.. You could be right, maybe we're exceeding some threshold for image size, or image proportion, e.g. maybe the scaling algorithms prefers exact powers of 2 or something : (

                                     

                                    I've not been able to find a pattern so far, but I do hit this problem quite frequently now. I do tend to scale images, because the defaults are too small for some situations where lots of detail needs to be shown.

                                    3 of 3 people found this helpful
                                      • Re: Blurry image
                                        balearicdynamics

                                        It is surely related to portrait. There are lots of issues when trying to add a portrait image; sometimes it is not correctly reshaped. Then while the landscape images can be added just dropping them to the lie where you want the image, this is not possible with portrait.

                                         

                                        dudley.nelson There was a period when images was almost impossible to add. Then things seemed to go fine but the editor stopped to resize them if the images was larger than 1600px (wide side). And portrait has the major issues.

                                         

                                        Enrico

                                        3 of 3 people found this helpful
                                  • Re: Blurry image
                                    Dudley Nelson

                                    Ultimately, it shouldn't matter what the dimensions are of a picture, it should render on the site fine. Although that said, when we have had issues with images, they have been tall and skinny.

                                     

                                    We did make changes to the codebase as a result of this issue before. We were provided with a patch and it was applied, and it seemed to make things better. Indeed - you can see looking at the pictures in this discussion that earlier images appear okay (I won't say it's perfect). There is definitely room for improvement tho as this screenshot attests.

                                     

                                    (you will probably need to click on this image to see my point)

                                     

                                    We are presently consumed with a major upgrade at the moment, which will be available... Soon™ There are improvements to image handling in that upgrade, and my first temptation is to do nothing until that hits, and see what happens.

                                     

                                    I'm going to take a copy of your blogpost before I do anything else so that we don't lose the original issue. I don't like to edit member content unless I have to, but I could have a mess around and see if I can make it appear more legible? There might be some stuff I can do with styles to make it appear better? I won't touch anything without your blessing tho.

                                     

                                    An aside question, and not one I am asking as a workaround to this issue, but one I have to ask is - how come you are using images for your screenshots and not the code syntax highligher?

                                    3 of 3 people found this helpful
                                      • Re: Blurry image
                                        shabaz

                                        Hi Dudley,

                                         

                                        No problem, please go ahead and experiment with it : )

                                         

                                        Regarding the syntax highlighter, in this case it seemed preferable to have code as an image, fully expanded alongside the text description, which gives me capabilities to selectively highlight stuff, more like a diagram or image in an article than code for copy-pasting. In the end I didn't highlight stuff in this instance, but the option was there, and seemed better for the type of article I was writing. I could have used the syntax highlighter tool in hindsight, but it could affect the next blog posts too, whenever an image ends up being needed : (

                                          • Re: Blurry image
                                            Dudley Nelson

                                            Having just been hit with this issue with one of our internal documents, I've debugged through the code and have at least some answers as to what's going on.

                                             

                                            This is being caused by a double scaling. It is resizing the image, and then having resized it, it resizes it again. The breakpoints I've put in the code prove beyond reasonable doubt that it's doing it twice. Why it's doing this I am still looking into. It seems to be particularly prone to tall and thin images and looks like it's a problem with images that hit the vertical size limit but not the width limit.

                                             

                                            Just thought I'd give you what information I have - I'm going to continue looking into it going forwards.

                                            4 of 4 people found this helpful
                                        • Re: Blurry image
                                          Jan Cumps

                                          I have what seems to be the same issue in this comment:

                                          https://www.element14.com/community/docs/DOC-83867#comment-114704

                                           

                                          I drag-and-dropped a picture of 1136*1399, 1.18 MB

                                          It appeared blurred immediately, before saving or resizing.

                                           

                                          I'll try to do the same here and now:

                                          20170913_133938.jpg

                                            • Re: Blurry image
                                              Dudley Nelson

                                              Drag and drop does something different to inserting an image through the dialogue or copy/pasting an image in.

                                               

                                              I've seen it before (in my gmail) and I think it was related to the version of chrome I was using. I'm working from memory here rather than any citation, so take my words with a pinch of salt. But I suspect chrome sometimes handles drag and drop events itself rather than letting the website code at it.

                                               

                                              Try inserting it by some other means than drag-and-drop? Just for diagnosis.

                                              2 of 2 people found this helpful