~ubuntu-branches/ubuntu/trusty/libjpeg-turbo/trusty

« back to all changes in this revision

Viewing changes to java/TJUnitTest.java

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2011-12-20 23:12:52 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20111220231252-74naxp27nuzxpn8o
Tags: 1.1.90+svn733-0ubuntu2
* Sync with upstream to svn733.

* Rename libjpeg-test to libjpeg-turbo-test.
* Rename libjpeg-turbo-dbg to libjpeg-turbo8-dbg.
* Rename libjpeg8-dev to libjpeg-turbo8-dev.
* Move the docs into the -dev package, install the upstream changelog
  in the -dev only.
* Split out libturbojpeg.so into it's own package, don't let
  libjpeg-turbo8-dev depend on it.
* Fix libjpeg-turbo8-dbg package description.
* Install jconfig.h into multiarch include path.
* Remove HAVE_STD{LIB,DEF}_H from jconfig.h since they are not used and
  conflict with autoconf.
* libjpeg-turbo8:
  - Add a symbols file, with a different version for symbols only found
    in the libjpeg-turbo implementation.
  - Remove the shlibs file.
  - Breaks/Replaces libjpeg8 (<< 8c-2ubuntu5).
* Copy the exifautotran and jpegexiforient tools from the libjpeg8
  sources, install into libjpeg-turbo-progs.
* Don't install tjbench in libjpeg-turbo-progs to avoid dependency
  on libturbojpeg.

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
  };
59
59
 
60
60
  private final static String pixFormatStr[] = {
61
 
    "RGB", "BGR", "RGBX", "BGRX", "XBGR", "XRGB", "Grayscale"
 
61
    "RGB", "BGR", "RGBX", "BGRX", "XBGR", "XRGB", "Grayscale",
 
62
    "RGBA", "BGRA", "ABGR", "ARGB"
62
63
  };
63
64
 
64
65
  private final static int alphaOffset[] = {
65
 
    -1, -1, 3, 3, 0, 0, -1
 
66
    -1, -1, -1, -1, -1, -1, -1, 3, 3, 0, 0
66
67
  };
67
68
 
68
69
  private final static int _3byteFormats[] = {
112
113
        else
113
114
          return TJ.PF_RGBX;
114
115
      case BufferedImage.TYPE_INT_RGB:
115
 
      case BufferedImage.TYPE_INT_ARGB:
116
 
      case BufferedImage.TYPE_INT_ARGB_PRE:
117
116
        if(byteOrder == ByteOrder.BIG_ENDIAN)
118
117
          return TJ.PF_XRGB;
119
118
        else
120
119
          return TJ.PF_BGRX;
 
120
      case BufferedImage.TYPE_INT_ARGB:
 
121
      case BufferedImage.TYPE_INT_ARGB_PRE:
 
122
        if(byteOrder == ByteOrder.BIG_ENDIAN)
 
123
          return TJ.PF_ARGB;
 
124
        else
 
125
          return TJ.PF_BGRA;
121
126
    }
122
127
    return 0;
123
128
  }
769
774
          size = compTest(tjc, dstBuf, w, h, pf, baseName, subsamp, 100,
770
775
            flags);
771
776
          decompTest(tjd, dstBuf, size, w, h, pf, baseName, subsamp, flags);
 
777
          if(pf >= TJ.PF_RGBX && pf <= TJ.PF_XRGB && !bi)
 
778
            decompTest(tjd, dstBuf, size, w, h, pf + (TJ.PF_RGBA - TJ.PF_RGBX),
 
779
              baseName, subsamp, flags);
772
780
        }
773
781
      }
774
782
    }