Details

    • Type: Bug Bug
    • Status: Reopened Reopened
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 0.4.0, 0.4.1, 0.4.1.1, 0.6.1.1
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Severity:
      High
    • Environment:
      .NET / Windows32
    • Steps to Reproduce:
      Hide

      Upload a smaller ( < 1024x1024) detailed image with SLImageUpload. To more easily see artifacts use contrasting, monochromatic hues.

      Show
      Upload a smaller ( < 1024x1024) detailed image with SLImageUpload. To more easily see artifacts use contrasting, monochromatic hues.

      Description

      Nasty artifacts and poor image quality present on images encoded and uploaded via openJPEG-libsl.

      1. LIBOMV-243.patch
        0.7 kB
        gonta maltz
      2. LIBOMV-243-with_image_component_sensitivity.patch
        0.8 kB
        gonta maltz
      3. openjpeg_result.tga
        768 kB
        gonta maltz
      4. plywood.tga
        768 kB
        Shack Dougall
      5. SL_result.tga
        768 kB
        gonta maltz
      1. original_image.png
        139 kB
      2. plywood_uploaded_not_lossless.jpg
        104 kB

        Issue Links

          Activity

          Hide
          Shack Dougall added a comment -

          I've found a workaround.

          FreeImage (http://freeimage.sourceforge.net/) has a liberal license and an excellent c# wrapper.

          Instead of calling:

          image = LoadTGAClass.LoadTGA(imagePath);

          I can use FreeImage by calling:

          FREE_IMAGE_FORMAT imgFormat = FREE_IMAGE_FORMAT.FIF_UNKNOWN;
          image = FreeImage.LoadBitmap(imagePath,FREE_IMAGE_LOAD_FLAGS.DEFAULT, ref imgFormat);

          And it creates a Bitmap with PixelFormat.Format24bppRgb like I want.

          I haven't thoroughly tested it yet, but it was easy to integrate and is well documented. Looks like a winner.

          Show
          Shack Dougall added a comment - I've found a workaround. FreeImage ( http://freeimage.sourceforge.net/ ) has a liberal license and an excellent c# wrapper. Instead of calling: image = LoadTGAClass.LoadTGA(imagePath); I can use FreeImage by calling: FREE_IMAGE_FORMAT imgFormat = FREE_IMAGE_FORMAT.FIF_UNKNOWN; image = FreeImage.LoadBitmap(imagePath,FREE_IMAGE_LOAD_FLAGS.DEFAULT, ref imgFormat); And it creates a Bitmap with PixelFormat.Format24bppRgb like I want. I haven't thoroughly tested it yet, but it was easy to integrate and is well documented. Looks like a winner.
          Hide
          Jonathan Ballard added a comment - - edited

          I've tried to isolate the alpha bug in the openjpeg library. It appears this has gone unnoticed since the viewer uploaded images as lossless. Now that they are irreversible enabled, the alpha bug emerges.

          Related discussion:
          http://groups.google.com/group/openjpeg/tree/browse_frm/thread/4683bba9660c2779#doc_a5d7e1d610446e2f
          http://groups.google.com/group/openjpeg/browse_thread/thread/1cb7807b2053592e

          Contact me if you or anybody has found a fix to encode images with alpha (32bit, not 24bit).

          Show
          Jonathan Ballard added a comment - - edited I've tried to isolate the alpha bug in the openjpeg library. It appears this has gone unnoticed since the viewer uploaded images as lossless. Now that they are irreversible enabled, the alpha bug emerges. Related discussion: http://groups.google.com/group/openjpeg/tree/browse_frm/thread/4683bba9660c2779#doc_a5d7e1d610446e2f http://groups.google.com/group/openjpeg/browse_thread/thread/1cb7807b2053592e Contact me if you or anybody has found a fix to encode images with alpha (32bit, not 24bit).
          Hide
          John Hurliman added a comment -

          My understanding is that this is an OpenJPEG issue and we are waiting on an upstream fix. Setting assignee to null for now. If this is incorrect please update.

          Show
          John Hurliman added a comment - My understanding is that this is an OpenJPEG issue and we are waiting on an upstream fix. Setting assignee to null for now. If this is incorrect please update.
          Hide
          glem02 added a comment - - edited

          Any news on this bug? Do we have to use the recommended workaround with freeimage (s. above)?

          Complex textured objects look weird after import because of those conversion and alpha issues in OpenJPEG (running TestClient on Windows7 - 64bit). The problem could become even bigger, as the transfers between grids and the usage of 64bit OS (e.g. Win-7 and Linux) is increasing quite fast.

          This problem should deserve a higher priority!

          Thanks, glem

          Show
          glem02 added a comment - - edited Any news on this bug? Do we have to use the recommended workaround with freeimage (s. above)? Complex textured objects look weird after import because of those conversion and alpha issues in OpenJPEG (running TestClient on Windows7 - 64bit). The problem could become even bigger, as the transfers between grids and the usage of 64bit OS (e.g. Win-7 and Linux) is increasing quite fast. This problem should deserve a higher priority! Thanks, glem
          Hide
          glem02 added a comment -

          I was thinking on a workaround...

          Is there any way to use the kakadu library from the viewers (llkdu.dll) for uploading images? Is there some example how tu use it?
          Or would I need to buy the code for this library and recompile it?

          Glem

          Show
          glem02 added a comment - I was thinking on a workaround... Is there any way to use the kakadu library from the viewers (llkdu.dll) for uploading images? Is there some example how tu use it? Or would I need to buy the code for this library and recompile it? Glem

            People

            • Assignee:
              Unassigned
              Reporter:
              gonta maltz
            • Votes:
              3 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated: